Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
root@remote:~# cat /etc/openvpn/server.conf | grep -v "^#" | grep -v "^;" | uniq -u
port 1194
proto udp
dev tap
up "/etc/openvpn/up.sh br0 eth1"
ca ca.crt
cert myservername.crt
key myservername.key # This file should be kept secret
dh dh2048.pem
ifconfig-pool-persist ipp.txt
server-bridge 192.168.1.111 255.255.255.0 192.168.1.240 192.168.1.254
client-to-client
keepalive 10 120
comp-lzo
persist-key
persist-tun
status openvpn-status.log
verb 3
root@remote:~#
@jonvargas

This comment has been minimized.

Copy link
Owner Author

commented Apr 1, 2016

And this is some further information about the server's network configuration:

root@remote:~# ifconfig 
br0       Link encap:Ethernet  HWaddr 08:00:27:cf:35:42  
          inet addr:192.168.1.111  Bcast:192.168.1.255  Mask:255.255.255.0
          inet6 addr: fe80::a00:27ff:fecf:3542/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:419 errors:0 dropped:0 overruns:0 frame:0
          TX packets:8 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0 
          RX bytes:40840 (40.8 KB)  TX bytes:648 (648.0 B)

eth0      Link encap:Ethernet  HWaddr 08:00:27:de:61:a1  
          inet addr:192.168.1.6  Bcast:192.168.1.255  Mask:255.255.255.0
          inet6 addr: fe80::a00:27ff:fede:61a1/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:5123 errors:0 dropped:0 overruns:0 frame:0
          TX packets:4010 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:415240 (415.2 KB)  TX bytes:497076 (497.0 KB)

eth1      Link encap:Ethernet  HWaddr 08:00:27:cf:35:42  
          UP BROADCAST RUNNING PROMISC MULTICAST  MTU:1500  Metric:1
          RX packets:40107 errors:0 dropped:0 overruns:0 frame:0
          TX packets:11 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:4828001 (4.8 MB)  TX bytes:906 (906.0 B)

lo        Link encap:Local Loopback  
          inet addr:127.0.0.1  Mask:255.0.0.0
          inet6 addr: ::1/128 Scope:Host
          UP LOOPBACK RUNNING  MTU:65536  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0 
          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)

tap0      Link encap:Ethernet  HWaddr ca:af:b0:79:0a:4b  
          inet6 addr: fe80::c8af:b0ff:fe79:a4b/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:429 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:100 
          RX bytes:0 (0.0 B)  TX bytes:47538 (47.5 KB)

root@remote:~# cat /etc/network/interfaces
# This file describes the network interfaces available on your system
# and how to activate them. For more information, see interfaces(5).

# The loopback network interface
auto lo
iface lo inet loopback

# The primary network interface
auto eth0
iface eth0 inet static
    address    192.168.1.6
    netmask    255.255.255.0
    gateway    192.168.1.1
    dns-nameservers  192.168.1.1

auto eth1
iface eth1 inet manual
    up ip link set $IFACE up promisc on

auto br0
iface br0 inet static
  address 192.168.1.111
  netmask 255.255.255.0
  bridge_ports eth1
root@remote:~# route -n
Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
0.0.0.0         192.168.1.1     0.0.0.0         UG    0      0        0 eth0
192.168.1.0     0.0.0.0         255.255.255.0   U     0      0        0 eth0
192.168.1.0     0.0.0.0         255.255.255.0   U     0      0        0 br0
root@remote:~# sysctl net.ipv4.ip_forward
net.ipv4.ip_forward = 1
root@remote:~# 
@jonvargas

This comment has been minimized.

Copy link
Owner Author

commented Apr 1, 2016

Client's Network Manager configuration of the VPN Connection:
https://www.dropbox.com/s/srn2uzyhe80q910/Selection_207.png?dl=0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.