Change hostname from locations below:

  • vi /etc/hostname
  • vi etc/hosts
restart the service
  • sudo /etc/init.d/hostname.sh start