Difference between revisions of "Software projects/OS/Slackware/Advanced usage/Hostname"
From Pandora Wiki
Linux-SWAT (talk | contribs) (Created page with "= Changing the hostname = * As root, type: netconfig * Now you have to edit /etc/sudoers . You have to use visudo or nano, otherwise some editors may change the permissions o...") |
Linux-SWAT (talk | contribs) (→Changing the hostname) |
||
Line 5: | Line 5: | ||
nano /etc/sudoers | nano /etc/sudoers | ||
* Change all "darkstar" into the hostname you've choosen. | * Change all "darkstar" into the hostname you've choosen. | ||
+ | * Sudoers permissions _must_ be: | ||
+ | ls -lsa /etc/sudoers | ||
+ | -r--r----- 1 root root | ||
* In case you changed the permissions, do this: | * In case you changed the permissions, do this: | ||
chmod 0440 /etc/sudoers | chmod 0440 /etc/sudoers | ||
chown 0.0 /etc/sudoers | chown 0.0 /etc/sudoers |
Revision as of 18:17, 5 March 2013
Changing the hostname
- As root, type:
netconfig
- Now you have to edit /etc/sudoers . You have to use visudo or nano, otherwise some editors may change the permissions of this file, therefore disable sudo commands.
nano /etc/sudoers
- Change all "darkstar" into the hostname you've choosen.
- Sudoers permissions _must_ be:
ls -lsa /etc/sudoers -r--r----- 1 root root
- In case you changed the permissions, do this:
chmod 0440 /etc/sudoers chown 0.0 /etc/sudoers