Configure New VMware Image on Gentoo
VMware Setup
Use the base template: "Linux Gentoo 64bit", although this will definitely need its packages updating. Please note, the limited space on this hosting account prevents me uploading the VM image, although it is a base Gentoo installation that can be easily reconstructed.
Change Network Settings
Modify the IP address in the following file
nano /etc/conf.d/net
Edit the following file replacing the MAC address with the one in the VMware settings page:
nano /etc/udev/rules.d/70-persistent-net.rules
Edit Hostname
Change the name of the server to something new:
nano /etc/apache2/httpd.conf nano /etc/hosts nano /etc/conf.d/hostname
Edit Apache vhosts
Locate the file and replace the IP address with the machine IP + change the hostname:
nano /home/dev/apache/conf/vhosts.conf
SKIP: Also edit the httpd.conf file to set the hostname near "SetEnv LOCAL_SERVER_NAME machine":
/etc/apache2/httpd.conf
Modify MySQL Bind Address
Locate the words "bind-address" and change to the server IP:
nano /etc/mysql/my.cnf
Change SSH Bind Address
Edit the IP address in sshd_config file:
nano /etc/ssh/sshd_config
Remove SSH Keys
You must remove the existing SSH keys as they no longer apply to the new host:
rm /etc/ssh/ssh_host_key* /etc/ssh/ssh_host_dsa_key* /etc/ssh/ssh_host_rsa_key*
Modify GRUB
Perform the following to change the name of the server:
mount /boot nano /boot/grub/grub.conf cd ~ umount /boot
Restart the Server
And finally test the shutdown / startup processes by simply rebooting:
shutdown –r now
Update the Packages
Now do an "emerge" to update out of date packages:
emerge --sync emerge –up world
Update Postfix Mail Aliases
Now do an "emerge" to update out of date packages:
newaliases