Creating a new web server is piece of cake at Rackspace Cloud. Here is a demo video of how to set up a new instance with your favorite Linux distribution. I have used Fedora 12 for my new spaniards.es servers, and here is the script I’ve used to install everything needed so far:
-
# Install HTTPD
-
yum -y install httpd rsync
-
-
# Install PHP
-
yum -y install php php-mbstring php-mysql mysql
-
-
#############################################################
-
# FIREWALL
-
# Open http port 80 (and ssh)
-
iptables -F
-
iptables -A INPUT -p tcp –dport 22 -j ACCEPT
-
iptables -P INPUT DROP
-
iptables -P FORWARD DROP
-
iptables -P OUTPUT ACCEPT
-
iptables -A INPUT -i lo -j ACCEPT
-
iptables -A INPUT -m state –state ESTABLISHED,RELATED -j ACCEPT
-
iptables -A INPUT -p tcp –dport 80 -j ACCEPT
-
iptables -L -v
-
service iptables save
-
-
# Start HTTPD server
-
/etc/init.d/httpd start
-
-
# Install memcached
-
yum -y install memcached
-
memcached -d -u apache
-
yum -y install php-pecl-memcache
-
-
# Restart HTTPD server
-
/etc/init.d/httpd restart
DNS configuration can be done through the admin pages, so there is no need for manual configuration. Copying the data from your old server can be done with rsync and having mysql installed is handy to test db connections from the console.
In less than 10 minutes you can have a new web server up and running :)