Close Menu
    What's Hot

    YouTube Unblocked Proxy: Overview, Benefits, and Real-World Use Cases

    April 7, 2026

    Linux Kernel Release Frequency Statistics 2026

    April 7, 2026

    How To Use The SSH Login Command

    April 7, 2026
    Facebook X (Twitter) Instagram
    Command Linux
    • About
    • Man Pages
    • Arch Linux
    • Statistics
    • How to
      • Q&A
    • OS
      • Windows
    • Blog
      • Featured
    • MORE
      • Easter Eggs
      • IP Address
    • Write For Us
    • Contact Us
    Command Linux
    Home - man page - HOSTNAME

    HOSTNAME

    WillieBy WillieJanuary 21, 2026Updated:January 21, 2026No Comments1 Min Read
     

    NAME

    hostname – Local hostname configuration file  

    SYNOPSIS

    /etc/hostname  

    DESCRIPTION

    The /etc/hostname file configures the name of the local system that is set during boot using the sethostname(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.

    Depending on the operating system, other configuration files might be checked for configuration of the hostname as well, however only as fallback.

    You may use hostnamectl(1) to change the value of this file from the command line.  

    HISTORY

    The simple configuration file format of /etc/hostname originates from Debian GNU/Linux.  

    Willie
    • Website

    Willie has over 15 years of experience in Linux system administration and DevOps. After managing infrastructure for startups and enterprises alike, he founded Command Linux to share the practical knowledge he wished he had when starting out. He oversees content strategy and contributes guides on server management, automation, and security.

    Related Posts

    E2FREEFRAG

    April 7, 2026

    Net::DNS::RR::DHCID

    April 7, 2026

    LOGROTATE

    April 7, 2026

    EVP_MD_CTX_destroy

    April 7, 2026
    Top Posts

    WHOAMI

    March 5, 2026

    8tshare6a Software Download Guide

    February 26, 2026

    BUSYBOX

    January 24, 2026

    XFCE4-ABOUT

    February 26, 2026
    • Home
    • Contact Us
    • Privacy Policy
    • Terms of Use

    Type above and press Enter to search. Press Esc to cancel.