mirror of
https://git.proxmox.com/git/systemd
synced 2025-06-02 23:25:06 +00:00
58 lines
2.2 KiB
Groff
58 lines
2.2 KiB
Groff
'\" t
|
|
.TH "HOSTNAME" "5" "" "systemd 219" "hostname"
|
|
.\" -----------------------------------------------------------------
|
|
.\" * Define some portability stuff
|
|
.\" -----------------------------------------------------------------
|
|
.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
|
.\" http://bugs.debian.org/507673
|
|
.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html
|
|
.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
|
.ie \n(.g .ds Aq \(aq
|
|
.el .ds Aq '
|
|
.\" -----------------------------------------------------------------
|
|
.\" * set default formatting
|
|
.\" -----------------------------------------------------------------
|
|
.\" disable hyphenation
|
|
.nh
|
|
.\" disable justification (adjust text to left margin only)
|
|
.ad l
|
|
.\" -----------------------------------------------------------------
|
|
.\" * MAIN CONTENT STARTS HERE *
|
|
.\" -----------------------------------------------------------------
|
|
.SH "NAME"
|
|
hostname \- Local hostname configuration file
|
|
.SH "SYNOPSIS"
|
|
.PP
|
|
/etc/hostname
|
|
.SH "DESCRIPTION"
|
|
.PP
|
|
The
|
|
/etc/hostname
|
|
file configures the name of the local system that is set during boot using the
|
|
\fBsethostname\fR(2)
|
|
system call\&. It should contain a single newline\-terminated hostname string\&. The hostname may be a free\-form string up to 64 characters in length; however, it is recommended that it consists only of 7\-bit ASCII lower\-case characters and no spaces or dots, and limits itself to the format allowed for DNS domain name labels, even though this is not a strict requirement\&.
|
|
.PP
|
|
Depending on the operating system, other configuration files might be checked for configuration of the hostname as well, however only as fallback\&.
|
|
.PP
|
|
You may use
|
|
\fBhostnamectl\fR(1)
|
|
to change the value of this file during runtime from the command line\&. Use
|
|
\fBsystemd-firstboot\fR(1)
|
|
to initialize it on mounted (but not booted) system images\&.
|
|
.SH "HISTORY"
|
|
.PP
|
|
The simple configuration file format of
|
|
/etc/hostname
|
|
originates from Debian GNU/Linux\&.
|
|
.SH "SEE ALSO"
|
|
.PP
|
|
\fBsystemd\fR(1),
|
|
\fBsethostname\fR(2),
|
|
\fBhostname\fR(1),
|
|
\fBhostname\fR(7),
|
|
\fBmachine-id\fR(5),
|
|
\fBmachine-info\fR(5),
|
|
\fBhostnamectl\fR(1),
|
|
\fBsystemd-hostnamed.service\fR(8),
|
|
\fBsystemd-firstboot\fR(1)
|