Long reboots on distro with RTC in local TZ

I just wanted to write about my experience with solving this issue, in case anyone else had it.

I’m not sure at what point after a fresh install of FreePBX 15 - I think it may have been after I set my local timezone with the sysadmin pro module, it began to take forever to reboot the system. I think it had to do with a database hang, so I was definitely experiencing this problem and maybe this problem as well.

Well, after many headaches what fixed it I stumbled upon by running a timedatectl from the CLI just to check things out. It showed the setting:

RTC in local TZ: yes

And informed me:

Warning: The system is configured to read the RTC time in the local time zone.
This mode can not 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’.

And so I thought, why not, let’s run timedatectl set-local-rtc 0 which then gave an:

RTC in local TZ: no

when you run timedatectl again just to view the status.

Well, my issues with the hanging database (“A stop job is running for MariaDB database server”) and long reboots were solved immediately.

I think this issue could be triggered in certain environments when you set your local timezone away from UTC (which most of us will do using either sysadmin pro or timedatectl set-timezone) but the RTC in local TZ is set to yes. Basically running the commands above to set that to no appears to fix it.

(also I believe on other distributions this may be set to no by default, but it does appear to be a default of yes for the FreePBX distro - I wonder if it would hurt anything to make the default for this setting a 0 or no?)

1 Like

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.