Changes

Jump to: navigation, search

OPS535-lab-nfs

759 bytes added, 14:23, 19 September 2019
m
Investigation 1: NFS Server Setup: - fixing a typo
Make sure to double check that the file permissions have been set correctly.</li>
<li>To set the sticky bit on the directory "/nfs-pub" , use the command
<soursesource>chmod +t /nfs-pub</source></li>
<li>Edit your /etc/exports file and insert the following lines:
<source>/nfs-pub ip-of-vm1(rw,root_squash)
/nfs-pub ip-of-vm3(rw,root_squash)</source>
"ip-of-vm1" should be replaced by the actual IP address of vm1 (VM1),and "ip-of-vm3" should be replaced by the actual IP address of vm3 (VM3).</li>
<li>Enter the command
Again, make notes of the owner and group owner of the file.</li>
<li>Login to the NFS server, and examine the ownership of the files you just created. Who is the owner and the group owner of the respective files?</li>
6. <li>On vm1 and vm3your nfs-client machine, un-mount the remote directory nfs-server:/nfs-pub with the command.umount /nfs-mntPlease Please note that this must be done by "root" and the directory /nfs-mnt is not being used by anyprocess.</li>7. <li>On the NFS server, make the following changes to the /etc/exports file:
change
<source>/nfs-pubip-of-vm1(rw, root_squash)</source>
to
<source>/nfs-pubchange/nfs-pubto/nfs-pubip-of-vm1(rw, root_squash)ip-of-vm1(rw, no_root_squash)ip-of-vm3(rw, root_squash)ip-of-vm3(rw, no_root_squash)</source>and re-export the directory.</li>8. <li>On vm1 and vm3the client, re-mount the share directory and repeat step 3 to step 6 under the super user
account "root" and copy the file /etc/group to the share directory /nfs-mnt with the
corresponding file name.</li>9. On vm1 and vm3, <li>un-mount the remote directory.</li>10.<li>On the NFS server, change the "rw" option in the /etc/exports file to "ro" and re-export thedirectory.</li>11.<li>On vm1 and vm3the client, re-mount the share directory and repeat step 3 to step 6 under the super user
account "root" and copy the file /etc/hosts to the share directory /nfs-mnt with the corresponding
file name.</li>ls -l <li>Observe how the different settings on the server affected the ownership and permissions of files created on the client side.</nfs-pub/passwd.A.*li><li>Repeat this investigation on vm3, naming the first user userB (or ls -l /nfs-pub/passwd.instead of userA), and replace the A in any file names with B.*) When creating files, try to check predict the file created by ownership and permissions of the user "userA" and "ops535" on vm1, vm3resulting files. </li>
</ol>
# What is the full path name of the nfs module file? i.e. where is it on your hard drive?
# What is the purpose of the sticky bit?
# Who is the owner of /nfs-mnt/passwd.A.root and /nfs-pub/passwd.A.root? Are they the same? Why?
# Who is the owner of the file /nfs-mnt/passwd.A.user and /nfs-pub/passwd.A.user? Are they the same? Why?
# Who is the owner of the file /nfs-mnt/passwd.A.map and /nfs-pub/passwd.A.map? Are they the same? Why and why not?
# Who is the owner of the file /nfs-mnt/passwd.A.ops and /nfs-pub/passwd.A.ops? Are they the same? Why and why not?
# Who is the owner of /nfs-mnt/group.A.root and /nfs-pub/group.A.root? Are they the same? Why?
# Did the file /nfs-mnt/hosts.A.root get created? Why or why not?
932
edits

Navigation menu