Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.

I just installed FreeBSD 9 on a new laptop and I'm having some trouble getting the network cards to work. Presumably the file representing the cards is in /dev, but where would the configuration files be? In /etc? Any tutorial or guidance in this matter would be greatly appreciated.

share|improve this question

1 Answer 1

up vote 1 down vote accepted

First of all, run ifconfig to get a list of all interfaces known to the kernel. In FreeBSD, interfaces are named after the driver module that controls them, so you might see em0, rl0, or any number of other things.

Once you know the name of the interface, you need a few settings in /etc/rc.conf. If you want to use dhcp, it's simple. (I will assume you have an Intel PRO/1000 card, which uses the em driver).

ifconfig_em0="DHCP"

That should be enough to get you on the network. If you use static IP addresses, you'll need something like this, substituting suitable values, instead:

ifconfig_em0="inet 192.168.0.34 netmask 255.255.255.0"
defaultrouter="192.168.0.1"

You can then either reboot the machine and let the startup process start the network card, or you can run /etc/rc.d/netif start to do it immediately.

share|improve this answer
    
Thank you! Much appreciated. –  Edgar Aroutiounian May 10 '13 at 13:04

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.