xref: /original-bsd/bin/hostname/hostname.1 (revision e1e2f25d)
1.\" Copyright (c) 1983, 1988, 1990 The Regents of the University of California.
2.\" All rights reserved.
3.\"
4.\" %sccs.include.redist.roff%
5.\"
6.\"	@(#)hostname.1	6.8 (Berkeley) 07/27/91
7.\"
8.Dd
9.Dt HOSTNAME 1
10.Os BSD 4.2
11.Sh NAME
12.Nm hostname
13.Nd set or print name of current host system
14.Sh SYNOPSIS
15.Nm hostname
16.Op Fl s
17.Op Ar nameofhost
18.Sh DESCRIPTION
19.Nm Hostname
20prints the name of the current host.  The super-user can
21set the hostname by supplying an argument; this is usually done in the
22network initialization script
23.Pa /etc/netstart ,
24normally run at boot
25time.
26.Pp
27Options:
28.Bl -tag -width flag
29.It Fl s
30Trims off any domain information from the printed
31name.
32.El
33.Sh SEE ALSO
34.Xr gethostname 2
35.Sh HISTORY
36The
37.Nm hostname
38command appeared in
39.Bx 4.2 .
40