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

  man pages->IRIX man pages -> makemdbm (1)              
Title
Content
Arch
Section
 

Contents


makemdbm(1M)							  makemdbm(1M)


NAME    [Toc]    [Back]

     makemdbm, makedbm - make an NIS mdbm file

SYNOPSIS    [Toc]    [Back]

     makemdbm [	-b ] [ -l ] [ -i yp_input_file ] [ -o yp_output_NAME ]
	  [ -d yp_domain_NAME ]	[ -m yp_master_NAME ] infile outfile
     makemdbm [	-u mdbmfilename	]

DESCRIPTION    [Toc]    [Back]

     makemdbm takes infile and converts	it to a	file in	mdbm(3B) format.  Each
     line of the input file is converted to a single mdbm 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 standard
     input is read.

     makemdbm is meant to be used in generating	mdbm files for NIS.  It
     generates a special entry with the	key yp_last_modified, which is the
     date of infile (or	the current time, if infile is -).

OPTIONS    [Toc]    [Back]

     -l	  Convert all uppercase	characters in the keys to lowercase.

     -i	yp_input_file
	  Create a special entry with the key YP_INPUT_FILE.

     -o	yp_output_NAME
	  Create a special entry with the key YP_OUTPUT_NAME.

     -d	yp_domain_NAME
	  Create a special entry with the key YP_DOMAIN_NAME.

     -m	yp_master_NAME
	  Create a special entry with the key YP_MASTER_NAME.  If no master
	  hostname is specified, yp_master_NAME	is set to the local hostname.

     -u	mdbmfilename
	  Undo a mdbm file.  That is, print out	a mdbm file one	entry per
	  line,	with a single space separating keys from values.

EXAMPLE    [Toc]    [Back]

     It	is easy	to write shell scripts to convert standard files such as
     /etc/passwd to the	key value form used by makemdbm.  For example,

	  #!/usr/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
     makemdbm to make the NIS file passwd.byname.  That	is, the	key is a



									Page 1






makemdbm(1M)							  makemdbm(1M)



     username, and the value is	the remaining line in the /etc/passwd file.

SEE ALSO    [Toc]    [Back]

      
      
     yppasswd(1), nis(1M), mdbm(3B).


									PPPPaaaaggggeeee 2222
[ Back ]
 Similar pages
Name OS Title
mdbm_remove IRIX invalidate and remove mdbm files
link Linux make a new name for a file
symlink Linux make a new name for a file
mktemp IRIX make a unique file name
mkdir HP-UX make a directory file
mkfifo NetBSD make a fifo file
mkfifo FreeBSD make a fifo file
elf_begin IRIX make a file descriptor
mk.conf NetBSD make configuration file
mkdir NetBSD make a directory file
Copyright © 2004-2005 DeniX Solutions SRL
newsletter delivery service