The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

/etc/hosts

Discussion in 'General Discussion' started by odmtech, Nov 14, 2003.

  1. odmtech

    odmtech Member

    Joined:
    Nov 4, 2003
    Messages:
    11
    Likes Received:
    0
    Trophy Points:
    1
    I have tried to add a new short name to the 127.0.0.1 address in /etc/hosts :

    127.0.0.1 localhost mysql1

    but the next day, this setting has been reset to the initial value :
    127.0.0.1 localhost

    I want to use the "mysql1" short name to be able to switch my databases easily to a new server, without changing my settings in all the scripts.
    But how can I do this if the /etc/hosts file gets reset everyday ?
     
  2. odmtech

    odmtech Member

    Joined:
    Nov 4, 2003
    Messages:
    11
    Likes Received:
    0
    Trophy Points:
    1
    culprit found !

    I have found the culprit : the script "fixetchosts" seems to be the one which resets the "etc/hosts" file every night.

    But I still don't have my answer : how can I change the /etc/hosts file without my changes being deleted everyday !

    I could deactivate this script, but what will happen the next time I upgrade cpanel ?

    Could this be an WHM feature I have not found ?

    Has anyone found a way to apply lasting changes to the /etc/hosts.

    Thanks in advance for your help.
     
Loading...

Share This Page