Difference between revisions of "User:Supaplex/my vserver install notes"

From Freeside
Jump to: navigation, search
m
Line 1: Line 1:
 
My steps.
 
My steps.
  
# <code># vserver fshead build -m debootstrap -- -d etch -m ftp://mirrors.xmission.com/debian/</code>
+
 
 +
<code><pre>
 +
# preflight checklist for guest: /etc/network/interfaces dnsmasq:/etc/hosts ip
 +
 
 +
# set these accordingly
 +
export guest=fshead
 +
 
 +
# hint: grep ^iface /etc/network/interfaces
 +
# or: export guest_ip=eth0:$(grep ^iface\ eth0: /etc/network/interfaces | tr ':' ' ' | awk '{print $3}' | sort -n | tail -n 1)
 +
export guest_if=
 +
# ifup ${guest_if}
 +
export guest_ip=
 +
# or: export guest_ip=$(ifconfig ${guest_if} | grep 'inet addr:' | tr ':' ' ' | awk '{print $3}')
 +
export guest_cidr=
 +
# netmask: ifconfig ${guest_if} | grep Mask: | tr ':' ' ' | awk '{print $7}'
 +
 
 +
 
 +
# dnsmasq:
 +
echo -e "echo "${guest_ip}"\t"${guest}'>> /etc/hosts && /etc/init.d/dnsmasq restart'
 +
 
 +
# debootstrap+vserver guest install
 +
vserver $guest build -m debootstrap -- -d etch -m ftp://mirrors.xmission.com/debian/</code>
 +
cd /etc/vservers/${guest}/
 +
echo ${guest} > uts/nodename
 +
 
 +
# network setup
 +
mkdir interfaces/0
 +
cd interfaces/0
 +
echo ${guest_if} > dev
 +
echo ${guest_ip} > ip
 +
echo ${guest_cidr} > prefix
 +
</pre></code>

Revision as of 10:53, 1 February 2008

My steps.


# preflight checklist for guest: /etc/network/interfaces dnsmasq:/etc/hosts ip

# set these accordingly
export guest=fshead

# hint: grep ^iface /etc/network/interfaces
# or: export guest_ip=eth0:$(grep ^iface\ eth0: /etc/network/interfaces | tr ':' ' ' | awk '{print $3}' | sort -n | tail -n 1)
export guest_if=
# ifup ${guest_if}
export guest_ip=
# or: export guest_ip=$(ifconfig ${guest_if} | grep 'inet addr:' | tr ':' ' ' | awk '{print $3}')
export guest_cidr=
# netmask: ifconfig ${guest_if} | grep Mask: | tr ':' ' ' | awk '{print $7}'


# dnsmasq:
echo -e "echo "${guest_ip}"\t"${guest}'>> /etc/hosts && /etc/init.d/dnsmasq restart'

# debootstrap+vserver guest install
vserver $guest build -m debootstrap -- -d etch -m ftp://mirrors.xmission.com/debian/</code>
cd /etc/vservers/${guest}/
echo ${guest} > uts/nodename

# network setup
mkdir interfaces/0
cd interfaces/0
echo ${guest_if} > dev
echo ${guest_ip} > ip
echo ${guest_cidr} > prefix