Fix issue #5214: hostname persistence on RedHat/CentOS