Can not config the network

Hello folks,

I am newbie to BSD world. Just now, I install FreeBSD 8 and then follow with the BSD manual, modify /etc/rc.conf as adding
Code:
ifconfig_em0="inet 192.168.1.102 netmask=255.255.255.0"
and save/reboot. When system startup again, it seems the IP address is not set successfully. I check and retry for 3 times, still failed.

Would you please give me any hint?

Thanks,

Phillip
 
sixtydoses said:
Try:

Code:
ifconfig_em0="inet 192.168.1.102 netmask 255.255.255.0"

Ops original syntax was rrong. This ^^ is correct syntax.
If this doesn't work, check your interface name, maybe it's not em0 :D
 
Beastie said:
And how do you know the IP address is not set successfully? Execute % ifconfig em0.

ifconfig won't set the address when the syntax is wrong

Code:
gnome:~# ifconfig em1
em1: flags=8802<BROADCAST,SIMPLEX,MULTICAST> metric 0 mtu 1500
	options=9b<RXCSUM,TXCSUM,VLAN_MTU,VLAN_HWTAGGING,VLAN_HWCSUM>
	ether 00:04:23:bd:10:89
	media: Ethernet autoselect (1000baseT <full-duplex>)
	status: active
gnome:~# ifconfig em1 192.1.1.1 netmask=255.255.255.0 
ifconfig: netmask=255.255.255.0: bad value
gnome:~# ifconfig em1
em1: flags=8802<BROADCAST,SIMPLEX,MULTICAST> metric 0 mtu 1500
	options=9b<RXCSUM,TXCSUM,VLAN_MTU,VLAN_HWTAGGING,VLAN_HWCSUM>
	ether 00:04:23:bd:10:89
	media: Ethernet autoselect (1000baseT <full-duplex>)
	status: active
 
Hi folks,

It is my mistake(should remove "=") and I will be more careful in future.

All of your kindly help make me feel more confidence on traveling BSD world, thanks a lot.

Phillip
 
Back
Top