]> git.michaelhowe.org Git - packages/o/openafs.git/commitdiff
Turn on --enable-bos-new-config unconditionally
authorRuss Allbery <rra@stanford.edu>
Fri, 24 Jul 2009 20:18:31 +0000 (13:18 -0700)
committerDerrick Brashear <shadow|account-1000005@unknown>
Tue, 1 Sep 2009 16:46:37 +0000 (09:46 -0700)
Remove the conditional and Autoconf flag for enabling BosConfig.new
handling and change bosserver to always rename BosConfig.new to BosConfig
on startup if the former exists.

Document BosConfig.new handling in the bosserver and BosConfig man pages.
Tone down the warning about the BosConfig file format changing and warn
that bosserver rewrites BosConfig when shutting down.

Reviewed-on: http://gerrit.openafs.org/211
Reviewed-by: Derrick Brashear <shadow@dementia.org>
Tested-by: Derrick Brashear <shadow@dementia.org>
acinclude.m4
doc/man-pages/pod5/BosConfig.pod
doc/man-pages/pod8/bosserver.pod
src/bozo/bosserver.c

index df3a9b5e0436aaa797c5f5294c72905fcec637aa..ff33b72b6e2ef09e420a623255843a7b182cff10 100644 (file)
@@ -52,7 +52,6 @@ AH_VERBATIM([OPENAFS_HEADER],
 #undef AFS_NAMEI_ENV
 #undef BITMAP_LATER
 #undef BOS_RESTRICTED_MODE
-#undef BOS_NEW_CONFIG
 #undef FAST_RESTART
 #undef FULL_LISTVOL_SWITCH
 #undef COMPLETION_H_EXISTS
@@ -111,11 +110,6 @@ AC_ARG_ENABLE([bos-restricted-mode],
          functionality])],
     , 
     [enable_bos_restricted_mode="no"])
-AC_ARG_ENABLE([bos-new-config],
-    [AS_HELP_STRING([--enable-bos-new-config],
-        [enable bosserver pickup of BosConfig.new on restarts])],
-    ,
-    [enable_bos_new_config="no"])
 AC_ARG_ENABLE([largefile-fileserver],
     [AS_HELP_STRING([--disable-largefile-fileserver],
         [disable large file support in fileserver])],
@@ -1469,10 +1463,6 @@ if test "$enable_bos_restricted_mode" = "yes"; then
        AC_DEFINE(BOS_RESTRICTED_MODE, 1, [define if you want to want bos restricted mode])
 fi
 
-if test "$enable_bos_new_config" = "yes"; then
-       AC_DEFINE(BOS_NEW_CONFIG, 1, [define if you want to enable automatic renaming of BosConfig.new to BosConfig at startup])
-fi
-
 if test "$enable_largefile_fileserver" = "yes"; then
        AC_DEFINE(AFS_LARGEFILE_ENV, 1, [define if you want large file fileserver])
 fi
index 135cec915cd13c15f805a5d01646f6efa6cee87a..dec4b7e38fe2101b87a04aff65adf97b88157da2 100644 (file)
@@ -130,11 +130,11 @@ is 5:00 a.m.
 
 =back
 
-Although the F<BosConfig> file is in ASCII format, do not use a text
-editor to alter it. Its format is subject to change and incorrectly
-formatted entries can prevent server startup in ways that are difficult to
-diagnose. Instead always use the appropriate commands from the B<bos>
-command suite:
+Although the F<BosConfig> file is in ASCII format, it is normally best not
+to use a text editor to alter it.  The parser is very picky, and
+incorrectly formatted entries can prevent server startup in ways that are
+difficult to diagnose. Instead, use the appropriate commands from the
+B<bos> command suite:
 
 =over 4
 
@@ -198,6 +198,12 @@ The B<bos startup> command starts a process.
 
 =back
 
+When the BOS Server shuts down, it rewrites F<BosConfig>, discarding any
+changes made manually to that file.  To change the configuration for the
+next BOS Server restart, instead write a new file to F<BosConfig.new>.  If
+F<BosConfig.new> exists when the BOS Server starts, it will rename that
+file to F<BosConfig> before reading its configuration.
+
 =head1 SEE ALSO
 
 L<bos_create(8)>,
index 01ac948556ebce5b07754977720f3890c9263002..aa75e9b7c1dffdd9eb34dd7fa03991f0c53c99d3 100644 (file)
@@ -51,6 +51,19 @@ issue commands from the B<bos> and B<vos> suites.
 
 =back
 
+The BOS Server is configured via the F<BosConfig> configuration file.
+Normally, this file is managed via the B<bos> command suite rather than
+edited directly.  See the L<BosConfig(5)> man page for the syntax of this
+file.
+
+The BOS Server will rewrite B<BosConfig> when shutting down, so changes
+made manually to it will be discarded.  Instead, to change the BOS Server
+configuration only for the next restart of B<bosserver>, create a file
+named F</usr/afs/local/BosConfig.new>.  If B<BosConfig.new> exists when
+B<bosserver> starts, it is renamed to F</usr/afs/local/BosConfig>,
+removing any existing file by that name, before B<bosserver> reads its
+configuration.
+
 The BOS Server logs a default set of important events in the file
 F</usr/afs/logs/BosLog>. To record the name of any user who performs a
 privileged B<bos> command (one that requires being listed in the
index 99f6579443c850d45f2f0cc108fb8a23c0dd7710..4c5159e46d8b8c0d70863a08b743233c0cd664d7 100644 (file)
@@ -293,7 +293,6 @@ ReadBozoFile(char *aname)
            if (code < 0)
                perror("bosconfig rename");
        }
-#ifdef BOS_NEW_CONFIG
        if (access(AFSDIR_SERVER_BOZCONFNEW_FILEPATH, 0) == 0) {
            code =
                renamefile(AFSDIR_SERVER_BOZCONFNEW_FILEPATH,
@@ -301,7 +300,6 @@ ReadBozoFile(char *aname)
            if (code < 0)
                perror("bosconfig rename");
        }
-#endif
     }
 
     /* setup default times we want to do restarts */