


NSRADMIN(8)                                           NSRADMIN(8)


NNAAMMEE
       nsradmin - NetWorker administrative program

SSYYNNOOPPSSIISS
       nnssrraaddmmiinn [ --cc ] [ --ii _f_i_l_e ] [ --ss _s_e_r_v_e_r ] [ --pp _p_r_o_g_n_u_m ] [
       --vv _v_e_r_s_i_o_n ] [ _q_u_e_r_y ]

       nnssrraaddmmiinn [ --cc ] [ --ii _f_i_l_e ] [ --ff _r_e_s_f_i_l_e ... ] [ --tt  _t_y_p_e_-
       _f_i_l_e ] [ _q_u_e_r_y ]

DDEESSCCRRIIPPTTIIOONN
       The  nnssrraaddmmiinn  command is a command-line based administra-
       tive program for the NetWorker system.  Normally  nnssrraaddmmiinn
       monitors  and  modifies  NetWorker resources over the net-
       work.  Commands are entered on standard input, and  output
       is produced on standard output.

       If  nnssrraaddmmiinn  is started without a query it uses a default
       query that selects all  resources  involved  in  NetWorker
       products.

OOPPTTIIOONNSS
       --cc     Use the tteerrmmccaapp(5) and ccuurrsseess(3) packages to imple-
              ment a full-screen  display  mode,  just  like  the
              vviissuuaall command described below.

       --ff _r_e_s_f_i_l_e
              Use  the NetWorker resource file _r_e_s_f_i_l_e instead of
              opening a network connection.  This  should  gener-
              ally  never  be  used,  except  when  the NetWorker
              server is not running.   Multiple  --ff  and  _r_e_s_f_i_l_e
              arguments can be used to start nnssrraaddmmiinn with access
              to more than one file at a time.

       --ii _f_i_l_e
              Take input commands from _f_i_l_e instead of from stan-
              dard  input.  In  this mode, the interactive prompt
              will not be printed.

       --ss _s_e_r_v_e_r
              Open a connection to  the  named  NetWorker  server
              instead  of allowing administration of all servers.
              Useful to limit the number of  resources  if  there
              are  many  servers,  or  to administer when the RAP
              location service is not working.

       --pp _p_r_o_g_r_a_m
              Use the given RPC program  number  instead  of  the
              standard  program  number.   The standard number is
              390109.  This option is  generally  used  only  for
              debugging.

       --tt _t_y_p_e_f_i_l_e
              Use  the  alternate  file  _t_y_p_e_f_i_l_e  to  define RAP



NetWorker rt_1998_4Q.Build.MMaJrFcehra0l8_,0021000                        1





NSRADMIN(8)                                           NSRADMIN(8)


              types.

       --vv _v_e_r_s_i_o_n
              Bind to the NetWorker RAP service  with  the  given
              version  number.  The default is 2.  This option is
              generally used only for debugging.

       _q_u_e_r_y  If  a  query  is  specified  (in  the  form  of  an
              attribute  list), the edit operation (see below) is
              performed on the results of the  query.   See  COM-
              MANDS,  below, for more information on how the edit
              command works.

RREESSOOUURRCCEESS
       Each NetWorker resource is made up  of  a  list  of  named
       attributes.   Each attribute can have zero or more values.
       The attribute names and  values  are  all  represented  by
       printable  strings.   Upper  and lower case is not distin-
       guished on comparisons,  and  spaces  are  ignored  except
       inside the names and values.

       The  format  for specifying attributes and attribute lists
       is:

       _a_t_t_r_i_b_u_t_e ::=  _n_a_m_e [ :: _v_a_l_u_e [ ,, _v_a_l_u_e ]* ]
              An attribute is a name  optionally  followed  by  a
              colon, followed by zero or more values, with values
              separated by commas.  A comma at the end of a  line
              continues the line.

       _a_t_t_r_i_b_u_t_e _l_i_s_t ::= _a_t_t_r_i_b_u_t_e [ ;; _a_t_t_r_i_b_u_t_e ]*
              An  attribute  list is one or more attributes sepa-
              rated by semicolons.  A semicolon at the end  of  a
              line  continues  the  line.  The list is ended by a
              newline that is not preceded by a  comma  or  semi-
              colon.

       Here is an example of an attribute list:

              name: mars;
              type: NSR client;
              remote access: mars, venus, jupiter;

       For  more  information  on attributes, attribute lists and
       the  NetWorker  resource  types,  see   the   rreessoouurrccee(5),
       nnssrr__rreessoouurrccee(5), and rraapp(8) manual pages.

CCOOMMMMAANNDDSS
       At  each input prompt, nnssrraaddmmiinn expects a command name and
       some optional arguments. Command names can be shortened to
       the  smallest  unique  string  (e.g. p for print). Command
       arguments are always specified in the form of an attribute
       list.   Most  commands  operate  on  a  set  of  resources
       returned by  a  _q_u_e_r_y.   The  query  is  specified  as  an



NetWorker rt_1998_4Q.Build.MMaJrFcehra0l8_,0021000                        2





NSRADMIN(8)                                           NSRADMIN(8)


       attribute  list  which is used to match resources with the
       following rules:

              1)  The  resource  must   match   all   the   given
              attributes.

              2) If more than one value is specified the resource
              can match any one of the values.

              3) Values in a query may be in the  form  of  eedd(1)
              style  regular  expressions.   A  pattern  match is
              attempted against all resources  that  contain  the
              specified attribute.

              4)  If  an attribute is specified with no value the
              resource must contain an attribute of that name.

       Thus, a query:
              type:NSR device;
              name:mars, venus;
              test
       will match all resources that have a ttyyppee  attribute  with
       the  value NNSSRR ddeevviiccee and a nnaammee attribute with a value of
       either mmaarrss or vveennuuss,  and  an  attribute  tteesstt  with  any
       value.

       If the query has only one name and no values (for example,
       if there is no semi-colon or colon in it), then  the  pro-
       gram  tries  to guess a more reasonable query. If the name
       is a host  name,  then  the  query  will  select  all  the
       resources  on the given host.  Otherwise, the name will be
       interpreted as a type name,  and  all  resources  of  that
       given type will be selected.

       bbiinndd [_q_u_e_r_y]
              Bind   to   the  service  that  owns  the  resource
              described by _q_u_e_r_y.   If  no  query  is  specified,
              queries are sent to the RAP Resource Directory, and
              update, create, and delete commands to the  service
              that  owns the resource being changed.  On failure,
              the previous service will continue to be used.

       ccrreeaattee _a_t_t_r_i_b_u_t_e _l_i_s_t
              Create a resource with the given attributes. One of
              the  attributes must be ttyyppee to specify a NetWorker
              type that can be created. The ttyyppeess command can  be
              used to find out which types a server supports.

       ddeelleettee [_q_u_e_r_y]
              Delete  the resources that match the current query.
              If a _q_u_e_r_y is specified,  it  becomes  the  current
              query.





NetWorker rt_1998_4Q.Build.MMaJrFcehra0l8_,0021000                        3





NSRADMIN(8)                                           NSRADMIN(8)


       eeddiitt [_q_u_e_r_y]
              Edit  the  resources  that match the current query.
              If a _q_u_e_r_y is specified,  it  becomes  the  current
              query.   If the environment variable EDITOR is set,
              then that editor will be invoked,  otherwise  vvii(1)
              will  be  started.  When the editor exits, nnssrraaddmmiinn
              applies update, delete and create operations  based
              on  the changes to the resources. Be careful to not
              edit the  resource  identifier  attribute,  and  to
              write the file out before exiting the editor.

       hheellpp [_c_o_m_m_a_n_d]
              Print a message describing a command. If no command
              name is given a synopsis of all of the commands  is
              printed.

       pprriinntt [_q_u_e_r_y]
              Print  the  resources that match the current query.
              If a _q_u_e_r_y is specified,  it  becomes  the  current
              query.  If  the current show list is not empty only
              the attributes named in the show list will be  dis-
              played.

       sseerrvveerr [_s_e_r_v_e_r_n_a_m_e]
              Bind  to  the  given  NetWorker server name.  If no
              server is specified, the RAP location service  will
              be used.  On failure, the previous server will con-
              tinue to be used.

       sshhooww [_n_a_m_e;; ...]
              If a name list (really an attribute  list  with  no
              values)  is  specified, add those names to the show
              list. Only these attributes will  be  displayed  in
              subsequent  pprriinntt  commands.   If  no  name list is
              given the show list is cleared,  resulting  in  all
              attributes being shown.

       ttyyppeess  Print a list of all known types.

       uuppddaattee _a_t_t_r_i_b_u_t_e_s
              Update  the resources given by the current query to
              match _a_t_t_r_i_b_u_t_e_s.

       qquuiitt   Exit.

       vviissuuaall  [_q_u_e_r_y]
              Enter a full-screen mode using the ccuurrsseess(3)  pack-
              age  to  step  through  commands  in a perhaps more
              user-friendly manner than the command  line  inter-
              face.   You can get this mode directly using the --cc
              command line argument.

       ooppttiioonn [_l_i_s_t]
              This command enables some  options  to  change  the



NetWorker rt_1998_4Q.Build.MMaJrFcehra0l8_,0021000                        4





NSRADMIN(8)                                           NSRADMIN(8)


              display  of  resources.   With no arguments it dis-
              plays the current options; with a list  of  options
              it  turns  the specified ones on.  The options are:
              DDyynnaammiicc displays all dynamic attributes,  even  the
              normally   hidden   ones.    HHiiddddeenn   displays  all
              attributes,  even   the   normally   hidden   ones.
              RReessoouurrccee  IIDD  displays  the  resource identifier on
              each resource, a number that is used internally  to
              provide sequencing and uniqueness.

       uunnsseett [_l_i_s_t]
              This command turns off the specified option.

       .. [_q_u_e_r_y]
              If  a _q_u_e_r_y is specified, this command will set the
              current query without printing the results  of  the
              query.  Otherwise,  it  will  display  the  current
              query, show list, server binding, and options.

       ?? [_c_o_m_m_a_n_d]
              Same as the hheellpp command above.

EEXXAAMMPPLLEESS
       print type:NSR device
          Print all resources of type NNSSRR ddeevviiccee  and  make  this
          the current query.

       show type; name
          Set  the  show list to only display the attributes ttyyppee
          and nnaammee.

       delete
          Delete all resources that match the current query.

       delete type:NSR device; hostname: mars
          Delete the resource with attributes: ttyyppee::  NNSSRR  ddeevviiccee
          and hhoossttnnaammee:: mmaarrss.

       edit type:NSR notification
          Edit all resources of type NNSSRR nnoottiiffiiccaattiioonn.

SSEEEE AALLSSOO
       eedd(1), vvii(1), ccuurrsseess(3), nnssrr__rreessoouurrccee(5), tteerrmmccaapp(5),
       nnssrr(8) rraapp(8), rraappdd(8).

DDIIAAGGNNOOSSTTIICCSS
       The following exit status values are meaningful:


       0      Interactive mode exited normally.

       1      There was a usage or other non-query related error.

       2      When  reading  input  from a file (--ii _f_i_l_e), one or



NetWorker rt_1998_4Q.Build.MMaJrFcehra0l8_,0021000                        5





NSRADMIN(8)                                           NSRADMIN(8)


              more RAP operations failed.  This status  is  never
              returned interactively.























































NetWorker rt_1998_4Q.Build.MMaJrFcehra0l8_,0021000                        6


