1share(1M)               System Administration Commands               share(1M)
2
3
4

NAME

6       share - make local resource available for mounting by remote systems
7

SYNOPSIS

9       share [-p] [-F FSType] [-o specific_options] [-d description]
10            [pathname]
11
12

DESCRIPTION

14       The  share command exports, or makes a resource available for mounting,
15       through a remote file system of type FSType. If the option -F FSType is
16       omitted,  the first file system type listed in /etc/dfs/fstypes is used
17       as  default.  For  a  description  of   NFS   specific   options,   see
18       share_nfs(1M).  pathname is the pathname of the directory to be shared.
19       When invoked with no arguments, share displays all shared file systems.
20

OPTIONS

22       -d description
23
24           The -d flag may be used to provide a description  of  the  resource
25           being shared.
26
27
28       -F FSType
29
30           Specify the filesystem type.
31
32
33       -o specific_options
34
35           The  specific_options  are  used  to  control  access of the shared
36           resource. (See share_nfs(1M) for the NFS  specific  options.)  They
37           may be any of the following:
38
39           rw
40
41               pathname  is shared read/write to all clients. This is also the
42               default behavior.
43
44
45           rw=client[:client]...
46
47               pathname is shared read/write only to the  listed  clients.  No
48               other systems can access pathname.
49
50
51           ro
52
53               pathname is shared read-only to all clients.
54
55
56           ro=client[:client]...
57
58               pathname  is  shared  read-only  only to the listed clients. No
59               other systems can access pathname.
60
61           Separate multiple options with commas. Separate  multiple  operands
62           for an option with colons. See EXAMPLES.
63
64
65       -p
66
67           Causes the share operation to persist across reboots.
68
69

EXAMPLES

71       Example 1 Sharing a Read-Only Filesystem
72
73
74       This line will share the /disk file system read-only at boot time.
75
76
77         share -F nfs -o ro /disk
78
79
80
81       Example 2 Invoking Multiple Options
82
83
84       The  following command shares the filesystem /export/manuals, with mem‐
85       bers of the netgroup having read-only access and users on the specified
86       host having read-write access.
87
88
89         share -F nfs -o ro=netgroup_name,rw=host1:host2:host3 /export/manuals
90
91
92

FILES

94       /etc/dfs/dfstab
95
96           List  of  share commands to be executed at boot time. Note that you
97           can invoke share from  a  command  line  and  use  the  -p  option,
98           described above, as an alternative to editing this file.
99
100
101       /etc/dfs/fstypes
102
103           List of file system types; NFS is the default.
104
105
106       /etc/dfs/sharetab
107
108           System record of shared file systems.
109
110

ATTRIBUTES

112       See attributes(5) for descriptions of the following attributes:
113
114
115
116
117       ┌─────────────────────────────┬─────────────────────────────┐
118       │      ATTRIBUTE TYPE         │      ATTRIBUTE VALUE        │
119       ├─────────────────────────────┼─────────────────────────────┤
120       │Availability                 │SUNWcsu                      │
121       └─────────────────────────────┴─────────────────────────────┘
122

SEE ALSO

124       mountd(1M),   nfsd(1M),   share_nfs(1M),   shareall(1M),   unshare(1M),
125       attributes(5)
126

NOTES

128       Export (old terminology): file system sharing used to be called export‐
129       ing  on  SunOS  4.x,  so  the  share  command  used  to  be  invoked as
130       exportfs(1B) or /usr/sbin/exportfs.
131
132
133       If share commands are invoked multiple times on  the  same  filesystem,
134       the  last  share  invocation supersedes the previous—the options set by
135       the last share command replace the old options. For example,  if  read-
136       write permission was given to usera on /somefs, then to give read-write
137       permission also to userb on /somefs:
138
139
140       example% share -F nfs -o rw=usera:userb /somefs
141
142
143       This behavior is not  limited  to  sharing  the  root  filesystem,  but
144       applies to all filesystems.
145
146
147
148SunOS 5.11                        23 Jan 2007                        share(1M)
Impressum