Steps to set Linux Server time to local time

  1. Search for the required time zone available ex. Asia

    timedatectl list-timezones | grep -i Asia

  2. Unlink the current time zone from local time

    unlink /etc/localtime

  3. Set the require time zone by using the below command ex. IST

    ln -s /usr/share/zoneinfo/Asia/Kolkata /etc/localtime

  4. sync the time to server from NTP server of your choice ex. in.pool.ntp.org

    /usr/sbin/ntpdate -u in.pool.ntp.org

  5. To sync the server time and update the bios time at a time from the NTP server

    /usr/sbin/ntpdate -u in.pool.ntp.org && hwclock --systohc

Comments

Popular posts from this blog

Create folder with current date as name

మీ వాట్సాప్ లో రెండు-దశల ధృవీకరణ కోడ్‌ను ఎలా ప్రారంభం చేయాలి