antispam

Member
Nov 26, 2012
8
0
1
cPanel Access Level
Root Administrator
Hi all,

in a new server (installed CPanel yesterday) I tried about 8 hours ago to "Change Hostname".

It seemed to finish ok, then it asked for "Add an A Entry for Your Hostname", which I did as prompted, also ok.

However, when I click on the "Change Hostname" a warning appears: "Your previous attempt to change the hostname is still running. Please wait until it completes".

When using "/usr/local/cpanel/bin/set_hostname abc.def.com" I get
"Changing hostname to abc.def.com...Failed!
Cannot set the hostname; there is already hostname change in progress.

The /scripts/check_valid_server_hostname diplays ok.
Any ideas?
 

antispam

Member
Nov 26, 2012
8
0
1
cPanel Access Level
Root Administrator
Forgot to say that ~4 hours after the "Change Hostname" I tried to fix it by restarting the server.
Still, I have the exact same situation.

And it might be needed to change the name again in the near future.
 

antispam

Member
Nov 26, 2012
8
0
1
cPanel Access Level
Root Administrator
Yes, DNS is perfectly valid. In fact the server responds to both the old and new host names.

However, the certificate given out during IMAP/POP3/SMTP/FTP connections reflects the old host name.
 

antispam

Member
Nov 26, 2012
8
0
1
cPanel Access Level
Root Administrator
Hi again, it's CentOS 7.2 kernel-3.10.0-327.22.2.el7.x86_64, WHM 58.0 (build 28), System and Server software is up to date (the System was only installed yesterday and "System Update" only updated 5 packages).
 

antispam

Member
Nov 26, 2012
8
0
1
cPanel Access Level
Root Administrator
Hi, for the record, I opened a CPanel Ticket and Jon proposed
to just delete the touch file:
/var/cpanel/.application-locks/UpdateHostname.

In fact hundreds of 1-byte files
(the above mentioned plus one for each domain name on this IP)
are left there.

Indeed, after I delete them I am able to change Host Name,
but now every time I try to change the name,
the same thing happens, the files remain there and block further attempts
(until I delete them again).

Obviously, I 'm a little afraid that the process did not finish ok.
The logs however don't report any error, as far as I can tell,
and everything seems to work.
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,909
2,228
463
Indeed, after I delete them I am able to change Host Name,
but now every time I try to change the name,
the same thing happens, the files remain there and block further attempts
(until I delete them again).
Hello,

Could you reopen the ticket, or open a new one, so we can determine why the lock files are left in-place after updating the hostname? You can post the ticket number here so we can update this thread with the outcome. There's an internal case, CPANEL-6156, regarding this issue, but additional information about why the lock files remain on the system will help us to address the issue.

Thank you.