Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!


Configure KVM Bridge in OVH Server.
New on LowEndTalk? Please Register and read our Community Rules.

All new Registrations are manually reviewed and approved, so a short delay after registration may occur before your account becomes active.

Configure KVM Bridge in OVH Server.

I got server from ovh & they give me another subnet with IP's and now the gateway seems to be out of my new IP block ?

How to configure kvm bridge in the server please ?

Comments

  • dragon2611dragon2611 Member
    edited September 2016

    Is it actually an OVH server or is it a SYS/KIMSUFI.

    If it's an actual OVH machine and If you dont mind losing 3 IP's from the subnet it might be better to stuff it in Vrack otherwise you have do a load of routing hacks to deal with the out of subnet gateway and also register the MAC address of the VM's with OVH or their switches/routers will block it.

  • MikeAMikeA Member, Patron Provider
    edited September 2016

    The gateway is the main IP of your system with .254 as the last octet.

    Just configure bridge like you normally would.

  • dragon2611 said: Is it actually an OVH server or is it a SYS/KIMSUFI.

    it's OVH :/

    MikeA said: The gateway is the main IP of your system with .254 as the last octet.

    I try configure like this but not working ? can you help me ? do you have experience in OVH Bridge ?

  • exception0x876exception0x876 Member, Host Rep, LIR

    make sure to assign a virtual mac from OVH panel to each IP, and then assign each mac to corresponding VM.

  • I cannot help you in detail, but here is my network setup (debian/ubuntu based) on a OVH machine for a host-routed KVM setup (replace aa.bb.cc.dd etc. as appropriate. Also you may need some iptables/sysctl rules to make forwarding, proxyarp, etc. work):

    # This file describes the network interfaces available on your system
    # and how to activate them. For more information, see interfaces(5).
    
    source /etc/network/interfaces.d/*
    
    # lo: loopback network interface
    auto lo
    iface lo inet loopback
    iface lo inet6 loopback
    
    # eno1: primary network interface - WAN
    auto eno1
    iface eno1 inet static
      address         aa.bb.cc.dd
      netmask         255.255.255.0
      gateway         aa.bb.cc.254
      pointopoint     aa.bb.cc.254
    
    iface eno1 inet6 static
      address 2001:41d0:aaaa:bbbb::1
      netmask 128
    
      pre-up ip -6 a flush dev eno1 mngtmpaddr
    
      post-up /sbin/ip -6 route add 2001:41d0:aaaa:bbff:ff:ff:ff:ff dev eno1
      post-up /sbin/ip -6 route add default via 2001:41d0:aaaa:bbff:ff:ff:ff:ff
    
      pre-down /sbin/ip -6 route del default via 2001:41d0:aaaa:bbff:ff:ff:ff:ff
      pre-down /sbin/ip -6 route del 2001:41d0:aaaa:bbff:ff:ff:ff:ff
    
    #
    # BRIDGES (host-only)
    #
    
    # vmbr0: routed hosting of VMs with public IPs
    auto vmbr0
    iface vmbr0 inet static
      address         aa.bb.cc.dd
      netmask         255.255.255.255
      bridge_ports    none
      bridge_stp      off 
      bridge_fd       0   
      bridge_maxwait  0
    
    iface vmbr0 inet6 static
      address         2001:41d0:aaaa:bbbb::1
      netmask         64 
    
    # vmbr1: internal LAN with private IPs (with access to LAN)
    auto vmbr1
    iface vmbr1 inet static
      address         10.4.30.100
      netmask         255.255.255.0
      bridge_ports    none
      bridge_stp      off
      bridge_fd       0
      bridge_maxwait  0
    
  • @exception0x876 said:
    make sure to assign a virtual mac from OVH panel to each IP, and then assign each mac to corresponding VM.

    Btw, as far as I know, OVH only supports IPv4 for assigning virtual macs. That's why I opted for routed hosting of the VMs.

  • Shoaib_AShoaib_A Member
    edited September 2016

    You can do it in conventional way( tons of tutorials are available online ) for which will you have to free 3 IPv4 addresses out of assigned block.The other (OVH) recommended way is very simple, all you have to do for each failover is as follows:

    Suppose main IP of your server is 1.1.1.1 & your IPv4 block is 2.2.2.1/30 then for example if you assign 2.2.2.1 to your first VPS the netmask & gateway will be

    IP = 2.2.2.1

    Netmask = 255.255.255.255

    Gateway = 1.1.1.254 ( IP of your main server but last octet ending in 254 )

    Similarly for 2.2.2.2

    Netmask = 255.255.255.255

    Gateway = 1.1.1.254 ( IP of your main server but last octet ending in 254 )

    Remember you have to generate vMac address for each IP from OVH Manager & use that in the VPS. If a VPS has more than one IPv4, then every IPv4 assigned to that VPS must have same vMac.


    Following is a sample configuration for bridge

    /etc/sysconfig/network-scripts/ifcfg-eth0 should look like

        DEVICE=eth0
        HWADDR=00:25:90:98:35:90
        IPV6INIT=yes
        IPV6_AUTOCONF=yes
        ONBOOT=yes
        BRIDGE=br0
    

    etc/sysconfig/network-scripts/ifcfg-br0 should look like

    DEVICE=br0
    TYPE=Bridge
    BOOTPROTO=static
    IPADDR=1.1.1.1
    NETMASK=255.255.255.0
    GATEWAY=1.1.1.254
    ONBOOT=yes
    
    Thanked by 1Falzo
  • @Shoaib_A said:

    +1 , that's totally it.

    if you use debian/ubuntu instead you might want to use POINTOPOINT in /etc/network/interfaces of the guest, we covered that lately in one of the proxmox threads ;-)

  • @exception0x876 said:
    make sure to assign a virtual mac from OVH panel to each IP, and then assign each mac to corresponding VM.

    That's why I said if it's an OVH machine and you don't mind wasting 3 IP's from the subnet just use Vrack and then it behaves like a normal subnet (They say not to use the last 3 as presumably they plan to run some kind of HSRP)

Sign In or Register to comment.