squeak!
Syllabus Homepage
Course Overview
Course resources
Day 1
Day 2
Day 3
Day 4
Day 5
Day 6
Day 7
Day 8
Common errors
Internet Glossary
About Your Instructor
Credits: This site powered by the vi text editor, apache webserver, perl scripting, and Debian linux.
squeak!

solaris8 II - Day 5

Goals

  • get an overview of NFS
  • work with NFS

POST

This exercise will be done on your NIS box.
  1. what is the sun recommended way to make significant network changes to your machine?
  2. where do you start to troubleshoot if you cannot ping an internet site by IP?
  3. where do you start to troubleshoot if you cannot ping an internet site by hostname?
  4. where is NIS information stored for servers?
  5. where is NIS information stored for clients (binding information, not actual NIS DATA)?
  6. why don't our NIS logins have home directories?

NFS introduction

  • centralization of data
  • consistency of data
  • leverage SANS, etc
  • homedir appears to follow the user around
  • share discspace between machines
  • do not crossmount
  • NFS failures can cause box or app lockups
  • NFS mounts can take a while, especially at boot time
  • NFS is now TCP transport, but initial contact can be a UDP RCP call to the portmapper to find out where the TCP port is going to be (whew!).
  • WebNFS is a little-known NFS variant that works on stable ports (useful through firewalls). Rarely used.

practicum: mounting userdirs on fileserver

  • mount options pp. 610-11 (see permissions digression below)
  • mount manually: mount -F nfs [-o options] host:filesystem mountpoint
  • mount automatically: /etc/vfstab

advanced permissions

---s--s--t 7000 setuid, setgid, sticky 
---s--s--- 6000 setuid, setgid
---s-----t 5000 setuid, sticky
---s------ 4000 setuid
------s--t 3000 setgid, sticky
---s------ 2000 setgid
---------t 1000 sticky
---------- 0000 none


/usr/bin/find / -user root -perm -4000 -o -perm -2000
  • Access Control Lists (ACLs) (Solaris only) File Access Control Lists are a way to achieve finer permissions granularity than normal unix ownership/permissions allows. ACLs are allowed on files and dirs, and dirs can have (and should have) a default ACL.

    • getfacl shows the current ACL
      $ getfacl examplefile
      
      # file: examplefile
      # owner: snelling
      # group: snelling
      user::rw-
      group::r--              #effective:r--
      mask:r--
      other:r--
      

      The main difference here is the presence of a mask which specifies the maximal permission for any non-user (ie, non-owner) account.

    • setfacl sets the ACL for a file or directory
      setfacl -s acl_settings file - set the ACL. cf numerical mode chmod
      setfacl -m acl_settings file - modify the ACL. cf symbolic mode chmod
      u[ser]::perms
      g[roup]::perms
      o[ther]:perms
      m[ask]:perms
      u[ser]:uid:perms
      g[roup]:gid:perms
      d[efault]:u[ser]::perms
      d[efault]:g[roup]::perms
      d[efault]:o[ther]:perms
      d[efault]:m[ask]:perms
      d[efault]:u[ser]:uid:perms
      d[efault]:g[roup]:gid:perms
      

    getfacl bar | setfacl -f - foo

  • RBAC RBAC is generally implemented via the SMC.
    1. some utilities are RBAC-aware; some will need to be run through SMC
    2. may require the creation of roles before granting privs to users

    practicum: sharing NFS filesystems

    • share options pp. 606-07
    • share manually: share -F nfs [-o options] path
    • share automatically: /etc/dfs/dfstab. Run as a script? Latest mount supersedes preceding ones.

    Homework


    http://www.mousetrap.net/syllabus/solaris8-nfs/day5.html
    $Id: day5.orb,v 1.2 2002/11/15 18:32:05 mouse Exp $

  • © 1994-2002 jason carr.
    distributed under the terms of the GNU Free Documentation License.

    jason carr

    Reminders

    • Classroom temperature can be wildly variable. Dress lightly and bring layers.
    • your username is based on the class title and the last two digits of your workstation's hostname.
    • remember to take your work with you.