*nix Documentation Project
·  Home
 +   man pages
·  Linux HOWTOs
·  FreeBSD Tips
·  *niX Forums

  man pages->Tru64 Unix man pages -> makedbm (8)              
Title
Content
Arch
Section
 

makedbm(8)

Contents


NAME    [Toc]    [Back]

       makedbm  -  Makes  a Network Information Service (NIS) map
       file

SYNOPSIS    [Toc]    [Back]

       /var/yp/makedbm [-i yp_input_file] [-s yp_secure_name] [-a
       method]   [-o   yp_output_name]  [-d  yp_domain_name]  [-m
       yp_master_name] infile outfile

       /var/yp/makedbm [-a method] -u  infile

OPTIONS    [Toc]    [Back]

       Specifies that NIS maps are to be stored  in  one  of  the
       following  formats: btree -- Recommended when creating and
       maintaining very large maps.   dbm/ndbm  --  For  backward
       compatibility. This is the default.  hash -- A potentially
       quicker method for managing small maps.  Creates a special
       entry  with  the  key  YP_INPUT_FILE,  which is set to the
       specified value.  Creates a special  entry  with  the  key
       YP_SECURE,  which  is  set  to  the  specified value. This
       causes the makedbm command to write a secure map.  Creates
       a  special entry with the key YP_OUTPUT_NAME, which is set
       to the specified value.  Creates a special entry with  the
       key  YP_DOMAIN_NAME,  which is set to the specified value.
       Creates a special entry with the key YP_MASTER_NAME, which
       is  set  to the specified value. If no master host name is
       specified, YP_MASTER_NAME will be set to  the  local  host
       name.  Undoes a dbm file. Prints the file to standard output
 in a plain text format, one entry  per  line,  with  a
       single space separating keys from values. This option processes
 dbm/ndbm-formatted files by default. To undo  btree
       or  hash  files, you must use the -a option in combination
       with the -u option to specify the format.

DESCRIPTION    [Toc]    [Back]

       The makedbm command takes the file specified by the  argument
  infile and converts it to a single file or a pair of
       files in dbm(3), btree(3), or hash(3) format.  The  dbm(3)
       files  are  stored  as  outfile.pag  and  outfile.dir, the
       btree(3)  files  are  stored  as  outfile.btree,  and  the
       hash(3) files are stored as outfile.hash. Each line of the
       input file is converted to a single record. All characters
       up to the first tab or space form the key, and the rest of
       the line is defined as the key's  associated  data.  If  a
       line  ends  with a backslash (\), the data for that record
       is continued onto the next line. It is left for  the  Network
  Information  Service  (NIS) clients to interpret the
       number sign (#); makedbm does not treat it  as  a  comment
       character.   The  infile parameter can be a hyphen (-), in
       which case makedbm reads the standard input.

       The makedbm command is meant  to  be  used  in  generating
       database  files  for  NIS. The makedbm command generates a
       special entry with the key YP_LAST_MODIFIED, which is  set
       to the modification date from infile.






RESTRICTIONS    [Toc]    [Back]

       You  must  use  the same database format for each map in a
       domain. In addition, a server serving multiple NIS domains
       must use the same database format for all domains.

       Although  a  Tru64 UNIX NIS server that takes advantage of
       btree files will be able to store  very  large  maps,  NIS
       slave  servers  that  lack  this feature might have a much
       smaller limit on the number of map entries they  can  handle.
  It may not be possible to distribute very large maps
       from a Tru64 UNIX NIS master server to a slave server that
       lacks  support  for  very large maps.  NIS clients are not
       affected by these enhancements.

EXAMPLES    [Toc]    [Back]

       The following example shows how a combination of  commands
       can  be  used  to make the NIS dbm files passwd.byname.pag
       and passwd.byname.dir from the  /etc/passwd  file:  %  awk
       'BEGIN { FS = ":"; OFS = "\t"; }
        {  print  $1,  $0 }' /etc/passwd > ptmp % /var/yp/makedbm
       ptmp /var/yp/domain_name/passwd.byname % rm ptmp

              The awk command creates the ptmp file, which is  in
              a  form usable by makedbm. The makedbm command uses
              this temporary file to create the  database  files,
              which  it stores in the map file directory for your
              domain, /var/yp/domain_name. The rm command removes
              the  ptmp file.  The following example shows how to
              create the same passwd.byname map in btree  format:
              /var/yp/makedbm          -a          b         ptmp
              /var/yp/domain_name/passwd.byname

              This    command    outputs    a     file     called
              passwd.byname.btree  and  stores it in the map file
              directory  for  your  domain,  /var/yp/domain_name.
              The following example shows how to undo a hash-formatted
 ypservers map and put the output into a temporary
  file  for  editing: /var/yp/makedbm -a h -u
              /var/yp/domain_name/ypservers > tmpfile

              You might undo the ypservers map in this manner  if
              you  need  to add or remove a slave server from the
              domain. See Network  Administration:  Services  for
              the  full  procedure  and  scripts to automate this
              process.

SEE ALSO    [Toc]    [Back]

      
      
       Commands: yppasswd(1), ypmake(8)

       Functions: btree(3), dbm(3), dbopen(3), hash(3), ndbm(3)

       Network Administration: Services



                                                       makedbm(8)
[ Back ]
 Similar pages
Name OS Title
yppasswdd Tru64 server daemon for modifying the Network Information Service (NIS) password file
rpc.yppasswdd Tru64 server daemon for modifying the Network Information Service (NIS) password file
nis_intro Tru64 Network Information Service (NIS) introductory information
nis HP-UX a new version of the network information name service
nis+ HP-UX a new version of the network information name service
NIS+ HP-UX a new version of the network information name service
yp_first Tru64 Network Information Service (NIS) client package
setdomainna HP-UX get/set name of current Network Information Service domain
getdomainna HP-UX get/set name of current Network Information Service domain
yp_next Tru64 Network Information Service (NIS) client package
Copyright © 2004-2005 DeniX Solutions SRL
newsletter delivery service