Jean-Simon Pendry's paper on amd refers to the use of "ypcat -k"
against the "master map" to get the list of mount point/amd map correspondences, and using that list as command-line arguments to start amd. When I tried to do this with the existing /etc/rc* scripts, I found that I couldn't do this by modifying only /etc/rc.conf: that file gets sourced very early by /etc/rc, well before any networking functionality is present, let alone NIS. Further, I wasn't able to figure out a way to use various levels & types of quoting to defer evaluation of the string to a point subsequent to NIS initialization. As a result, I resorted to hacking /etc/rc.network -- but I did it in a way that ought to be reasonably general, and avoid breakage for anyone else. PR: 6387 Reviewed by: phk Submitted by: David Wolfskill <dhw@whistle.com>
This commit is contained in:
parent
f24a941b31
commit
4cb3dec38f
@ -1,6 +1,6 @@
|
||||
#!/bin/sh -
|
||||
#
|
||||
# $Id: rc.network,v 1.21 1998/04/12 09:47:43 markm Exp $
|
||||
# $Id: rc.network,v 1.22 1998/04/18 10:27:06 brian Exp $
|
||||
# From: @(#)netstart 5.9 (Berkeley) 3/30/91
|
||||
|
||||
# Note that almost all the user-configurable behavior is no longer in
|
||||
@ -238,6 +238,9 @@ network_pass3() {
|
||||
|
||||
if [ "X${amd_enable}" = X"YES" ]; then
|
||||
echo -n ' amd'
|
||||
if [ "X${amd_map_program}" != X"NO" ]; then
|
||||
amd_flags="${amd_flags} `${amd_map_program}`"
|
||||
fi
|
||||
amd -p ${amd_flags} > /var/run/amd.pid 2> /dev/null
|
||||
fi
|
||||
|
||||
|
@ -6,7 +6,7 @@
|
||||
#
|
||||
# All arguments must be in double or single quotes.
|
||||
#
|
||||
# $Id: rc.conf,v 1.44 1998/04/12 09:47:41 markm Exp $
|
||||
# $Id: rc.conf,v 1.45 1998/04/18 10:27:04 brian Exp $
|
||||
|
||||
##############################################################
|
||||
### Important initial Boot-time options #####################
|
||||
@ -54,6 +54,7 @@ kerberos_stash="" # Is the kerberos master key stashed?
|
||||
rwhod_enable="NO" # Run the rwho daemon (or NO).
|
||||
amd_enable="NO" # Run amd service with $amd_flags (or NO).
|
||||
amd_flags="-a /net -c 1800 -k i386 -d my.domain -l syslog /host /etc/amd.map"
|
||||
amd_map_program="NO" # Can be set to "ypcat -k amd.master"
|
||||
nfs_client_enable="NO" # This host is an NFS client (or NO).
|
||||
nfs_client_flags="-n 4" # Flags to nfsiod (if enabled).
|
||||
nfs_server_enable="NO" # This host is an NFS server (or NO).
|
||||
|
@ -1,6 +1,6 @@
|
||||
#!/bin/sh -
|
||||
#
|
||||
# $Id: rc.network,v 1.21 1998/04/12 09:47:43 markm Exp $
|
||||
# $Id: rc.network,v 1.22 1998/04/18 10:27:06 brian Exp $
|
||||
# From: @(#)netstart 5.9 (Berkeley) 3/30/91
|
||||
|
||||
# Note that almost all the user-configurable behavior is no longer in
|
||||
@ -238,6 +238,9 @@ network_pass3() {
|
||||
|
||||
if [ "X${amd_enable}" = X"YES" ]; then
|
||||
echo -n ' amd'
|
||||
if [ "X${amd_map_program}" != X"NO" ]; then
|
||||
amd_flags="${amd_flags} `${amd_map_program}`"
|
||||
fi
|
||||
amd -p ${amd_flags} > /var/run/amd.pid 2> /dev/null
|
||||
fi
|
||||
|
||||
|
@ -1,6 +1,6 @@
|
||||
#!/bin/sh -
|
||||
#
|
||||
# $Id: rc.network,v 1.21 1998/04/12 09:47:43 markm Exp $
|
||||
# $Id: rc.network,v 1.22 1998/04/18 10:27:06 brian Exp $
|
||||
# From: @(#)netstart 5.9 (Berkeley) 3/30/91
|
||||
|
||||
# Note that almost all the user-configurable behavior is no longer in
|
||||
@ -238,6 +238,9 @@ network_pass3() {
|
||||
|
||||
if [ "X${amd_enable}" = X"YES" ]; then
|
||||
echo -n ' amd'
|
||||
if [ "X${amd_map_program}" != X"NO" ]; then
|
||||
amd_flags="${amd_flags} `${amd_map_program}`"
|
||||
fi
|
||||
amd -p ${amd_flags} > /var/run/amd.pid 2> /dev/null
|
||||
fi
|
||||
|
||||
|
@ -1,6 +1,6 @@
|
||||
#!/bin/sh -
|
||||
#
|
||||
# $Id: rc.network,v 1.21 1998/04/12 09:47:43 markm Exp $
|
||||
# $Id: rc.network,v 1.22 1998/04/18 10:27:06 brian Exp $
|
||||
# From: @(#)netstart 5.9 (Berkeley) 3/30/91
|
||||
|
||||
# Note that almost all the user-configurable behavior is no longer in
|
||||
@ -238,6 +238,9 @@ network_pass3() {
|
||||
|
||||
if [ "X${amd_enable}" = X"YES" ]; then
|
||||
echo -n ' amd'
|
||||
if [ "X${amd_map_program}" != X"NO" ]; then
|
||||
amd_flags="${amd_flags} `${amd_map_program}`"
|
||||
fi
|
||||
amd -p ${amd_flags} > /var/run/amd.pid 2> /dev/null
|
||||
fi
|
||||
|
||||
|
@ -1,6 +1,6 @@
|
||||
#!/bin/sh -
|
||||
#
|
||||
# $Id: rc.network,v 1.21 1998/04/12 09:47:43 markm Exp $
|
||||
# $Id: rc.network,v 1.22 1998/04/18 10:27:06 brian Exp $
|
||||
# From: @(#)netstart 5.9 (Berkeley) 3/30/91
|
||||
|
||||
# Note that almost all the user-configurable behavior is no longer in
|
||||
@ -238,6 +238,9 @@ network_pass3() {
|
||||
|
||||
if [ "X${amd_enable}" = X"YES" ]; then
|
||||
echo -n ' amd'
|
||||
if [ "X${amd_map_program}" != X"NO" ]; then
|
||||
amd_flags="${amd_flags} `${amd_map_program}`"
|
||||
fi
|
||||
amd -p ${amd_flags} > /var/run/amd.pid 2> /dev/null
|
||||
fi
|
||||
|
||||
|
@ -1,6 +1,6 @@
|
||||
#!/bin/sh -
|
||||
#
|
||||
# $Id: rc.network,v 1.21 1998/04/12 09:47:43 markm Exp $
|
||||
# $Id: rc.network,v 1.22 1998/04/18 10:27:06 brian Exp $
|
||||
# From: @(#)netstart 5.9 (Berkeley) 3/30/91
|
||||
|
||||
# Note that almost all the user-configurable behavior is no longer in
|
||||
@ -238,6 +238,9 @@ network_pass3() {
|
||||
|
||||
if [ "X${amd_enable}" = X"YES" ]; then
|
||||
echo -n ' amd'
|
||||
if [ "X${amd_map_program}" != X"NO" ]; then
|
||||
amd_flags="${amd_flags} `${amd_map_program}`"
|
||||
fi
|
||||
amd -p ${amd_flags} > /var/run/amd.pid 2> /dev/null
|
||||
fi
|
||||
|
||||
|
@ -1,6 +1,6 @@
|
||||
#!/bin/sh -
|
||||
#
|
||||
# $Id: rc.network,v 1.21 1998/04/12 09:47:43 markm Exp $
|
||||
# $Id: rc.network,v 1.22 1998/04/18 10:27:06 brian Exp $
|
||||
# From: @(#)netstart 5.9 (Berkeley) 3/30/91
|
||||
|
||||
# Note that almost all the user-configurable behavior is no longer in
|
||||
@ -238,6 +238,9 @@ network_pass3() {
|
||||
|
||||
if [ "X${amd_enable}" = X"YES" ]; then
|
||||
echo -n ' amd'
|
||||
if [ "X${amd_map_program}" != X"NO" ]; then
|
||||
amd_flags="${amd_flags} `${amd_map_program}`"
|
||||
fi
|
||||
amd -p ${amd_flags} > /var/run/amd.pid 2> /dev/null
|
||||
fi
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user