1 In this section, you make modifications to guarantee that the appropriate fsck program runs on AFS server partitions. The fsck program provided with the operating system must never run on AFS server partitions. Because it does not recognize the structures that the File Server uses to organize volume data, it removes all of the data. To repeat:
3 Never run the standard fsck program on AFS server partitions. It discards AFS volumes.
5 1. Create the /usr/lib/fs/afs directory to house the AFS-modified fsck program and related files.
7 # mkdir /usr/lib/fs/afs
11 2. Copy the vfsck binary to the newly created directory, changing the name as you do so.
13 # cp /cdrom/sysname/dest/root.server/etc/vfsck fsck
15 1. Working in the /usr/lib/fs/afs directory, create the following links to Solaris libraries:
17 # ln -s /usr/lib/fs/ufs/clri
18 # ln -s /usr/lib/fs/ufs/df
19 # ln -s /usr/lib/fs/ufs/edquota
20 # ln -s /usr/lib/fs/ufs/ff
21 # ln -s /usr/lib/fs/ufs/fsdb
22 # ln -s /usr/lib/fs/ufs/fsirand
23 # ln -s /usr/lib/fs/ufs/fstyp
24 # ln -s /usr/lib/fs/ufs/labelit
25 # ln -s /usr/lib/fs/ufs/lockfs
26 # ln -s /usr/lib/fs/ufs/mkfs
27 # ln -s /usr/lib/fs/ufs/mount
28 # ln -s /usr/lib/fs/ufs/ncheck
29 # ln -s /usr/lib/fs/ufs/newfs
30 # ln -s /usr/lib/fs/ufs/quot
31 # ln -s /usr/lib/fs/ufs/quota
32 # ln -s /usr/lib/fs/ufs/quotaoff
33 # ln -s /usr/lib/fs/ufs/quotaon
34 # ln -s /usr/lib/fs/ufs/repquota
35 # ln -s /usr/lib/fs/ufs/tunefs
36 # ln -s /usr/lib/fs/ufs/ufsdump
37 # ln -s /usr/lib/fs/ufs/ufsrestore
38 # ln -s /usr/lib/fs/ufs/volcopy
40 1. Append the following line to the end of the file /etc/dfs/fstypes.
44 1. Edit the /sbin/mountall file, making two changes.
46 \* Add an entry for AFS to the case statement for option 2, so that it reads as follows:
53 s5) foptions="-y -t /var/tmp/tmp$$ -D"
58 ### <a name="Solaris 6"></a> Solaris 6
60 \* Edit the file so that all AFS and UFS partitions are checked in parallel. Replace the following section of code:
62 # For fsck purposes, we make a distinction between ufs and
65 if [ "$fstype" = "ufs" ]; then
66 ufs_fscklist="$ufs_fscklist $fsckdev"
67 saveentry $fstype "$OPTIONS" $special $mountp
71 with the following section of code:
73 # For fsck purposes, we make a distinction between ufs/afs
74 # and other file systems.
76 if [ "$fstype" = "ufs" -o "$fstype" = "afs" ]; then
77 ufs_fscklist="$ufs_fscklist $fsckdev"
78 saveentry $fstype "$OPTIONS" $special $mountp
82 ### <a name="Solaris 9"></a> Solaris 9
84 \* Edit the file so that all AFS and UFS partitions are checked in parallel.
86 You must copy /usr/lib/fs/ufs/fsckall to /usr/lib/fs/afs/fsckall and change the word ufs to afs in file /usr/lib/fs/afs/fsckall as indicated below. This ensures that AFS fsck is called on vice partitions.
88 1. 1. 1. Copy /usr/lib/fs/ufs/fsckall to /usr/lib/fs/afs/fsckall.
90 cp /usr/lib/fs/ufs/fsckall /usr/lib/fs/afs/fsckall
92 1. 1. 1. Edit /usr/lib/fs/afs/fsckall and replace ufs with afs as indicated below.
97 /usr/sbin/fsck -m -F ufs $fsckdev >/dev/null 2>&1
101 for fsckdev in $*; do
102 /usr/lib/fs/afs/fsck -m -F afs $fsckdev >/dev/null 2>&1
104 Also, this section of the same file:
108 echo "checking ufs filesystems"
109 /usr/sbin/fsck -o p $ufs_fscklist
113 echo "checking afs filesystems"
114 /usr/lib/fs/afs/fsck -o p $ufs_fscklist