Link to home
Start Free TrialLog in
Avatar of Neo-Rio
Neo-Rio

asked on

1 ethernet port, multiple virtual interfaces, multiple DHCP servers. How to set up?

I have a laptop running FreeBSD 4.10 which has one ethernet port (fxp0)

I have so far configured the ethernet port and kernel to support three vlan virtual interfaces with static IPs. (vlan0, vlan1, vlan2). So far, I have got this working.

What I want to do now is make each of my vlan interfaces connect to a DHCP server to get their own IP adresses on different networks, but here's the catch: each vlan interface needs to connect to a different DHCP server.

I figure that since there's only one default gateway on the machine, all DHCP requests are going to end up at one DHCP server, therefore making all 3 virtual vlan interfaces get an IP from the same network. I don't want this to happen.

I know that in FreeBSD, rc.conf can be edited so that an interface gets its IP from DHCP (for example, ifconfig_fxp0="DHCP"

Is there any way I can set up rc.conf to get each virtual interface to point to a different DHCP server? If not, is there some set of commands I can use to do this?

Thanks
Avatar of gheist
gheist
Flag of Belgium image

DHCP is for ethernet and not for vlan.
VLAN is fot those whose ethernet switches decode it.

Please describe your problem in understandable manner with commands you run and errors you get ...
Avatar of Neo-Rio
Neo-Rio

ASKER

Ok, here's a more concise question:

Can I, or can I not, set a virtual vlan interface to receive an IP from a specified DHCP server within FreeBSD?

I can set an ethernet interface to receive DHCP with ifconfig_fxp0="DHCP".
If I do ifconfig_vlan0="DHCP", then no IP address is taken for the interface, and the vlan interface remains with no IP address.
ASKER CERTIFIED SOLUTION
Avatar of gheist
gheist
Flag of Belgium image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial