server time error: [a fatal error or timeout occurred while processing this

lucayang0204

Member
Nov 27, 2012
10
0
1
cPanel Access Level
Root Administrator
Hello,

I want to setup the time zone to Asia/Taipei on WHM. But even the system shows the change is done, the system time is still different with Taipei local time. so I changed the server time via ssh on my vps with the following command:
Code:
[[email protected]~]# rm -rf /etc/localtime
[[email protected]~]# ln -s /usr/share/zoneinfo/Asia/Shanghai /etc/localtime
and now the system time is correct with Taipei local time.

But when I back to WHM to check the time again, the error "[a fatal error or timeout occurred while processing this directive]" happen. the following error is shown when I click on [a fatal error or timeout occurred while processing this directive]:
Code:
/etc/localtime: Does not exist at whostmgr/bin/whostmgr line 5084
	Carp::croak('/etc/localtime: Does not exist') called at /usr/local/cpanel/Cpanel/CPAN/Digest/MD5/File.pm line 47
	Cpanel::CPAN::Digest::MD5::File::__ANON__('/etc/localtime') called at /usr/local/cpanel/Cpanel/CPAN/Digest/MD5/File.pm line 150
	Cpanel::CPAN::Digest::MD5::File::file_md5_hex('/etc/localtime') called at whostmgr/bin/whostmgr line 5084
	main::edittime() called at whostmgr/bin/whostmgr line 948
Can anyone teache me how to fix the error? thanks.

Best Regards,
 

bbrink68

Active Member
Nov 27, 2012
26
0
1
cPanel Access Level
DataCenter Provider
Hmm, I think perhaps something went wrong when you modified the timezone. I don't think you are supposed to remove it. You should touch the file /etc/localtime And try this method:

You may try removing the link first:

Code:
 cp /usr/share/zoneinfo/America/Chicago /etc/localtime
Using tab complete to make sure your grabbing the right time zones. Good luck!
 
Last edited:

lucayang0204

Member
Nov 27, 2012
10
0
1
cPanel Access Level
Root Administrator
Re: server time error: [a fatal error or timeout occurred while processing

Hmm, I think perhaps something went wrong when you modified the timezone. I don't think you are supposed to remove it. You should touch the file /etc/localtime And try this method:

You may try removing the link first:

Code:
 cp /usr/share/zoninfo/America/Chicago /etc/localtime
Using tab complete to make sure your grabbing the right time zones. Good luck!

Hello bro,

thanks for your reply. When I login to the vps via sftp, but I cannot find the file /etc/localtime, how should I do now? thanks again for your kindly help.

Best Regards,
 

bbrink68

Active Member
Nov 27, 2012
26
0
1
cPanel Access Level
DataCenter Provider
Hello again

The command I put in my last response needs to be ran from SSH. You should have SSH access to your server no?

Keep in mind you will use different timezones than the one I used above.
 

lucayang0204

Member
Nov 27, 2012
10
0
1
cPanel Access Level
Root Administrator
Re: server time error: [a fatal error or timeout occurred while processing

Hello,

I try it on SSH, and the system shows as below:
Code:
cp: cannot stat `/usr/share/zoninfo/America/Chicago': No such file or directory
what the next I should do now, thanks, bro

Best Regards,
 

bbrink68

Active Member
Nov 27, 2012
26
0
1
cPanel Access Level
DataCenter Provider
Hey,

Oops, remember your command will be different. Instead of America Chicago you will use Asia/Taipei so will use them instead. First you will need to create the missing file. Try these commands in this order:

Code:
touch /etc/localtime
Code:
cp /usr/share/zoneinfo/Asia/Taipei /etc/localtime
Or use this for Asia/Shanghai

Code:
cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime
Let me know if this works for you.
 
Last edited: