Инструменты пользователя

Инструменты сайта


linux:timedatectl

Различия

Показаны различия между двумя версиями страницы.

Ссылка на это сравнение

linux:timedatectl [2025/12/06 08:48] – создано Кириллlinux:timedatectl [Дата неизвестна] (текущий) – внешнее изменение (Дата неизвестна) 127.0.0.1
Строка 1: Строка 1:
 +====== Настройка локального времени в linux ======
 +
 +----
 +
 +Открываем терминал **Ctrl+Alt+T**, и пишем следующие команды:
 +
 +Включаем локальное время:
 +<code>
 +sudo timedatectl set-local-rtc 1 --adjust-system-clock
 +</code>
 +
 +Смотрим статус:
 +<code>
 +sudo timedatectl
 +</code>
 +
 +Вывод в терминале:
 +
 +<code>
 +               Local time: Сб 2025-08-09 13:40:20 +07
 +           Universal time: Сб 2025-08-09 06:40:20 UTC
 +                 RTC time: Сб 2025-08-09 13:40:20
 +                Time zone: Asia/Novosibirsk (+07, +0700)
 +System clock synchronized: yes
 +              NTP service: active
 +          RTC in local TZ: yes
 +
 +Warning: The system is configured to read the RTC time in the local time zone.
 +         This mode cannot be fully supported. It will create various problems
 +         with time zone changes and daylight saving time adjustments. The RTC
 +         time is never updated, it relies on external facilities to maintain it.
 +         If at all possible, use RTC in UTC by calling
 +         'timedatectl set-local-rtc 0'.
 +
 +</code>
 +
 +Выключаем локальное время:
 +<code>
 +sudo timedatectl set-local-rtc 0
 +</code>