1nisdefaults(1) User Commands nisdefaults(1)
2
3
4
6 nisdefaults - display NIS+ default values
7
9 nisdefaults [-adghprstv]
10
11
13 The nisdefaults utility prints the default values that are returned by
14 calls to the NIS+ local name functions (see nis_local_names(3NSL)).
15 With no options specified, all defaults will be printed in a verbose
16 format. With options, only that option is displayed in a terse form
17 suitable for shell scripts. See the example below.
18
20 The following options are supported:
21
22 -a Print all defaults in a terse format.
23
24
25 -d Print the default domain name.
26
27
28 -g Print the default group name.
29
30
31 -h Print the default host name.
32
33
34 -p Print the default principal name.
35
36
37 -r Print the default access rights with which new objects will be
38 created.
39
40
41 -s Print the default directory search path.
42
43
44 -t Print the default time to live value.
45
46
47 -v Print the defaults in a verbose format. This prepends an identi‐
48 fying string to the output.
49
50
52 Example 1 Printing NIS+ defaults
53
54
55 The following prints the NIS+ defaults for a root process on machine
56 example in the foo.bar. domain:
57
58
59 example# nisdefaults
60 Principal Name : example.foo.bar.
61 Domain Name : foo.bar.
62 Host Name : example.foo.bar.
63 Group Name :
64 Access Rights : −−−−rmcdr−−−r−−−
65 Time to live : 12:00:00
66 Search Path : foo.bar.
67
68
69
70 Example 2 Setting a variable in the shell script
71
72
73 This example sets a variable in a shell script to the default domain:
74
75
76 DOMAIN=`nisdefaults -d`
77
78
79
80 Example 3 Printing the default time to live in verbose format
81
82
83 This example prints out the default time to live in a verbose format:
84
85
86 example% nisdefaults -tv
87 Time to live : 12:00:00
88
89
90
91 Example 4 Printing the time to live in terse format
92
93
94 This example prints out the time to live in the terse format:
95
96
97 example% nisdefaults -t
98 43200
99
100
101
103 Several environment variables affect the defaults associated with a
104 process.
105
106 NIS_DEFAULTS This variable contains a defaults string that will
107 override the NIS+ standard defaults. The defaults
108 string is a series of tokens separated by colons. These
109 tokens represent the default values to be used for the
110 generic object properties. All of the legal tokens are
111 described below.
112
113 ttl=time This token sets the default time to
114 live for objects that are created.
115 The value time is specified in the
116 format as defined by the nischttl(1)
117 command. The default value is 12
118 hours.
119
120
121 owner=ownername This token specifies that the NIS+
122 principal ownername should own cre‐
123 ated objects. The default for this
124 value is the principal who is exe‐
125 cuting the command.
126
127
128 group=groupname This token specifies that the group
129 groupname should be the group owner
130 for created objects. The default is
131 NULL.
132
133
134 access=rights This token specifies the set of
135 access rights that are to be granted
136 for created objects. The value
137 rights is specified in the format as
138 defined by the nischmod(1) command.
139 The default value is:
140 −−−−rmcdr−−−r−−−.
141
142
143
144 NIS_GROUP This variable contains the name of the local NIS+
145 group. If the name is not fully qualified, the default
146 domain will be appended to it.
147
148
149 NIS_PATH This variable overrides the default NIS+ directory
150 search path. It contains an ordered list of directories
151 separated by ':' (colon) characters. The '$' (dollar
152 sign) character is treated specially. Directory names
153 that end in '$' have the default domain appended to
154 them, and a '$' by itself is replaced by the list of
155 directories between the default domain and the global
156 root that are at least two levels deep. The default
157 NIS+ directory search path is '$'.
158
159 Refer to the Name Expansion subsection in NIS+[22m(1) for
160 more details.
161
162
164 See attributes(5) for descriptions of the following attributes:
165
166
167
168
169 ┌─────────────────────────────┬─────────────────────────────┐
170 │ ATTRIBUTE TYPE │ ATTRIBUTE VALUE │
171 ├─────────────────────────────┼─────────────────────────────┤
172 │Availability │SUNWnisu │
173 └─────────────────────────────┴─────────────────────────────┘
174
176 nischmod(1), nischttl(1), NIS+[22m(1), nis_local_names(3NSL), attributes(5)
177
179 NIS+ might not be supported in future releases of the Solaris operating
180 system. Tools to aid the migration from NIS+ to LDAP are available in
181 the current Solaris release. For more information, visit
182 http://www.sun.com/directory/nisplus/transition.html.
183
184
185
186SunOS 5.11 2 Dec 2005 nisdefaults(1)