Installguide proxmox on Software Raid (Hetzner EQ6 server)

ellenverheyen

Member
Jun 3, 2009
55
0
6
installing proxmox EQ6 hetzner softwareRAID

THIS IS NOT SUPPORTED BY THE PROXMOX TEAM
USE AT YOUR OWN RISK!

The system will be running the development Openvz (with KVM) Kernel: Linux 2.6.32-belyayev.1 #1 SMP

Boot with the rescue system

# installimage
debian 64 minimal

configure disks (sizes and partitions are an example):

HARD DISK DRIVE(S):

DRIVE1 /dev/sda
DRIVE2 /dev/sdb

SOFTWARE RAID:

SWRAID 1
SWRAIDLEVEL 1

BOOTLOADER grub

HOSTNAME proxmox or something else

PART /boot ext3 4G
PART lvm vg0 424G
PART lvm vg1 all

LV vg0 root / ext3 100G (some extra space to store temp)
LV vg0 swap swap swap 24G (double the size of the RAM)
LV vg0 backup /backup ext3 300G (to store backups)

LV vg1 vz /var/lib/vz ext3 all (the space for the vm disks and vz data)

control F10, save, and wait until the process is finished…
reboot

Change login password and update packages
# passwd
# apt-get update
# apt-get upgrade

Chech partitions with
#df

Install Proxmox VE repodata
http://pve.proxmox.com/wiki/Install_Proxmox_VE_on_Debian_Lenny

# nano /etc/apt/sources.list
add:

# PVE packages provided by proxmox.com
deb http://download.proxmox.com/debian lenny pve

# apt-get update
# apt-get upgrade

Install Proxmox VE and 2.6.32 kernel for kvm modules
http://pve.proxmox.com/wiki/Proxmox_VE_Kernel
# apt-get install proxmox-ve-2.6.32

Install openvz kernel 2.6.32 to include openvz, kvm will be with included with the modules because proxmox installed it
http://wiki.openvz.org/Install_kernel_from_rpm_on_debian
# apt-get install alien fakeroot
# wget http://download.openvz.org/kernel/b...elyayev.1/kernel-2.6.32-belyayev.1.x86_64.rpm
# fakeroot alien -k kernel-2.6.32-belyayev.1.x86_64.rpm (takes a long time!!)
# dpkg -i kernel_2.6.32-belyayev.1_amd64.deb
# update-initramfs -c -k 2.6.32-belyayev.1
# update-grub
# reboot

Check if kernel is running
# uname -a
Linux proxmox2 2.6.32-belyayev.1 #1 SMP Thu May 27 20:22:10 MSD 2010 x86_64 GNU/Linux

proxmox2:~# lsmod
Module Size Used by
kvm_intel 41024 0
kvm 245345 1 kvm_intel

vzrst 114302 0
vzcpt 100441 0
vzdquota 39661 0 [permanent]
vzmon 19041 4 vzethdev,vznetdev,vzrst,vzcpt
vzdev 2339 4 vzethdev,vznetdev,vzdquota,vzmon


Add vmbr0/vmbr1

# nano /etc/network/interfaces
auto lo
iface lo inet loopback

auto eth0
iface eth0 inet static
address MAIN IP
(broadcast IP)
netmask 255.255.255.192
gateway gateway IP
post-up iptables-restore < /etc/iptables.up.rules

auto vmbr0
iface vmbr0 inet static
address First additional IP
netmask 255.255.255.192
gateway IP of ETH0
bridge_ports none
bridge_stp off
bridge_fd 0

auto vmbr1
iface vmbr1 inet static
address first IP of additional subnet
netmask netmask of additional subnet
gateway IP of ETH0
bridge_ports none
bridge_stp off
bridge_fd 0


change sysctl settings (hetzner eth0 policy)


# nano /etc/sysctl.conf
# these values are necessary

net.ipv4.ip_forward = 1
net.ipv6.conf.all.forwarding = 1
net.ipv4.conf.default.proxy_arp = 1
net.ipv4.conf.all.rp_filter = 1
kernel.sysrq = 1
net.ipv4.conf.default.send_redirects = 1
net.ipv4.conf.all.send_redirects = 0

to check the values
# systcl -p

restart networking
# /etc/init.d/networking restart
or just reboot

Having mdadm send emails when raid has a problem
#nano /etc/mdadm/mdadm.conf
add
MAILADDR mailadres

# /etc/init.d/mdadm restart

Login to webinterface
change DNS to ok settings
Set time zone
Add admin emailadres
change keyboard layout and language
check if all bridges exist (ping them…)
add backup target (local directory) (optional)

Create a KVM/VZ test machine to see if everything is ok.
Download some appliance templates using the webinterface
Upload an install disc to test KVM

Adding precreated openvz templates:
# cd /var/lib/vz/template/cache
# wget "template URL"
change the name according to the templates proxmox uses.

You're ready, the system's running!
Feel free to adapt these instructions to your own needs.

If someone finds a mistake, please reply to this thread and comment on the process.
If there's a better way of doing this, please let me know and I'll correct the instructions.

Please remember as previously said this setup is not supported by the proxmox team and future updates to the system may break it.
We are not responsible for data loss!

Kindly regards

Ellen Verheyen
2E Projects bvba

p.s. a big thank you to chronos for providing the instructions to install the alien kernel.
 
Last edited:

nekys

Member
Jun 14, 2010
6
0
21
Did so the setup, this is my /etc/network/interfaces:

auto eth0
iface eth0 inet static
address 188.40.71.135
broadcast 188.40.71.191
netmask 255.255.255.192
gateway 188.40.71.129
post-up iptables-restore < /etc/iptables.up.rules



auto vmbr0
iface vmbr0 inet static
address 188.40.71.164
netmask 255.255.255.192
gateway 188.40.71.135
bridge_ports none
bridge_stp off
bridge_fd 0

Still, my guest OS can't reach the internet and I can't reach the guest OS from the internet...
This is the network config on the guest OS:
address 188.40.71.164
subnet mask 255.255.255.192
gateway 188.40.71.135
 

ellenverheyen

Member
Jun 3, 2009
55
0
6
I Can ping your server:

PING 188.40.71.135 (188.40.71.135): 56 data bytes
64 bytes from 188.40.71.135: icmp_seq=0 ttl=53 time=26.293 ms
64 bytes from 188.40.71.135: icmp_seq=1 ttl=53 time=24.352 ms
64 bytes from 188.40.71.135: icmp_seq=2 ttl=53 time=26.816 ms

and you bridge:

PING 188.40.71.164 (188.40.71.164): 56 data bytes
64 bytes from 188.40.71.164: icmp_seq=0 ttl=53 time=23.720 ms
64 bytes from 188.40.71.164: icmp_seq=1 ttl=53 time=22.833 ms
64 bytes from 188.40.71.164: icmp_seq=2 ttl=53 time=22.785 ms
c64 bytes from 188.40.71.164: icmp_seq=3 ttl=53 time=26.485 ms
 

nekys

Member
Jun 14, 2010
6
0
21
Yes but if I try to connect via secondary IP, I reach host, not guest OS.
 

ellenverheyen

Member
Jun 3, 2009
55
0
6
You need to use a different address for your guest OS, you may not use the same address as the bridge does. so f.e. use 188.40.71.165

then it should work.

Ellen
 

nekys

Member
Jun 14, 2010
6
0
21
OK, so I use one of my extra IPs for the vmbr0 and on the VPS I give another one.
Can you be more specific on the kind of config I do on the guest OS and Proxmox enviroment?
 

otakuz

New Member
Jun 18, 2010
1
0
1
It is actual!

How to make accessible Guest OS?

On IP to the address it is accessible only HOST OS. Guest OS it is accessible only locally.

Example:
Host OS - IP 78.?6.4?.2?2
I create VM Guest OS and I use vmbr0 (selected IP 78.4?.?3.2?5).

After start, VM Guest OS (vmbr0) works also the accessible is local. But to Guest OS it is impossible to be connected on SSH... In any way

PS Earlier used here (http://www.liverpoollife.net/Darren...ed-network-configuration-plus-1-to-1-nat.html) such configuration and it worked. And as it to make now, I do not know :(
 
Last edited:

darude

Guest
Hi guys,

Thanks for your guide in the first place, most important about the belyayev kernel was the mdadm support, OpenVZ is nice to have too. :)

We tried to setup a similar setup but we havn't finished yet successfully.

The point and problem is: We don't want to waste the 4 IPs for the bridges itself.

We used the howto below, but havn't managed to get a connection from the guest (with one of those additional IPs) to the outer world, the main IP as gateway seems to be not valid in the given subnet.

The question is such a setup possible with proxmox or just a waste of time?

We would very thankful if somebody has any idea.


Bye, Benjamin.

http://wiki.hetzner.de/index.php/Xen_auf_einem_EQ_4_mit_Debian_Lenny_64Bit_und_4_IP's

Our config on the Proxmox Host:
Code:
### Hetzner Online AG - installimage
# Loopback device:
auto lo
iface lo inet loopback

# device: eth0
auto  eth0
iface eth0 inet manual
post-up iptables-restore < /etc/iptables.up.rules

auto vmbr0
iface vmbr0 inet static
        address xx.xx.78.143
        netmask 255.255.255.192
        broadcast xx.xx.78.159
        gateway xx.xx.78.129

        bridge_ports eth0
        bridge_stp off
        bridge_maxwait 5

        up route add -host xx.xx.75.198 gw xx.xx.75.198
        up route add -host xx.xx.75.199 gw xx.xx.75.199
        up route add -host xx.xx.75.200 gw xx.xx.75.200

Info from Hetzner for the additional IPs:
Code:
Gateway: xx.xx.75.193
Mask: 255.255.255.240

Guest Info:
Code:
address xx.xx.75.198
netmask 255.255.255.240
broadcast xx.xx.75.207
gateway xx.xx.78.143 <= the Host IP

Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
xx.xx.75.192    0.0.0.0         255.255.255.240 U     0      0        0 eth0
 
Last edited by a moderator:

darude

Guest
It's working now!

Following Guest config with Gateway below needs to be used, instead of the Host Main IP:

Code:
address xx.xx.75.198
netmask 255.255.255.240
broadcast xx.xx.75.207
gateway xx.xx.75.193 <= the Gateway in this subnet

Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
xx.xx.75.192    0.0.0.0         255.255.255.240 U     0      0        0 eth0
 

mastens

Active Member
May 1, 2009
45
0
26
Hi,

Can you past you whole configuration? I'm in trouble with an Hetzner server myself, and need an setup that works, to get my VPS's up and running again :)

Marius
 

darude

Guest
Finally as conclusion the working configuraiton:

Host configuration:
Code:
### Hetzner Online AG - installimage
# Loopback device:
auto lo
iface lo inet loopback

# device: eth0
auto  eth0
iface eth0 inet static
        address xx.xx.78.143
        netmask 255.255.255.255
        broadcast xx.xx.78.159
        gateway xx.xx.78.129
        pointopoint xx.xx.78.129
        post-up iptables-restore < /etc/iptables.up.rules

auto vmbr0
iface vmbr0 inet static
        address xx.xx.78.143
        netmask 255.255.255.255
        broadcast xx.xx.78.159
        bridge_ports none
        bridge_stp off
        bridge_fd 0

        up ip route add xx.xx.75.198/32 dev vmbr0
        up ip route add xx.xx.75.199/32 dev vmbr0
        up ip route add xx.xx.75.200/32 dev vmbr0

Guest configuration:
Code:
# The loopback network interface
auto lo
iface lo inet loopback

# The primary network interface
auto eth0
iface eth0 inet static
        address xx.xx.75.198
        broadcast xx.xx.75.207
        netmask 255.255.255.240
        gateway xx.xx.75.193
        # opendns for example
        dns-nameservers 208.67.222.222 208.67.220.220

Source: http://wiki.hetzner.de/index.php/Proxmox_VE
 
Last edited by a moderator:

mastens

Active Member
May 1, 2009
45
0
26
darude... Question for you...

Have you been running into packet loss problems after using this config?

I'm having trouble, they changed nic and patch cable, switch port, and still having problems with some minor packet loss..
Which is VERY annoying... And very hard to figure out.. using the exact same config as you, ofcourse with other ip's.

Marius
 

darude

Guest
Hi mastens,

no I'm not having any problems with packetloss.
Can you specify which host is having packetloss to which net or host?
Is the problem inside your host between the guests or/and bridges?
Or from the guest via host to the interwebbz?

Bye, darude
 

mastens

Active Member
May 1, 2009
45
0
26
Hi,

15. 213.239.229.137 0.0% 1000 44.2 44.4 40.4 83.2 3.2
16. 85.10.xxx.xxx 2.4% 1000 49.0 48.8 45.3 94.8 3.7

This is to the host machine from another location... No loss before last hop... same goes from 3 other places. So, it has to be something with the internal routing on the server. I guess?!?!

And, ofcourse with mtr to guests on host machine, i also have packet loss...

Can you run an mtr against your server from an remote location?

mtr --no-dns --report --report-cycles 1000 ipadress -> filename

Just to check if it's any packetloss on your side, i'm using exactly the same setup you are, with my own ip's.

Regards

Marius
 

darude

Guest
hi marius,

I did some further testing (thanks for the nice mtr tool).
I kept mtr running for some time and had no packetloss.
There're some peaks due to some p2p. :)

The source host is my ubuntu machine at home and the destination a virtual machine on the hetzner proxmox host.

Right now I am doing the same thing with the hetzner host, but it seems looking quite well.

Finally, I am not having any packetlossy issues. :)

Code:
                                                                                                  Packets               Pings
 Host                                                                                           Loss%   Snt   Last   Avg  Best  Wrst StDev
 1. homeserver                                                                            0.0% 17607    0.6   0.4   0.4  18.2   0.5
 2. 172.29.xx.xx                                                                           0.0% 17606    7.3  19.5   4.8 371.9  47.5
 3. 78.35.xx.xx                                                                             0.0% 17606    6.2  21.0   5.6 916.4  47.5
 4. core-maw1-vl200.netcologne.de                                               0.0% 17606    6.0  22.8   5.2 2269.  53.6
 5. core-sto2-vl409.netcologne.de                                                  0.0% 17606    6.1  22.3   5.3 560.0  50.1
 6. rtdecix-te43.netcologne.de                                                       0.0% 17606   10.2  25.6   8.5 430.5  51.2
 7. decix2-gw.hetzner.de                                                               0.0% 17606   11.1  24.3   8.6 372.8  47.5
 8. hos-bb1.juniper2.fs.hetzner.de                                                  0.0% 17606   15.2  29.9  13.2 436.1  48.6
 9. hos-tr4.ex3k3.rz12.hetzner.de                                                   0.0% 17606   16.1  28.8  13.8 2328.  49.5
10. static.78-46-xx-xx.clients.your-server.de                                    0.0% 17606   15.2  28.4  13.3 2352.  50.7
11. mydomain.de                                                                          0.0% 17606   16.5  28.0  13.8 400.3  45.5


Edit:

Code:
HOST: homeserver                    Loss%   Snt   Last   Avg  Best  Wrst StDev
  1. homeserver                   0.0%  1000    0.6   0.5   0.4   1.4   0.1
  2. 172.29.xx.xx                    0.0%  1000    5.9   6.4   4.9  24.3   1.6
  3. 78.35.xx.xx                  0.0%  1000    8.6   7.9   5.7  34.7   3.0
  4. 195.14.195.145                0.0%  1000    6.9  10.2   5.3 203.9  18.9
  5. 195.14.215.254                0.0%  1000    7.0  10.7   5.3 208.5  22.1
  6. 87.79.16.163                  0.0%  1000    9.9  13.1   8.5 209.1  18.3
  7. 80.81.193.164                 0.0%  1000    9.9  11.9   8.8  62.6   6.0
  8. 213.239.240.242               0.0%  1000   14.2  18.4  13.4 116.3  11.7
  9. 213.239.228.164               0.0%  1000   16.9  16.0  14.0  32.9   1.5
 10. 78.46.xx.xx                  0.0%  1000   17.9  15.4  13.5  36.2   1.8
 
Last edited by a moderator:

Ablius

Guest
Hello everyone. excuse my English, but it is bad. I followed your discussion with interest. I too have a server on Hetzner. I successfully installed proxmox There being explained and the panel is active. this is my configuration:

### Hetzner Online AG - installimage
# Loopback device:
auto lo
iface lo inet loopback

# device: eth0
auto eth0
iface eth0 inet static
address 178.63.15.2000
netmask 255.255.255.192
broadcast 178.63.15.191
gateway 178.63.15.129
pointtoopoint 178.63.15.129
post-up iptables-restore < /etc/iptables.up.rules

auto vmbr0
iface vmbr0 inet static
address 178.63.15.2000
netmask 255.255.255.192
broadcast 178.63.15.191
bridge_ports none
bridge_stp off
bridge_fd 0

up ip route add xx.xx.75.198/26 dev vmbr0
up ip route add xx.xx.75.199/26 dev vmbr0
up ip route add xx.xx.75.200/26 dev vmbr0





Unfortunately, creating a VM can not access to content. Is anyone able to successfully run the KVM with VM. Can you help please. Thanks to all
 

darude

Guest
Hello everyone. excuse my English, but it is bad. I followed your discussion with interest. I too have a server on Hetzner. I successfully installed proxmox There being explained and the panel is active. this is my configuration:

### Hetzner Online AG - installimage
# Loopback device:
auto lo
iface lo inet loopback

# device: eth0
auto eth0
iface eth0 inet static
address 178.63.15.2000
netmask 255.255.255.192
broadcast 178.63.15.191
gateway 178.63.15.129
pointtoopoint 178.63.15.129
post-up iptables-restore < /etc/iptables.up.rules

auto vmbr0
iface vmbr0 inet static
address 178.63.15.2000
netmask 255.255.255.192
broadcast 178.63.15.191
bridge_ports none
bridge_stp off
bridge_fd 0

up ip route add xx.xx.75.198/26 dev vmbr0
up ip route add xx.xx.75.199/26 dev vmbr0
up ip route add xx.xx.75.200/26 dev vmbr0





Unfortunately, creating a VM can not access to content. Is anyone able to successfully run the KVM with VM. Can you help please. Thanks to all

- Your IP-Adresse is not a valid IPv4-Adresse, the last octet is bigger than 255.
- The subnet masks in the routes you added are not /32, from my experience this is necessary for successful routing conditions. For examples compare that with my configuration further to the top.
- Maybe thats just by accident, but try not use the same IP-Adresses in the routes use as I do. :)

Bye.
 
Last edited by a moderator:

Ablius

Guest
thanks for the reply. I changed as you said. Unfortunately it does not work the same.
this and the current configuration:

# device: eth0
auto eth0
iface eth0 inet static
address 178.63.15.199 "example"
broadcast 178.63.15.191
netmask 255.255.255.192
gateway 178.63.15.129
pointtopoint 178.63.15.129
up echo 1 > /proc/sys/net/ipv4/ip_forward


### NETWORK OPENVZ
auto vmbr0
iface vmbr0 inet static
address 178.63.15.199 "example"
broadcast 178.63.15.191
netmask 255.255.255.255
bridge_ports none
bridge_stp off
bridge_fd 0

### NETWORK KVM
auto vmbr1
iface vmbr1 inet static
address 178.63.15.199 "example"
broadcast 178.63.15.191
netmask 255.255.255.255
bridge_ports none
bridge_stp off
bridge_fd 0
up ip route add 178.63.15.177/32 dev vmbr1 "example"
up ip route add 178.63.15.178/32 dev vmbr1 "example"
up ip route add 178.63.15.179/32 dev vmbr1 "example"


EVEN WITH THIS SETUP I CAN NOT QUIT. this my sysctl.conf

### Hetzner Online AG installimage
# sysctl config
net.ipv4.ip_forward=1
net.ipv4.conf.all.rp_filter=1
net.ipv4.icmp_echo_ignore_broadcasts = 1
net.ipv6.conf.all.forwarding=1
#-- OpenVZ begin --#

# On Hardware Node we generally need
# packet forwarding enabled and proxy arp disabled
net.ipv4.conf.default.forwarding=1
net.ipv4.conf.default.proxy_arp = 1

# Enables source route verification
net.ipv4.conf.all.rp_filter = 1

# Enables the magic-sysrq key
kernel.sysrq = 1

# TCP Explict Congestion Notification
#net.ipv4.tcp_ecn = 0

# we do not want all our interfaces to send redirects
net.ipv4.conf.default.send_redirects = 1
net.ipv4.conf.all.send_redirects = 0

#-- OpenVZ end --#

some ideas. Thanks to all
 
Last edited by a moderator:

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get your own in 60 seconds.

Buy now!