LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Networking (https://www.linuxquestions.org/questions/linux-networking-3/)
-   -   Help with virtual interfaces (https://www.linuxquestions.org/questions/linux-networking-3/help-with-virtual-interfaces-670171/)

swordphsh 09-15-2008 10:14 PM

Help with virtual interfaces
 
i'm trying to find a way to send specific traffic through a certain virtual ethernet device.

Here's my setup:
i'm in a college dorm with a 180KB/s cap per mac address, so i'm trying to figure out a way to download a file through one interface and use another interface for my web browsing, etc.

Thanks in advance.

Mr. C. 09-16-2008 12:25 AM

The virtual interfaces share the physical MAC address.
The kernel routing table determines which by interface packets leave your system. Your applications don't make this decision.

CRC123 09-16-2008 12:51 AM

Mr. C is right, but I think I may have an idea:

VMware can create virtual machines that use bridged networking. In this setup, the virtual NIC gets its own MAC address. I am fairly certain that even though it accesses the network through the physical card in your computer, it still looks like it is a separate NIC on the network (the reason I suspect this is b/c my router can hand out IP's to the virtual NIC by looking at its MAC address). In this set up, I would use the virtual machine to do web surfing and the physical NIC to do downloads. This set up also has its security advantages so that if you get a virus while web surfing, it's contained in the virtual machine and not your physical machine.

NOTE: Some college's (and network's in general) will block access based on MAC addresses. Did you have to run a program or fill out any forms to be granted network access at your college?

Mr. C. 09-16-2008 12:56 AM

... and another possible problem. Smart switches can recognize and associate a single MAC address with a switch port, and block all but the first MAC address in operation.

swordphsh 09-16-2008 12:33 PM

So the virtual interface mac cannot be changed using ifconfig?...I figured it could, but haven't played around with it yet.

Quote:

The kernel routing table determines which by interface packets leave your system. Your applications don't make this decision.
That said, lets say I have 2 physical interfaces, is what I want to do possible? I used to do it on Windows by giving each interface the same default gateway and prioritizing the connection to one, starting the download, then prioritizing the other connection so everything after that would go through the second interface.

To what CRC123 said:
The VMware idea does work, that's what I normally use, but am looking for a better solution.
Also, the school allows an unlimited amount of macs to be registered per user and it will allow any mac, as long as it's registered with their system.

Thanks again for the quick replies.

Mr. C. 09-16-2008 01:19 PM

You can use policy-based routing. See:

http://lartc.org/howto/index.html
http://www.policyrouting.org/PolicyR...NLINE/TOC.html
http://linux-ip.net/html/ch-routing.html


All times are GMT -5. The time now is 12:27 PM.