If you have already installed openafs-client and configured it for
some other cell, you do need to configure it to point to your new
cell for these instructions to work. Stop the AFS client on the
- system with /etc/init.d/openafs-client stop and then run:
+ system with service openafs-client stop and then run:
dpkg-reconfigure openafs-client
if (m:^AFS:) {
print "The AFS client is currently running on this workstation.\n";
print "Please restart this script after running"
- . " /etc/init.d/openafs-client stop\n";
+ . " service openafs-client stop\n";
exit(1);
}
}
# Stop the file server.
print "If the fileserver is not running, this may hang for 30 seconds.\n";
-run("/etc/init.d/openafs-fileserver stop");
+run("service openafs-fileserver stop");
# Get the local hostname. Use the fully-qualified hostname to be safer.
$server = `hostname -f`;
close CELLSERVDB or die "Cannot write to /etc/openafs/server/CellServDB: $!\n";
# Now, we should be able to start bos and add the admin user.
-run("/etc/init.d/openafs-fileserver start");
+run("service openafs-fileserver start");
$shutdown_needed = 1;
run("bos adduser $server $afs_admin -localauth");
unwind("bos removeuser $server $afs_admin -localauth");
or die "ERROR: Cannot create /etc/openafs/ThisCell: $!\n";
print THIS "$cell\n";
close THIS or die "ERROR: Cannot write to /etc/openafs/ThisCell: $!\n";
-run("/etc/init.d/openafs-client force-start");
+run("service openafs-client force-start");
# Verify that AFS has managed to start.
my $afs_running = 0;
# with open AFS files to be killed before unmounting AFS if the runlevel being
# switched to is 0 or 6.
#
-# Warning: This means /etc/init.d/openafs-client stop will kill all processes
+# Warning: This means service openafs-client stop will kill all processes
# with files open in AFS rather than returning an error saying the file system
# is busy. This is probably what you want when the whole system is shutting
# down, but often *not* what you want when just stopping and restarting the
* Switch openafs-fileserver.service to Type=simple and pass -nofork to
bosserver. (Closes: #865962)
* Update for policy version 4.0.0, honor nodoc in DEB_BUILD_OPTIONS
+ * Use service(8) instead of /etc/init.d/* directly in documentation and
+ helper scripts
-- Benjamin Kaduk <kaduk@mit.edu> Thu, 06 Jul 2017 09:19:27 -0500
Normally, most users who install the openafs-client package expect to
run it at boot. However, if you are planning on setting up a new cell
or are on a laptop, you may not want it started at boot time. If you
-choose not to start AFS at boot , run /etc/init.d/openafs-client
+choose not to start AFS at boot , run service openafs-client
force-start to start the client when you wish to run it.
Run Openafs client now and at boot? no
Do you meet these requirements? [y/n] y
If the fileserver is not running, this may hang for 30 seconds.
-/etc/init.d/openafs-fileserver stop
+service openafs-fileserver stop
Stopping AFS Server: bos: could not find entry (can't find cell '<default>' in cell database)
bosserver.
What administrative principal should be used? faheem/admin
/etc/openafs/server/CellServDB already exists, renaming to .old
-/etc/init.d/openafs-fileserver start
+service openafs-fileserver start
Starting AFS Server: bosserver.
bos adduser riverside.dulci.biostat.duke.edu faheem.admin -localauth
pt_util: /var/lib/openafs/db/prdb.DB0: Bad UBIK_MAGIC. Is 0 should be 354545
Waiting for database elections: done.
vos create riverside.dulci.biostat.duke.edu a root.afs -localauth
Volume 536870912 created on partition /vicepa of riverside.dulci.biostat.duke.edu
-/etc/init.d/openafs-client force-start
+service openafs-client force-start
Starting AFS services: afsd: All AFS daemons started.
afsd.
be mounted automatically at boot. However, if you are planning on
setting up a new cell or are on a laptop, you may not want it started at
boot time. If you choose not to start AFS at boot, run
- /etc/init.d/openafs-client force-start to start the client when you wish
+ service openafs-client force-start to start the client when you wish
to run it.
Template: openafs-client/afsdb