admnetwork(1M) DG/UX R4.11MU05 admnetwork(1M)
NAME
admnetwork - manage network database
SYNOPSIS
admnetwork -o add [ -y ] [ -l alias-list ] -a network-address
network-name
admnetwork -o modify [ -y ] [ -n new-network-name ] [ -a network-
address ] [ -l alias-list ] network-name
admnetwork -o delete [ -yq ] network-name ...
admnetwork -o list [ -y ] [ -qv ] [ -s ] [ network-name ... ]
DESCRIPTION
admnetwork manages the local or the NIS (YP) network database. The
network(4) database consists of a list of network names and the
Internet address for each.
Operations
add Add a new network entry.
modify Change an existing entry to contain a new network name or a
new network address, or both.
delete Remove an entry from the network database.
list List one or more entries from the network database.
Information is listed about each of the network-names
given; if network-name is "all", information about all
networks is listed.
Options
-y Perform the requested operation on the global NIS database.
Without this option, the requested operation is performed
on the local database in the /etc directory. If specified
with the add, delete, or modify operations, this option is
valid only if the machine on which the command is run is
the NIS master. The -y option uses the default domain name
derived from the SRC_DIR variable specified in the NIS
makefile (/etc/yp/Makefile).
-a network-address
network-address is the Internet address of the network. If
this option is excluded on modify, the current Internet
address for the network is preserved.
-l alias-list
alias-list is a comma-separated list of aliases by which
the network can be referenced. If this option is excluded
on modify, the current alias list for the network is
preserved.
-q "Quiet." Produce an unformatted listing (i.e. no headers,
fields delimited by a single space). When this option is
used with the delete operation, no confirmation is
presented before the network-name is deleted.
-s "Sort." Sort the listing by network name.
-v "Verbose." Produce a formatted listing with headers and
aligned columns. This is the default.
admnetwork expects all network addresses to be of the form
a.b.c.d,
where a is a decimal number between 0 and 224, and b, c, and d are
decimal numbers between 0 and 255. The address must have all four
octets.
OUTPUT
The list operation writes its output to stdout.
The verbose form of the list operation outputs the name and Internet
address for each network. Information is printed in aligned columns
with column headers.
If -q option is specified with the list operation, headers are
suppressed and each entry is printed on a separate line. The fields
within the entry are delimited by a single space, and are in the
following order:
network_name internet_address
FILES
/etc/networks
Local networks database file.
DIAGNOSTICS
Warnings
None.
Errors
- The -y option is specified for an add, delete, or modify
operation and the host is not the NIS master.
- The add operation is requested, and network-name or network-
address already exists.
- The modify operation is requested, and new-network-name or
network-address already exists.
- The delete or modify operation is requested, and network-name
does not exist.
- The network-address is not a valid network address.
- The -y option is given, and there is an error exporting NIS maps.
Exit Codes
0 The operation was successful.
1 The operation was unsuccessful.
2 The operation failed due to access restrictions.
3 There was an error in the command line. does not exist.
NOTES
You must have appropriate privilege to the networks database to use
the add, delete, and modify operations. On a traditional DG/UX
system, appropriate privilege means that you have superuser
privilege, or an effective UID of root. On a system that supports
the DG/UX Capability option, appropriate privilege is defined as
having one one or more specific capabilities enabled in the effective
capability set of the user. See capdefaults(5) for the default
capabilities for this command.
SEE ALSO
domainname(1), sysadm(1M), networks(4). capdefaults(5).
Licensed material--property of copyright holder(s)