How to create openvpn tunnel between multiple interface hos

Samples of working configurations.

Moderators: TinCanTech, TinCanTech, TinCanTech, TinCanTech, TinCanTech, TinCanTech

Post Reply
kumarraj
OpenVpn Newbie
Posts: 2
Joined: Wed Jan 14, 2015 7:32 am

How to create openvpn tunnel between multiple interface hos

Post by kumarraj » Wed Jan 14, 2015 7:38 am

Hi,
I want to create openvpn tunnel between two host.
Each host has two interfaces.
Say,
Host1 > eth0,eth1
Host2 > eth1,eth2

I want to create tunnel between ,
1) Host1's eth0 to Host2's eth0 as well as Host1's eth1 to Host2's eth1.
How to create this.
Do I need to create two bridges for each interfaces and tap0 for br0 and eth0, tap1 for br1 and eth1.
Is it correct?.
But in openvpn server.conf, I can write dev tap, but how to add multiple bridge (br0,br1), two taps (tap0 and tap1) in the config file?.
Any example can i get.
How to do the routing, iptables for this.
2) Do i need to create taps, bridges same like server in client machine also.
How to add it in client.cong.
Do I need any specific configuration in client machine.

3) In any openvpn install guide it show I need to run couple of commands and need to create key,etc. And copy the keys to client machine. Is it enough or I need to all server install guide like steps in client machine.
In my case I just installed openvpn and copy the certificates from server.
What are the important certificates do i need at clent side.
4) When I just run openvpn commands in command prompt it didn't create tun or tap interfaces automatically.
I used modprobe tun and sudo modprobe bridge. then used the commands openvpn --mktun --dev tap0 in seperate script. is it need to create sepeartely before run openvpn.

Please provide yours valuable inputs on above questions.

Thanks,
Kumarraj

User avatar
maikcat
Forum Team
Posts: 4200
Joined: Wed Jan 12, 2011 9:23 am
Location: Athens,Greece
Contact:

Re: How to create openvpn tunnel between multiple interface

Post by maikcat » Wed Jan 14, 2015 9:12 am

I want to create openvpn tunnel between two host.
Each host has two interfaces.
Say,
Host1 > eth0,eth1
Host2 > eth1,eth2
try a different approach...
forget interfaces and think ips,
also what you are trying to achieve? loadbalance?

Michael.

Post Reply