How to convert a RO volume to a RW volume in AFS
1) Get tokens as 'admin' via 'kinit admin' folllowed by 'aklog'
2) Check the mount: 'fs lsmount /afs/atlas.umich.edu/OSGWN' This will show you the volume name.
3) Remove the existing RO mount: 'fs rmmount /afs/.atlas.umich.edu/OWGWN' NOTE: the .atlas.umich.edu part.
4) Remount RW: 'fs mkmount /afs/.atlas.umich.edu/OSGWN -rw' (Put the right name in from step 2) )
5) Make sure the 'root' volume is updated and available: 'vos release root.cell' and 'fs checkvolumes'
How to add quota to a afs dir.
1) to do this, you need to login as admin
2) get the volume name which is associated with the directory
#fs lsmount /afs/atlas.umich.edu/BackupdCache
'/afs/atlas.umich.edu/BackupdCache' is a mount point for volume '%BackupdCache'
BackupdCache is the volume name
root# vos examine BackupdCache
BackupdCache 536874892 RW 54992198 K On-line
linat06.grid.umich.edu /vicepe
RWrite 536874892 ROnly 536874893 Backup 0
MaxQuota 75000000 K
Creation Wed Nov 14 13:05:13 2007
Copy Wed Nov 14 13:05:13 2007
Backup Never
Last Update Wed Apr 8 19:45:01 2009
40363 accesses in the past day (i.e., vnode references)
RWrite: 536874892 ROnly: 536874893
number of sites -> 2
server linat06.grid.umich.edu partition /vicepe RW Site
server linat06.grid.umich.edu partition /vicepe RO Site
linat06 /vicepe is the partion which hosts the volume Backupdcache
4) examine the partition which hosts the volume to see if there are enough space on that partition
#vos partinfo linat06 /vicepe
Free space on partition /vicepe: 218209100 K blocks out of total 935671040
it has about 218GB free space on this partition
5) add more space to the volume
#fs setquota /afs/atlas.umich.edu/BackupdCache 75000000
set the new quota to 75GB
6)verify that the total quota on the volume has been udpate
#vos examine BackupdCache
IP based ACL in AFS
Case, create a dir /afs/atlas.umich.edu/dcache/check_md5 which allows all umfs and msufs machines have rw permission..
1) create user by IP adress (should use both public and private IP, not sure which IP would be used to for fs nodes to talk to afs servers)
pts createuser 192.41.230.27
pts createuser 10.10.1.27
....
pts createuser 192.41.230.30
pts createuser 10.10.1.30
2) create a group and add all these ip users to the group..
pts creategroup aglt2fs
pts add 192.41.230.27 aglt2fs
pts add 10.10.1.27 aglt2fs
...
root@umfs09 ~# pts membership aglt2fs
Members of aglt2fs (id: -8017) are:
192.41.230.27
192.41.230.28
10.10.1.27
10.10.1.28
10.10.1.29
3) change the permission of dir
fs setacl /afs/atlas.umich.edu/dcache/ aglt2fs rlidwka
root@head02 ~# fs listacl /afs/atlas.umich.edu/dcache/
Access list for /afs/atlas.umich.edu/dcache/ is
Normal rights:
aglt2fs rlidwka
system:administrators rlidwka
system:anyuser rl
4) other things shawn has done to re-arrange the root dir /afs/atlas.umich.edu/dcache
1084 fs mkmount /afs/.atlas.umich.edu/dcache check_md5 -rw
1085 vos release root.cell
1086 fs checkvolumes
1087 fs listacl /afs/atlas.umich.edu/
1088 fs listacl /afs/atlas.umich.edu/dcache/
1089 fs setacl /afs/atlas.umich.edu/dcache/ aglt2fs rlidwka
1090 fs listacl /afs/atlas.umich.edu/dcache/
1091 fs lsmount /afs/atlas.umich.edu/BackupdCache
1092 fs mkmount /afs/atlas.umich.edu/dcache/BackupdCache BackupdCache -rw
1093 fs lsmount /afs/atlas.umich.edu/dcache/BackupdCache/
1094 fs lsmount /afs/atlas.umich.edu/dcache/BackupdCache
1095 fs listacl /afs/atlas.umich.edu/dcache/
1096 fs listacl /afs/atlas.umich.edu/dcache/BackupdCache
1097 fs setacl /afs/atlas.umich.edu/dcache/ system:anyuser rl
1098 fs listacl /afs/atlas.umich.edu/dcache/BackupdCache
1099 fs listacl /afs/atlas.umich.edu/dcache
1100 mkdir /afs/atlas.umich.edu/dcache/check_md5
1101 fs listacl /afs/atlas.umich.edu/dcache/check_md5/
1102 fs help setacl /afs/atlas.umich.edu/dcache/check_md5
1103 fs setacl /afs/atlas.umich.edu/dcache/check_md5 -clear system:administrators rlidwka aglt2fs rlidwka
1104 fs listacl /afs/atlas.umich.edu/dcache/check_md5/
--
WenjingWu - 16 Jan 2008