saurabh saurabh - 1 year ago 111
Linux Question

Linux sudo is working slow after changing the hostname

I have changed my hostname in linux mint and after that my sudo works slow I mean how to change the etc/sudoers back again to work properly or there is anything else that I have to change

Answer Source

you probably need to edit /etc/hosts to reflect your new hostname

otherwise it tries to find info about it via DNS (and timeouts, most probably)

look for:  localhost  oldname

and change to:  localhost  newname

Of course change only the line corresponding to oldname. Above I gave an an example of a machine which isn't connected to the net...

Below I give an example of a machine which have an IP:  localhost
a.b.c.d    oldname     <-- just edit that line
Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download