This post shows safe, distro-agnostic ways to change the system hostname and covers common variations (systemd, init-based, NetworkManager, cloud-init, and containers). Quick summary Temporary (current session): sudo hostname <new> Persistent (systemd systems): sudo hostnamectl set-hostname <new> Also update /etc/hosts and check cloud-init if present. Important: Always verify whether your environment (cloud image, container, or managed host) uses cloud-init or another management tool — it may overwrite manual changes. 1 — systemd-based systems (Ubuntu, Debian, Fedora, Arch, CentOS 7+) Set the persistent hostname: ...
How to Change Timezone in Linux (Ubuntu, CentOS, Fedora, Arch)
Changing the timezone on a Linux system is a common task for system administrators, especially when managing servers in different regions or for users traveling. This guide covers how to change the timezone on various Linux distributions, including systemd-based systems and older ones. Prerequisites Root or sudo access to the system. Basic knowledge of the command line. 1. Check Current Timezone Before changing the timezone, verify the current setting: timedatectl # For systemd systems date # General command 2. List Available Timezones To see all available timezones: ...
Complete Guide: Installing Docker on Linux with Non-Root Access
Docker simplifies application deployment with containerization. Running Docker without root enhances security and streamlines workflows. This guide will walk you through installing Docker on Linux and configuring it for non-root usage. Prerequisites A Linux system (Ubuntu, Debian, CentOS, etc.) A user account with sudo privileges. 1. Update Your System Keeping your system updated ensures compatibility and security. For Ubuntu/Debian: sudo apt update && sudo apt upgrade -y For RHEL-based systems (e.g., CentOS): ...