CoE Cluster november 2011/Dell Cluster installation

From Teknologisk videncenter
< CoE Cluster november 2011
Revision as of 11:41, 8 November 2011 by Heth (talk | contribs) (Routing IPv4 and NAT-ing)
Jump to: navigation, search

Hardware

Each group installs Ubuntu 10.10 32 bit on four Dell PowerEdge 1750 bladeserver with 36,5GB harddisk.

Filesystem

  • / filesystem 2 GB primary
  • /tmp filesystem 5 GB logical
  • /var filesystem 5 GB primary
  • /usr filesystem 6 GB logical
  • swap filesystem 2 GB logical
  • /home filesystem remaining space

Updating Ubuntu

Update

sudo bash
apt-get update
apt-get upgrade

List installed packages

Number of installed packages

root@newclusterh:~# <input>dpkg --get-selections | wc -l</input>
962

Searching installed packages

root@newclusterh:~#  <input>dpkg --get-selections | grep nfs</input>
libnfsidmap2                                    install
nfs-common                                      install
nfs-kernel-server                               install
root@newclusterh:~# <input>dpkg -L nfs-common</input>
/.
/etc
/etc/init.d
/etc/init
/etc/init/statd.conf
/etc/init/statd-mounting.conf
/etc/init/rpc_pipefs.conf
/etc/init/gssd.conf
<notice>...OUTPUT OMITTED...</notice>

Routing IPv4 and NAT-ing

Configuring additional NIC's

edit the file /etc/network/interfaces. Example below

auto eth0
iface eth0 inet static
 address 192.168.139.50
 netmask 255.255.255.0
 gateway 192.168.139.1
 network 192.168.139.0
 broadcast 192.168.139.255

auto eth1
iface eth1 inet static
        address 10.0.0.1
        netmask 255.255.255.0

Routing IPv4

  • Add or uncomment the line net.ipv4.ip_forward=1 in /etc/sysctl.conf to allow Routing after boot
  • Issue the command sysctl -w net.ipv4.ip_forward=1 to allow routing in flight.

NAT with iptables

#!/bin/bash
#
# Start firewall
#
# Tillader ping indefra og ud.
# Lukker for al anden trafik.
# Diverse erklæringer
FW=iptables
INT_NET="10.0.0.0/24"
EXT_NET="172.16.4.0/24"
EXT_IP="172.16.4.99"
EXT_IF="eth0"

# Fjern alle tidligere regler
$FW -F INPUT
$FW -F OUTPUT
$FW -F FORWARD
$FW -F -t nat


# Sæt default politik til afvisning
$FW -P FORWARD ACCEPT

# Tillad ping indefra
$FW -A FORWARD -s $INT_NET -p icmp --icmp-type echo-request -j ACCEPT

# Tillad pong udefra
$FW -A FORWARD -d $INT_NET -p icmp --icmp-type echo-reply -j ACCEPT

# Source NAT på udgående pakker
$FW -t nat -A POSTROUTING -o $EXT_IF -s $INT_NET -j SNAT --to-source $EXT_IP