Linux and UNIX Man Pages

Linux & Unix Commands - Search Man Pages

makedbm(8) [osf1 man page]

makedbm(8)						      System Manager's Manual							makedbm(8)

NAME
makedbm - Makes a Network Information Service (NIS) dbm file SYNOPSIS
/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 out- file /var/yp/makedbm [-u dbmfilename] OPTIONS
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. Cre- ates a special entry with the key yp_input_file. Creates a special entry with the key yp_secure_file. This causes the makedbm command to write a secure map. The key value ypserver looks for YP_SECURE. Creates a special entry with the key yp_output_name. Creates a special entry with the key yp_domain_name. Creates a special entry with the key yp_master_name. If no master host name is specified, yp_mas- ter_name will be set to the local host name. Undoes a dbm file. That is, prints out a dbm file one entry per line, with a single space separating keys from values. DESCRIPTION
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. Each line of the input file is converted to a single dbm 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 the date of infile. RESTRICTIONS
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 data- base 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
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. The percent sign (%) signifies the system prompt. % awk 'BEGIN { FS = ":"; OFS = " "; } { print $1, $0 }' /etc/passwd > ptmp % makedbm ptmp passwd.byname % rm ptmp The awk command creates the file ptmp which is in a form usable by makedbm. The makedbm command uses the ptmp file to create the database files. The rm command removes the ptmp file. The following is an example of the makedb command used with the btree format database routine to store NIS maps. makedbm -a b ... SEE ALSO
Commands: yppasswd(1), ypmake(8) Functions: btree(3), dbm(3), dbopen(3), hash(3), ndbm(3) makedbm(8)

Check Out this Related Man Page

makedbm(1M)						  System Administration Commands					       makedbm(1M)

NAME
makedbm - make a dbm file, or get a text file from a dbm file SYNOPSIS
makedbm [-b] [-l] [-s] [-E] [-i yp_input_file] [-o yp_output_name] [-d yp_domain_name] [-m yp_master_name] [-S delimiter] [-D num- ber_of_delimiters] infile outfile makedbm [-u dbmfilename] DESCRIPTION
The makedbm utility takes the infile and converts it to a pair of files in ndbm format (see ndbm(3C)), namely outfile.pag and outfile.dir. Each line of the input file is converted to a single dbm record. All characters up to the first TAB or SPACE form the key, and the rest of the line is the data. If a line ends with `' (backslash), the data for that record is continued on to the next line. makedbm does not treat `#' (pound-sign) as a special character. Because makedbm is mainly used in generating dbm files for the NIS name service, it generates a special entry with the key yp_last_modi- fied, which is the date of infile (or the current time, if infile is `-'). The entries that have keys with the prefix yp_ are interpreted by NIS server utilities. OPTIONS
The following options are supported: -b Insert the YP_INTERDOMAIN into the output. This key causes ypserv(1M) to use DNS for host name and address lookups for hosts not found in the maps. -d yp_domain_name Create a special entry with the key yp_domain_name. -D number_of delimiters Specify number_of_delimiters to skip before forming the key. -E Delimiters are escaped. -i yp_input_file Create a special entry with the key yp_input_file. -l Lower case. Convert the keys of the given map to lower case, so that, for example, host name matches succeed inde- pendent of upper or lower case distinctions. -m yp_master_name Create a special entry with the key yp_master_name. If no master host name is specified, yp_master_name is set to the local host name. -o yp_output_name Create a special entry with the key yp_output_name. -s Secure map. Accept connections from secure NIS networks only. -S delimiter Specify the delimiter to use instead of the default delimiter for forming the key. -u dbmfilename Undo a dbm file. Prints out the file in text format, one entry per line, with a single space separating keys from values. OPERANDS
The following operands are supported: infile Input file for makedbm. If infile is `-' (dash), the standard input is read. outfile One of two output files in ndbm format: outfile.pag and outfile.dir. ATTRIBUTES
See attributes(5) for descriptions of the following attributes: +-----------------------------+-----------------------------+ | ATTRIBUTE TYPE | ATTRIBUTE VALUE | +-----------------------------+-----------------------------+ |Availability |SUNWcsu | +-----------------------------+-----------------------------+ SEE ALSO
ypserv(1M), ndbm(3C), attributes(5) SunOS 5.10 17 Aug 1999 makedbm(1M)
Man Page