Change hostname only if the name is different and added restart machine