have a task its a list of questions and can you please assist me...
1.how do you format or partition a disk
2.what files will you edit to change a servers hostname
3.How would one set a service to start automatically after reboot
I would recommend going directly to the source and reviewing the RHEL system administrator guide, and storage administrator guide for whichever version you're running. They contain step by step information of what you're seeking.
Product Documentation for Red Hat Enterprise Linux - Red Hat Customer Portal
1. look up the following commands: mkpart, mkfs
2. look up the hostname command, and the /etc/sysconfig/network file
3. this depends on your version. RHEL 6 services are defined in init.d; they can be managed with the chkconfig command (you want your service to be "on"). RHEL7 services are defined by systemd and can be managed with systemctl (you want your service to be "enabled"). Look up whichever command corresponds to your version.
For RHEL 7
example : you have SAN disk / or local disk with /dev/sdf as the disk
Create Primary partion using fdisk /dev/sdf ( take a look at Man page of fdisk)
take a look at this (Partitioning with fdisk )
you can use "hostnamectl" command to change the hostname , make sure dns is not having any issue
check out this Redhat 7 article
[ 3.3. Configuring Host Names Using hostnamectl ]
in Redhat 7 you can below to list all
systemctl list-units --type service
To start only for this time
systemctl start name.service
To set a service Persistent on after reboot use
systemctl enable name.service
ex: ~]# systemctl start httpd.service
systemctl start httpd.service
for more info refer
[ Chapter 9. Managing Services with systemd ] https://www.google.com.sg/url?sa=t&rct=j&q=&esrc=s&source=web&cd=1&cad=rja&uact=8&ved=0ahUKEwiKpOXGnLHQAhUfSo8KHah4DNEQFggZMAA&url=https%3A%2F%2Faccess.redhat.com%2Fdocumentation%2Fen-US%2FRed_Hat_Enterprise_Linux%2F7%2Fhtml%2FSystem_Administrators_Guide%2Fchap-Managing_Services_with_systemd.html&usg=AFQjCNHr-oCGDcyu7Xju60xJMki5wYaezg&sig2=2FYlqM-qf9blBNVMAXe9AA
Retrieving data ...