[OpenAFS-devel] parsing program options from config file(s)
Derrick Brashear
shadow@gmail.com
Mon, 30 Jul 2012 11:52:08 -0400
Gerrit 7903 adds 2 krb5 profile-style config files,
openafs-client.conf (in client's etc dir e.g. /usr/vice/etc) and
openafs-server.conf (in server's etc dir e.g. /usr/afs/etc)
We agreed at the hackathon to eventually support configuration in these:
http://wiki.openafs.org/AFSLore/hackathon_pittsburgh_2011/
this does not go far in that direction. for the moment it is limited
to option support, replacing (well, actually,
supplementing, and that's important) command line switches.
For instance, openafs-client.conf on a Mac using a non-standard cache might be:
[afsd]
dynroot = true
afsdb = true
fakestat-all = true
daemons = 8
volumes = 70
chunksize = 18
stat = 5000
dcache = 800
cachedir = /Library/Caches/org.openafs.filesystems.afs
Continuing to parse command line switches allows additional options to
be set, which allows things like
afsd -shutdown to still work.
Because previous work has already made ptserver, vlserver, fileserver
and afsd able to support this (conversion
from hand-parsed command lines to cmd_OptionAsXXX) initial support is
provided there. Anyone willing to convert
volserver and bosserver? Comments welcome, if there are specific code
complaints, stick them in gerrit.
--
Derrick