diff options
| author | Sheldon Hearn <sheldonh@FreeBSD.org> | 2001-12-27 13:41:27 +0000 |
|---|---|---|
| committer | Sheldon Hearn <sheldonh@FreeBSD.org> | 2001-12-27 13:41:27 +0000 |
| commit | d7fb353a4328df9c8f3d2b4735313e36f794538e (patch) | |
| tree | 69e6a4dfd4e1e8c2aab2a8a47eeb1b5f7763d5cb | |
| parent | ca33a43ede6dbaf0049a29341bceeb0f13496eff (diff) | |
Notes
| -rw-r--r-- | etc/defaults/rc.conf | 2 | ||||
| -rw-r--r-- | etc/rc | 33 | ||||
| -rw-r--r-- | share/man/man5/rc.conf.5 | 10 |
3 files changed, 44 insertions, 1 deletions
diff --git a/etc/defaults/rc.conf b/etc/defaults/rc.conf index aeeaea824ace..1f759af7b210 100644 --- a/etc/defaults/rc.conf +++ b/etc/defaults/rc.conf @@ -36,6 +36,8 @@ script_name_sep=" " # Change if your startup scripts' names contain spaces rc_conf_files="/etc/rc.conf /etc/rc.conf.local" fsck_y_enable="NO" # Set to YES to do fsck -y if the initial preen fails. background_fsck="YES" # Attempt to run fsck in the background where possible. +networkfs_types="nfs:NFS smbfs:SMB portalfs:PORTAL" # List of network + # filesystem types for delayed mount at startup. ############################################################## ### Network configuration sub-section ###################### @@ -268,7 +268,16 @@ esac umount -a >/dev/null 2>&1 # Mount everything except nfs filesystems. -mount -a -t nonfs +if [ -z "${networkfs_types}" ]; then + networkfs_types='nfs:NFS smbfs:SMB portalfs:PORTAL' +fi +mount_excludes='no' +for i in ${networkfs_types}; do + fstype=${i%:*} + mount_excludes="${mount_excludes}${fstype}," +done +mount_excludes=${mount_excludes%,} +mount -a -t ${mount_excludes} case $? in 0) @@ -407,6 +416,11 @@ case ${ipv6_enable} in esac # Mount NFS filesystems if present in /etc/fstab +# +# XXX When the vfsload() issues with nfsclient support and related sysctls +# have been resolved, this block can be removed, and the condition that +# skips nfs in the following block (for "other network filesystems") can +# be removed. case "`mount -d -a -t nfs 2> /dev/null`" in *mount_nfs*) # Handle absent nfs client support @@ -430,6 +444,23 @@ case "`mount -d -a -t nfs 2> /dev/null`" in ;; esac +# Mount other network filesystems if present in /etc/fstab +for i in ${networkfs_types}; do + fstype=${i%:*} + fsdecr=${i#*:} + + if [ "${fstype}" = "nfs" ]; then + continue + fi + case "`mount -d -a -t ${fstype}`" in + *mount_${fstype}*) + echo -n "Mounting ${fsdecr} file systems:" + mount -a -t ${fstype} + echo '.' + ;; + esac +done + # Whack the pty perms back into shape. # if ls /dev/tty[pqrsPQRS]* > /dev/null 2>&1; then diff --git a/share/man/man5/rc.conf.5 b/share/man/man5/rc.conf.5 index e2554267dad1..8b4b79e6bdec 100644 --- a/share/man/man5/rc.conf.5 +++ b/share/man/man5/rc.conf.5 @@ -686,6 +686,16 @@ If set to the system will attempt to run .Xr fsck 8 in the background where possible. +.It Va networkfs_types +.Pq Vt str +A whitespace-separated list of network filesystem descriptor pairs, +each consisting of a filesystem type as passed to +.Xr mount 8 +and a human-readable, one-word description, +joined with a colon +.Pq Sq \&: . +This list can be extended as required to accommodate +third-party filesystem support. .It Va syslogd_enable .Pq Vt bool If set to |
