Hello,
I made a GRE Tunnel to transfer a subnet / 29.
It's just that internet on VPS doesn't work outside because of the wrong bridge configuration.
Thank you!
PHP Code IP SV1: x.158
IP SV2: x.242
IP /29: x.192/29
Bridge: bridge0
SV1:
ip tunnel add gre1 mode gre remote x.242 local x.158 ttl 255
ip link set gre1 up
ip route add x.192/29 dev gre1
SV2:
ip tunnel add gre1 mode gre remote x.158 local x.242 ttl 255
ip link set gre1 up
ip rule add from x.192/29 table 666
ip route add default dev gre1 table 666
ip route add x.192/29 dev bridge0 table 666
ip addr add x.193/29 dev bridge0
SV 2 - /etc/sysconfig/network-scripts/ifcfg-bridge0
DEVICE=bridge0
TYPE=Bridge
ONBOOT=yes
BOOTPROTO=static
IPADDR="x.194"
NETMASK="x.248"
GATEWAY="x.193"
SV 2 - /etc/sysconfig/network-scripts/ifcfg-eth0
# Created by cloud-init on instance boot automatically, do not edit.
#
BOOTPROTO=dhcp
DEVICE=eth0
HWADDR=fa:16:3e:9a:2f:d2
MTU=1500
ONBOOT=yes
TYPE=Ethernet
USERCTL=no
|