Skip site navigation (1)Skip section navigation (2)

FreeBSD Manual Pages

  
 
  

home | help
dhtadm(1M)		System Administration Commands		    dhtadm(1M)

NAME
       dhtadm -	DHCP configuration table management utility

SYNOPSIS
       dhtadm -C [-r resource] [-p path] [-u uninterpreted]

       dhtadm  -A -s symbol_name -d definition [-r resource] [-p path] [-u un-
       interpreted]

       dhtadm -A -m macro_name -d definition [-r resource] [-p path] [-u unin-
       terpreted]

       dhtadm  -M -s symbol_name -d definition [-r resource] [-p path] [-u un-
       interpreted]

       dhtadm -M -s symbol_name	-n new_name [-r	resource] [-p path]  [-u unin-
       terpreted]

       dhtadm  -M  -m macro_name -n new_name [-r resource] [-p path] [-u unin-
       terpreted]

       dhtadm -M -m macro_name -d definition [-r resource] [-p path] [-u unin-
       terpreted]

       dhtadm -M -m macro_name -e symbol=value [-r resource] [-p path] [-u un-
       interpreted]

       dhtadm -D -s symbol_name	[-r resource] [-p path]	[-u uninterpreted]

       dhtadm -D -m macro_name [-r resource] [-p path] [-u uninterpreted]

       dhtadm -P [-r resource] [-p path] [-u uninterpreted]

       dhtadm -R [-r resource] [-p path] [-u uninterpreted]

       dhtadm -B [-v] [batchfile]

DESCRIPTION
       dhtadm manages the Dynamic Host Configuration Protocol  (DHCP)  service
       configuration  table, dhcptab. You can use it to	add, delete, or	modify
       DHCP configuration macros or options or view the	table. For a  descrip-
       tion of the table format, see dhcptab(4).)

       The  dhtadm  command  can be run	by root, or by other users assigned to
       the DHCP	Management profile. See	rbac(5)	and user_attr(4).

       After you make changes with dhtadm, you should issue a  SIGHUP  to  the
       DHCP server, causing it to read the dhcptab and pick up the changes. Do
       this using the command using  the  pkill	 -HUP  in.dhcpd	 command.  See
       in.dhcpd(1M).

OPTIONS
       One  of	the following function flags must be specified with the	dhtadm
       command:	-A, -B,	-C, -D,	-M, -P or -R.

       The following options are supported:

       -A    Add a symbol or macro definition to the dhcptab table.

	     The following sub-options are required:

	     -d	definition
		   Specify a macro or symbol definition.

		   definition must be enclosed in single quotation marks.  For
		   macros,  use	 the form -d 'symbol=value:symbol=value:'. For
		   symbols, the	definition is a	series of fields that define a
		   symbol's  characteristics. The fields are separated by com-
		   mas.	Use the	form  -d  'context,code,type,granularity,maxi-
		   mum'. See dhcptab(4)	for information	about these fields.

	     -m	macro_name
		   Specify the name of the macro to be added.

		   The	-d  option must	be used	with the -m option. The	-s op-
		   tion	cannot be used with the	-m option.

	     -s	symbol_name
		   Specify the name of the symbol to be	added.

		   The -d option must be used with the -s option. The  -m  op-
		   tion	cannot be used with the	-s option.

       -B    Batch  process  dhtadm commands. dhtadm will read from the	speci-
	     fied file or from standard	input a	series of dhtadm commands  and
	     execute them within the same process. Processing many dhtadm com-
	     mands using this method is	much faster than running an executable
	     batchfile	itself.	 Batch mode is recommended for using dhtadm in
	     scripts.

	     The following sub-option is optional:

	     -v	   Display commands to standard	output as they are processed.

       -C    Create the	DHCP service configuration table, dhcptab.

       -D    Delete a symbol or	macro definition.

	     The following sub-options are required:

	     -m	macro_name
		   Delete the specified	macro.

	     -s	symbol_name
		   Delete the specified	symbol.

       -M    Modify an existing	symbol or macro	definition.

	     The following sub-options are required:

	     -d	definition
		   Specify a macro or symbol definition	to modify.

		   The definition must be enclosed in single quotation	marks.
		   For	macros,	 use the form -d 'symbol=value:symbol=value:'.
		   For symbols,	the definition is a series of fields that  de-
		   fine	 a  symbol's characteristics. The fields are separated
		   by commas. Use  the	form  -d  'context,code,type,granular-
		   ity,maximum'.  See  dhcptab(4)  for information about these
		   fields.

	     -e	   This	sub-option uses	the symbol =value argument. Use	it  to
		   edit	 a  symbol/value  pair within a	macro. To add a	symbol
		   which does not have an associate value, enter:

		   symbol=NULL_VALUE_

		   To delete a symbol definition from a	macro, enter:

		   symbol=

	     -m	   This	sub-option uses	the macro_name argument. The  -n,  -d,
		   or  -e  sub-options	are  legal companions for this sub-op-
		   tion..

	     -n	   This	sub-option uses	the new_name argument and modifies the
		   name	of the object specified	by the -m or -s	sub-option. It
		   is not limited to macros. . Use it to specify a  new	 macro
		   name	or symbol name.

	     -s	   This	 sub-option  uses  the symbol_name argument. Use it to
		   specify a symbol. The -d sub-option is a legal companion.

       -p path
	     Override the dhcpsvc.conf(4) configuration	value for  PATH=  with
	     path.  See	 dhcpsvc.conf(4)  for more details regarding path. See
	     dhcp_modules(5) for information regarding	data  storage  modules
	     for the DHCP service.

       -P    Print (display) the dhcptab table.

       -r data_store_resource
	     Override  the  dhcpsvc.conf(4)  configuration value for RESOURCE=
	     with the data_store_resource specified. See  dhcpsvc.conf(4)  for
	     more  details  on	resource  type.	SeeSolaris DHCP	Service	Devel-
	     oper's Guide for more information about adding support for	 other
	     data  stores.  See	dhcp_modules(5)	for information	regarding data
	     storage modules for the DHCP service.

       -R    Remove the	dhcptab	table.

       -u uninterpreted
	     Data which	will be	ignored	by dhtadm,  but	 passed	 to  currently
	     configured	 public	 module,  to be	interpreted by the data	store.
	     This might	be used	for a database account name or other authenti-
	     cation  or	authorization parameters required by a particular data
	     store. Uninterpreted data is stored within	 RESOURCE_CONFIG  key-
	     word of dhcpsvc.conf(4).  See dhcp_modules(5) for information re-
	     garding data storage modules for the DHCP service.

EXAMPLES
       Example 1: Creating the DHCP Service Configuration Table

       The following command creates the  DHCP	service	 configuration	table,
       dhcptab:

       # dhtadm	-C

       Example 2: Adding a Symbol Definition

       The  following command adds a Vendor option symbol definition for a new
       symbol called MySym to the dhcptab table	in the SUNWfiles  resource  in
       the /var/mydhcp directory:

       # dhtadm	-A -s MySym
	    -d 'Vendor=SUNW.PCW.LAN,20,IP,1,0'
		   -r SUNWfiles	-p /var/mydhcp

       Example 3: Adding a Macro Definition

       The  following  command	adds the aruba macro definition	to the dhcptab
       table. Note that	symbol/value pairs are bracketed with colons (:).

       # dhtadm	-A -m aruba
	    -d ':Timeserv=10.0.0.10 10.0.0.11:DNSserv=10.0.0.1:'

       Example 4: Modifying a Macro Definition

       The following command modifies the Locale macro definition, setting the
       value of	the UTCOffst symbol to 18000 seconds. Note that	any macro def-
       inition which includes the definition of	the Locale macro will  inherit
       this change.

       # dhtadm	-M -m Locale -e	'UTCOffst=18000'

       Example 5: Deleting a Symbol

       The following command deletes the Timeserv symbol from the aruba	macro.
       Note that any macro definition which includes  the  definition  of  the
       aruba macro will	inherit	this change.

       # dhtadm	-M -m aruba -e 'Timeserv='

       Example 6: Adding a Symbol to a Macro

       The following command adds the Hostname symbol to the aruba macro. Note
       that the	Hostname symbol	takes no value,	and thus requires the  special
       value  _NULL_VALUE_. Note also that any macro definition	which includes
       the definition of the aruba macro will inherit this change.

       # dhtadm	-M -m aruba -e 'Hostname=_NULL_VALUE_'

       Example 7: Renaming a Macro

       The following command renames the Locale	macro to MyLocale.  Note  that
       any  Include  statements	 in macro definitions which include the	Locale
       macro will also need to be changed.

       # dhtadm	-M -m Locale -n	MyLocale

       Example 8: Deleting a Symbol Definition

       The following command deletes the MySym symbol  definition.  Note  that
       any macro definitions which use MySym will need to be modified.

       # dhtadm	-D -s MySym

       Example 9: Removing a dhcptab

       The  following  command removes the dhcptab table in the	NIS+ directory
       specified.

       # dhtadm	-R -r SUNWnisplus -p Test.Nis.Plus.

       Example 10: Printing a dhcptab

       The following command prints to standard	output	the  contents  of  the
       dhcptab	that  is  located  in the data store and path indicated	in the
       dhcpsvc.conf file:.

       # dhtadm	-P

       Example 11: Executing dhtadm in Batch Mode

       The following command runs a series of dhtadm commands contained	 in  a
       batch file:

       # dhtadm	-B addmacros

EXIT STATUS
       0     Successful	completion.

       1     Object already exists.

       2     Object does not exist.

       3     Non-critical error.

       4     Critical error.

FILES
       /etc/inet/dhcpsvc.conf

ATTRIBUTES
       See attributes(5) for descriptions of the following attributes:

       +-----------------------------+-----------------------------+
       |      ATTRIBUTE	TYPE	     |	    ATTRIBUTE VALUE	   |
       +-----------------------------+-----------------------------+
       |Availability		     |SUNWdhcsu			   |
       +-----------------------------+-----------------------------+
       |Interface Stability	     |Evolving			   |
       +-----------------------------+-----------------------------+

SEE ALSO
       dhcpconfig(1M),	dhcpmgr(1M),  in.dhcpd(1M), dhcpsvc.conf(4), dhcp_net-
       work(4),	dhcptab(4), hosts(4),  user_attr(4),  attributes(5),  dhcp(5),
       dhcp_modules(5)rbac(5)

       Solaris DHCP Service Developer's	Guide

       System Administration Guide: IP Services

       Alexander,  S., and R. Droms, DHCP Options and BOOTP Vendor Extensions,
       RFC 1533, Lachman Technology, Inc., Bucknell University,	October	1993.

       Droms, R., Interoperation Between DHCP and BOOTP,  RFC  1534,  Bucknell
       University, October 1993.

       Droms, R., Dynamic Host Configuration Protocol, RFC 1541, Bucknell Uni-
       versity,	October	1993.

       Wimer, W., Clarifications and Extensions	for  the  Bootstrap  Protocol,
       RFC 1542, Carnegie Mellon University, October 1993.

SunOS 5.9			  13 Mar 2001			    dhtadm(1M)

NAME | SYNOPSIS | DESCRIPTION | OPTIONS | EXAMPLES | EXIT STATUS | FILES | ATTRIBUTES | SEE ALSO

Want to link to this manual page? Use this URL:
<https://www.freebsd.org/cgi/man.cgi?query=dhtadm&sektion=1m&manpath=SunOS+5.9>

home | help