Diff between tun/tap and some specific routing methods

Need help configuring your VPN? Just post here and you'll get that help.

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

Forum rules
Please use the [oconf] BB tag for openvpn Configurations. See viewtopic.php?f=30&t=21589 for an example.
Post Reply
jeffmonte
OpenVpn Newbie
Posts: 3
Joined: Fri Nov 25, 2011 4:49 am

Diff between tun/tap and some specific routing methods

Post by jeffmonte » Mon Nov 28, 2011 5:08 am

Hi there,

I am new to VPN setups and wanting to learn it. To be frank I have been trying to get a working setup for over 2 months and atleast I amlike OMG I did it. The only thing I am currently having is a VPN server with tun interface.

Why do I need to use TAP? Any real time examples? Also I am not familiar with those routing methods? Why do we use them and for what purpose?

When I use the currnet config file and connect with my server, I am not seeing my IP is changing from my local ISP to that server IP? Any suggestion about that?

but I can confirm that I am able to ping google from that tun interface created by , ping -I tun0 google.com

I am using openvz VPS. Thanks for any point you could give me. I am ready to hear all you geeks advices :)

User avatar
janjust
Forum Team
Posts: 2703
Joined: Fri Aug 20, 2010 2:57 pm
Location: Amsterdam
Contact:

Re: Diff between tun/tap and some specific routing methods

Post by janjust » Mon Nov 28, 2011 8:22 am

A 'tun' device will suffice for most purposes. It is a virtual point-to-point device that is capable of routing all kinds of IP traffic.
A 'tap' device is a virtual Ethernet device and is used when you need to tunnel non-IP traffic, e.g. IPX, AppleTalk.
It is also used for bridging, where a LAN adapter is bridged to the 'tap' device: all traffic which is received on one interface , is broadcast out the other interface. This is sometimes useful for gaming, older network protocols (NetBEUI). The general rule of thumb is: if you don't need bridging , don't use it. It's trickier to set up and can reduce performance by 50%.

To check that your tunnel is working , go to
http://www.whatismyip.com
and check the IP address: it should the address of the VPN server (depending on how you have set up routing).

Post Reply