makedbm [ -u dbmfilename ]
makedbm takes infile and converts it to a pair of files in ndbm.3 format, 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 `\', then the data for that record is continued on to the next line. It is left for the clients of the Network Information Service (NIS) to interpret #; makedbm does not itself treat it as a comment character. infile can be `-', in which case the standard input is read.
makedbm is meant to be used in generating dbm files for the NIS service, and it generates a special entry with the key yp_last_modified, which is the date of infile (or the current time, if infile is `-').
It is easy to write shell scripts to convert standard files such as /etc/passwd to the key value form used by makedbm. For example:
#!/bin/awk -f BEGIN { FS = ":"; OFS = "\t"; } { print $1, $0 }
takes the /etc/passwd file and converts it to a form that can be read by makedbm to make the NIS file passwd.byname. That is, the key is a username, and the value is the remaining line in the /etc/passwd file.
The Network Information Service (NIS) was formerly known as Sun Yellow Pages (YP). The functionality of the two remains the same; only the name has changed.
Created by unroff & hp-tools. © somebody (See intro for details). All Rights Reserved. Last modified 11/5/97