HP Visualize J210XC IRIX to HP-UX Migration Guide - Page 102

Start_mountd=1

Page 102 highlights

Network File System # /usr/sbin/exportfs directory You can issue the exportfs command without adding the directory to the /etc/exports file, and the directory will be added to your server's internal list of exported directories. However, it will stop being exported when you reboot your system or restart NFS, unless you also add it to the /etc/exports file. (Issuing the exportfs command does not change the contents of the /etc/exports file.) Type man 1M exportfs for more information. The /etc/exports file should be owned by root and have mode 644 (-rw-r--r--). To Enable NFS Server Capability 1. In the /etc/rc.config.d/nfsconf file, make sure the NFS_SERVER and START_MOUNTD variables are set to 1, as follows: NFS_SERVER=1 START_MOUNTD=1 2. Issue the following command to run the NFS startup script: # /sbin/init.d/nfs.server start The NFS startup script uses the variables in /etc/rc.config.d/nfsconf to determine which processes to start. The START_MOUNTD variable causes the NFS startup script to start rpc.mountd, the mount daemon. If you need strict security, set the START_MOUNTD variable to 0, and configure the rpc.mountd daemon with the -e option in the /etc/inetd.conf file. This causes inetd to restart rpc.mountd with each mount request and to check credentials and access permissions for each request. When rpc.mountd is started with the -e option, no TCP port is opened for it. This can cause problems if your NFS clients use the automounter -hosts map, and one of the hosts on your network has a very large /etc/exports file. Before an NFS client automounts directories from a server, it polls the server for a list of its exported directories. If the list is very long, and no TCP port is open for rpc.mountd, the list may become truncated when it is sent over UDP, and the client will be able to automount only a subset of the exported directories from that host. CAUTION: If rpc.mountd is configured in /etc/inetd.conf on your system, set the START_MOUNTD flag to 0. Mounts will fail if rpc.mountd is enabled through both /etc/inetd.conf and /etc/rc.config.d/nfsconf. Unexporting Directories 1. On the NFS server, issue the following command for a list of all the NFS clients that have mounted the directory you want to unexport: # /usr/sbin/showmount -a 2. On every NFS client that has the directory mounted, issue the following command for a list of the process ids and user names of everyone using the mounted directory: # /usr/sbin/fuser -u servername:/directory 3. Warn any users to cd out of the directory, and kill any processes that are using the directory, or wait until the processes terminate. You can use the following command to kill all processes using the directory: # /usr/sbin/fuser -ck local_mount_point 97

  • 1
  • 2
  • 3
  • 4
  • 5
  • 6
  • 7
  • 8
  • 9
  • 10
  • 11
  • 12
  • 13
  • 14
  • 15
  • 16
  • 17
  • 18
  • 19
  • 20
  • 21
  • 22
  • 23
  • 24
  • 25
  • 26
  • 27
  • 28
  • 29
  • 30
  • 31
  • 32
  • 33
  • 34
  • 35
  • 36
  • 37
  • 38
  • 39
  • 40
  • 41
  • 42
  • 43
  • 44
  • 45
  • 46
  • 47
  • 48
  • 49
  • 50
  • 51
  • 52
  • 53
  • 54
  • 55
  • 56
  • 57
  • 58
  • 59
  • 60
  • 61
  • 62
  • 63
  • 64
  • 65
  • 66
  • 67
  • 68
  • 69
  • 70
  • 71
  • 72
  • 73
  • 74
  • 75
  • 76
  • 77
  • 78
  • 79
  • 80
  • 81
  • 82
  • 83
  • 84
  • 85
  • 86
  • 87
  • 88
  • 89
  • 90
  • 91
  • 92
  • 93
  • 94
  • 95
  • 96
  • 97
  • 98
  • 99
  • 100
  • 101
  • 102
  • 103
  • 104
  • 105
  • 106
  • 107
  • 108
  • 109
  • 110
  • 111
  • 112
  • 113
  • 114
  • 115
  • 116
  • 117
  • 118
  • 119
  • 120
  • 121
  • 122
  • 123
  • 124
  • 125

Network File System
97
# /usr/sbin/exportfs directory
You can issue the
exportfs
command without adding the directory to the
/etc/exports
file, and the directory
will be added to your serverĀ±s internal list of exported directories. However, it will stop being exported
when you reboot your system or restart NFS, unless you also add it to the
/etc/exports
file. (Issuing the
exportfs
command does not change the contents of the
/etc/exports
file.) Type
man 1M exportfs
for more
information. The
/etc/exports
file should be owned by
root
and have mode
644
(-rw-r--r--).
To Enable NFS Server Capability
1.
In the
/etc/rc.config.d/nfsconf
file, make sure the
NFS_SERVER
and
START_MOUNTD
variables
are set to
1
, as follows:
NFS_SERVER=1
START_MOUNTD=1
2.
Issue the following command to run the NFS startup script:
# /sbin/init.d/nfs.server start
The NFS startup script uses the variables in
/etc/rc.config.d/nfsconf
to determine which processes to start.
The
START_MOUNTD
variable causes the NFS startup script to start
rpc.mountd
, the
mount
daemon.
If you need strict security, set the
START_MOUNTD
variable to
0
, and configure the
rpc.mountd
daemon with the
-e
option in the
/etc/inetd.conf
file. This causes
inetd
to restart
rpc.mountd
with each
mount
request and to check credentials and access permissions for each request.
When
rpc.mountd
is started with the
-e
option, no TCP port is opened for it. This can cause problems if
your NFS clients use the automounter
-hosts
map, and one of the hosts on your network has a very large
/etc/exports
file. Before an NFS client automounts directories from a server, it polls the server for a list of
its exported directories. If the list is very long, and no TCP port is open for
rpc.mountd
, the list may
become truncated when it is sent over UDP, and the client will be able to automount
only a subset of the
exported directories from that host.
CAUTION:
If rpc.mountd
is configured in
/etc/inetd.conf
on your system, set the
START_MOUNTD
flag to
0
. Mounts will fail if
rpc.mountd
is enabled through both
/etc/inetd.conf
and
/etc/rc.config.d/nfsconf
.
Unexporting Directories
1.
On the NFS server, issue the following command for a list of all the NFS clients that have mounted the
directory you want to unexport:
# /usr/sbin/showmount -a
2.
On every NFS client that has the directory mounted, issue the following command for a list of the
process ids and user names of everyone using the mounted directory:
# /usr/sbin/fuser -u servername:/directory
3.
Warn any users to
cd
out of the directory, and kill any processes that are using the directory, or wait
until the processes terminate. You can use the following command to kill all processes using the
directory:
# /usr/sbin/fuser -ck local_mount_point