cancel
Showing results for 
Search instead for 
Did you mean: 
Tanveer
Flight Engineer
Flight Engineer
  • 8,422 Views

RHCSA-RH134 Lab

Jump to solution

Dear all,

As-salamu alaykum

Note:- Purpose of this post is not to distribute the RHCSA material but to clear my confusion.

In the end of the book RH134 there is a Chapter named COMPREHENSIVE REVIEW, there is LAB question the LAB CONFIGURING AND MANAGING SERVER SECURITY.

Q:-Configure serverb to automatically mount the home directory of the production5
user when the user logs in, using the network file system /home-directories/
production5. This network file system is exported from servera.lab.example.com.
Adjust the appropriate SELinux Boolean so that production5 can use the NFS-mounted
home directory on serverb after authenticating via SSH key-based authentication. The
production5 user's password is redhat.

Given answer that i did not understand is :-

Create the autofs master map file called /etc/auto.master.d/
production5.autofs with the following content.

/- /etc/auto.production5

 

Create the /etc/auto.production5 file with the following content

/localhome/production5 -rw servera.lab.example.com:/home-directories/
production5

Confusion point why the mount is /localhome/production5 instead of /home/production5.

Labels (1)
2 Solutions

Accepted Solutions
Tracy_Baker
Starfighter Starfighter
Starfighter
  • 7,740 Views

"Confusion point why the mount is /localhome/production5 instead of /home/production5."

The easy answer is because they want you to.

If I recall correctly, autofs locks the directory, disallowing use by other services. As a result, you really wouldn't want to use /home/production5/

If you wanted to mount into the user's home directory structure, you would want to mount to something like: /home/production5/p5dir/

(I'm sure someone will correct me if I'm wrong...)

What I find interesting is that your RH134 comprehensive review is, apparently, very different from the one I'm using with my Red Hat Academy. We have no "production5" user. Also, the systema.lab.example.com doesn't exist... Oh, it just hit me... Are you using RHEL 8 material?

Program Lead at Arizona's first Red Hat Academy, est. 2005
Estrella Mountain Community College

View solution in original post

0 Kudos
Tracy_Baker
Starfighter Starfighter
Starfighter
  • 7,710 Views

We aren't using something newer, we're still using RHEL 7. It will take us until Fall 2020 before we start to teach RHEL 8. As an academic institution, it takes about a year to get new curriculum / classes through all the apprpriate committees.

Program Lead at Arizona's first Red Hat Academy, est. 2005
Estrella Mountain Community College

View solution in original post

10 Replies
Tracy_Baker
Starfighter Starfighter
Starfighter
  • 7,741 Views

"Confusion point why the mount is /localhome/production5 instead of /home/production5."

The easy answer is because they want you to.

If I recall correctly, autofs locks the directory, disallowing use by other services. As a result, you really wouldn't want to use /home/production5/

If you wanted to mount into the user's home directory structure, you would want to mount to something like: /home/production5/p5dir/

(I'm sure someone will correct me if I'm wrong...)

What I find interesting is that your RH134 comprehensive review is, apparently, very different from the one I'm using with my Red Hat Academy. We have no "production5" user. Also, the systema.lab.example.com doesn't exist... Oh, it just hit me... Are you using RHEL 8 material?

Program Lead at Arizona's first Red Hat Academy, est. 2005
Estrella Mountain Community College
0 Kudos
Tanveer
Flight Engineer
Flight Engineer
  • 7,725 Views

Dear Sir,

As-salamu alaykum

I will look into this.

the book i have used as the refrence point is

SA2

Red Hat System Administration II

Student Workbook

(Release RHEL8.0-en-1-20190507)

Authors:-
Fiona Allen, Adrian Andrade, Herve Quatremain, Victor Costea,
Snehangshu Karmakar, Marc Kesler, Saumik Paul

please let me know if you are using something new.

0 Kudos
Tracy_Baker
Starfighter Starfighter
Starfighter
  • 7,711 Views

We aren't using something newer, we're still using RHEL 7. It will take us until Fall 2020 before we start to teach RHEL 8. As an academic institution, it takes about a year to get new curriculum / classes through all the apprpriate committees.

Program Lead at Arizona's first Red Hat Academy, est. 2005
Estrella Mountain Community College
Tanveer
Flight Engineer
Flight Engineer
  • 7,699 Views

Dear Sir,

As-salamu alaykum

Thank you for your time.

Can you tell me if LDAP's client side configuration will be asked in RHCSA on RHEL8 as this is not mentioned in RHCSA objective as well as i did not find it in the books ?

Again Thank you sir

0 Kudos
plou0404
Flight Engineer Flight Engineer
Flight Engineer
  • 7,448 Views

Hello,

 

Take a look at the environement of your user, production5 in this case.

If you try : #printenv | grep -i home ; from the production5 shell, the HOME varaible is set to :

HOME=/localhome/production5 #this is the home dir of our production5 user

We can see also the default directory for this user in the /etc/passwd file.

grep production5 /etc/passwd # return the default home dir for our production5 user.

 

Best regards,

Pascal

 

 

0 Kudos
JS_Learning
Moderator
Moderator
  • 7,428 Views

Hi,

It's an excellent question, I wondered the very same thing at the time.

it's not well explained but it can be done in two steps:

1) you need to identify what is the user home directory

2) you need to "automount" using that home directory.

As you discovered yourself, it's confusing because we are somehow told to do something, not knowing that this user directory is not /home/xxx.

So in order to do the step one, you can also use this command:

getent passwd username

In your case it's "getent passwd production5".

From that command, you will see that user home directory is actually set to something else.

 

Hope that helps!

Tanveer
Flight Engineer
Flight Engineer
  • 7,412 Views

Dear All,

As-salamu alaykum

I passed RHCSA and I got the quetion now.Thanks to ALL

Tracy_Baker
Starfighter Starfighter
Starfighter
  • 7,399 Views

Congratulations!

Program Lead at Arizona's first Red Hat Academy, est. 2005
Estrella Mountain Community College
0 Kudos
JS_Learning
Moderator
Moderator
  • 7,386 Views

Congratulations!

0 Kudos
Join the discussion
You must log in to join this conversation.