Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
N
net-tools
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
net-tools
Commits
2466c758
Commit
2466c758
authored
Aug 29, 2013
by
Bernd Eckenfels
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
hostname: modernized man page
parent
8f124a70
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
48 additions
and
59 deletions
+48
-59
man/en_US/hostname.1
man/en_US/hostname.1
+48
-59
No files found.
man/en_US/hostname.1
View file @
2466c758
.TH HOSTNAME 1 "20
08\-10\-03
" "net\-tools" "Linux System Administrator's Manual"
.TH HOSTNAME 1 "20
13\-08\-29
" "net\-tools" "Linux System Administrator's Manual"
.SH NAME
.SH NAME
hostname \- show or set the system's host name
hostname \- show or set the system's host name
.br
.br
domainname \- show or set the system's NIS/YP domain name
.br
dnsdomainname \- show the system's DNS domain name
dnsdomainname \- show the system's DNS domain name
.br
.br
nisdomainname \- show or set
system's NIS/YP domain name
domainname \- show or set the
system's NIS/YP domain name
.br
.br
ypdomainname \- show or set the
system's NIS/YP domain name
nisdomainname \- show or set
system's NIS/YP domain name
.br
.br
nodename \- show or set the system's DECnet node name
nodename \- show or set the system's DECnet node name
.br
ypdomainname \- show or set the system's NIS/YP domain name
.SH SYNOPSIS
.SH SYNOPSIS
.B hostname
.B hostname
.RB [ \-v ]
.RB [ \-v ]
.RB [ \-a ]
.RB [ \-s | \-\-short ]
.RB [ \-\-alias ]
.RB [ \-d ]
.RB [ \-\-domain ]
.RB [ \-f ]
.RB [ \-\-fqdn ]
.RB [ \-i ]
.RB [ \-\-ip\-address ]
.RB [ \-\-long ]
.RB [ \-s ]
.RB [ \-\-short ]
.RB [ \-y ]
.RB [ \-\-yp ]
.RB [ \-\-nis ]
.RB [ \-n ]
.RB [ \-\-node ]
.PP
.PP
.B hostname
.B hostname
.RB [ \-v ]
.RB [ \-v ]
.RB [ \-F\ filename ]
.RB [ \-a | \-\-alias ]
.RB [ \-\-file\ filename ]
.RB [ \-d | \-\-domain ]
.RB [ hostname ]
.RB [ \-f | \-\-fqdn | \-\-long ]
.RB [ \-i | \-\-ip\-address ]
.PP
.B hostname
.RB [ \-v ]
.RB [ \-y | \-\-yp | \-\-nis ]
.RB [ \-n | \-\-node ]
.PP
.B hostname
.RB [ \-v ]
.RB [ \-F\ filename | \-\-file\ filename ]
.RI [ newname ]
.PP
.PP
.B domainname
.B domainname
.RB [ \-v ]
.RB [ \-v ]
.RB [ \-F\ filename ]
.RB [ \-F\ filename | \-\-file\ filename ]
.RB [ \-\-file\ filename ]
.RI [ newname ]
.RB [ name ]
.PP
.PP
.B nodename
.B nodename
.RB [ \-v ]
.RB [ \-v ]
.RB [ \-F\ filename ]
.RB [ \-F\ filename | \-\-file\ filename ]
.RB [ \-\-file\ filename ]
.RI [ newname ]
.RB [ name ]
.PP
.PP
.B hostname
.B hostname
.RB [ \-v ]
.RB [ \-v | \-\-verbose ]
.RB [ \-h ]
.RB [ \-h | \-\-help ]
.RB [ \-\-help ]
.RB [ \-V | \-\-version ]
.RB [ \-V ]
.RB [ \-\-version ]
.PP
.PP
.B dnsdomainname
.B dnsdomainname
...
@@ -124,12 +118,8 @@ command (see
...
@@ -124,12 +118,8 @@ command (see
below).
below).
.LP
.LP
The host name is usually set once at system startup in
The host name is usually set once at system startup by reading the
.I /etc/rc.d/rc.inet1
contents of a file which contains the host name, e.g.
or
.I /etc/init.d/boot
(normally by reading the contents of a file which contains
the host name, e.g.
.IR /etc/hostname ).
.IR /etc/hostname ).
.SS THE FQDN
.SS THE FQDN
...
@@ -142,16 +132,17 @@ with this command. The FQDN of the system is the name that the
...
@@ -142,16 +132,17 @@ with this command. The FQDN of the system is the name that the
returns for the host name.
returns for the host name.
.LP
.LP
Technically: The FQDN is the
name
Technically: The FQDN is the
canonical name returned by
.BR gethostbyname (2)
.BR gethostbyname
2
(2)
returns for the host name returned by
when resolving the result of the
.BR gethostname (2)
.
.BR gethostname (2)
The DNS domain name is the part after the first dot.
name.
The DNS domain name is the part after the first dot.
.LP
.LP
Therefore it depends on the configuration (usually in
Therefore it depends on the configuration (usually in
.IR /etc/host.conf )
.IR /etc/host.conf )
how you can change it. Usually (if the hosts file is parsed before DNS or
how you can change it. If
NIS) you can change it in
.B hosts
is the first lookup method, you can change the FQDN in
.IR /etc/hosts .
.IR /etc/hosts .
...
@@ -161,22 +152,18 @@ NIS) you can change it in
...
@@ -161,22 +152,18 @@ NIS) you can change it in
Display the alias name of the host (if used).
Display the alias name of the host (if used).
.TP
.TP
.I "\-d, \-\-domain"
.I "\-d, \-\-domain"
Display the name of the DNS domain. Don't use the command
Display the name of the DNS domain (this is the FQDN without the segment up
.B domainname
to the first dot). This is equivalent to using the
to get the DNS domain name because it will show the NIS domain name and
not the DNS domain name. Use
.B dnsdomainname
.B dnsdomainname
instea
d.
comman
d.
.TP
.TP
.I "\-F, \-\-file filename"
.I "\-F, \-\-file filename"
Read the host name from the specified file. Comments (lines starting with
Read the
new
host name from the specified file. Comments (lines starting with
a `#') are ignored.
a `#') are ignored.
.TP
.TP
.I "\-f, \-\-fqdn, \-\-long"
.I "\-f, \-\-fqdn, \-\-long"
Display the FQDN (Fully Qualified Domain Name). A FQDN consists of a
Display the FQDN (Fully Qualified Domain Name). A FQDN consists of name
short host name and the DNS domain name. Unless you are using bind or NIS
including the DNS domain.
for host lookups you can change the FQDN and the DNS domain name (which is
part of the FQDN) in the \fI/etc/hosts\fR file.
.TP
.TP
.I "\-h, \-\-help"
.I "\-h, \-\-help"
Print a usage message and exit.
Print a usage message and exit.
...
@@ -203,11 +190,13 @@ Display the NIS domain name. If a parameter is given (or
...
@@ -203,11 +190,13 @@ Display the NIS domain name. If a parameter is given (or
.B \-\-file name
.B \-\-file name
) then root can also set a new NIS domain.
) then root can also set a new NIS domain.
.SH FILES
.SH FILES
.B /etc/hostname
.B /etc/hosts
.B /etc/hosts
.B /etc/host.conf
.SH AUTHOR
.SH AUTHOR
Peter Tobias, <tobias@et\-inf.fho\-emden.de>
Peter Tobias, <tobias@et\-inf.fho\-emden.de>
.br
.br
Bernd Eckenfels, <net\-tools@lina.inka.de> (NIS and manpage).
Bernd Eckenfels, <net\-tools@lina.inka.de> (NIS and manpage).
.br
.br
Steve Whitehouse, <SteveW@ACM.org> (DECnet support and manpage).
Steve Whitehouse, <SteveW@ACM.org> (DECnet support and manpage).
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment