Museum

Home

Lab Overview

Retrotechnology Articles

⇒ Online Manual

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

domainname(1)

yp(3R)

protocols(4)

services(4)



admservice(1M)                   DG/UX R4.11                  admservice(1M)


NAME
       admservice - manage service database

SYNOPSIS
       admservice -o add [ -y ] [ -l alias-list ] -n port-number -p protocol
                 service-name

       admservice -o delete [ -y ] -p protocol service-name

       admservice -o modify [ -y ] [ -s new-service-name ] [ -P new-protocol
                 ] [ -n port-number ] [ -l new-alias-list ] -p protocol
                 service-name

       admservice -o list [ -y ] [ -qv ] [ all | service-name ...  ]

       admservice -o search [ -y ] -p protocol service-name

DESCRIPTION
       admservice manages the local or the NIS (YP) services(4) database.
       Each services database entry consists of: service-name, protocol,
       port-number, and a list of aliases.

   Operations
       add       Add a new service entry into the services database.

       modify    Change a service entry from the services database.  The
                 service-name, protocol, port-number, and alias-list may be
                 changed.

       delete    Remove a service entry from the services database.

       list      List one or more service entries from the services
                 database.  Information is listed about each of the service-
                 names; if no service-names are given or if service-name is
                 all, information about all services is listed.

       search    Search for a service entry from the services database.  If
                 the entry is found, it is echoed to stdout.  If the entry
                 is not found, the operation exits with an error code.

   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).

       -p protocol
                 protocol is the transport protocol for this service(e.g.
                 tcp, udp).  The protocol must be found in the protocols(4)
                 database.

       -P new-protocol
                 new-protocol is the new transport protocol that replaces
                 protocol in the modify operation.  Without this option the
                 current protocol is preserved.

       -n port-number
                 port-number is the well-known port number assigned for this
                 service.  If this option is omitted in the modify
                 operation, the current port-number is preserved.

       -l alias-list
                 alias-list is a list of aliases by which the service can be
                 referenced.  If this option is omitted in the modify
                 operation, the current alias-list is preserved.

       -s new-service
                 new-protocol is the new service name that replaces service-
                 name in the modify operation.  Without this option the
                 current service is preserved.

       -q        "Quiet."  Produce an unformatted listing (i.e. no headers,
                 fields delimited by a single space).

       -v        "Verbose."  Produce a formatted listing with headers and
                 aligned columns.  This is enabled by default.

FILES
       /etc/services
                 Local services database file.

OUTPUT
       The list and search operations write their output to stdout.  The
       verbose form of the list operation outputs information 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:
                  service_name protocol port_number alias1 alias2 aliasN ...

       This format is also used by the search operation.

DIAGNOSTICS
   Warnings
        -  The delete operation is requested, and service-name/protocol does
           not exist.

   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 service-name/protocol already
           exists.

        -  The modify operation is requested, and new-service-name/new-
           protocol already exists.

        -  The modify or search operation is requested, and service-
           name/protocol does not exist.

        -  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
       Access to the add, delete, and modify operations is based on write
       permissions on the services database file.  Generally, only the
       system administrator has this access.  Access to the list and search
       operations is based on read permissions on the services database
       file.  Generally, all have this access.

SEE ALSO
       domainname(1), yp(3R), protocols(4), services(4).


Licensed material--property of copyright holder(s)

Typewritten Software • bear@typewritten.org • Edmonds, WA 98026