February 9th, 2010, 06:53 AM
[OpenBSD] Error with static IP
I've just installed OpenBSD for the second time in the last 24 hours and I'm still wondering:
Why do I get the message "nfe0: No link.." when I've set static ip?
When I'm running sh /etc/netstart I get the message:
dhcp NONE NONE NONE NONE
inet 10.1.1.5 255.255.255.0 NONE
But, when I'm running dhclient nfe0 (and putting the cable into the modem) I get internet and everything is OK.
nfe0: no link ........... sleeping
The clue is that I'm not going to have internet on this, just a local machine.
And, when I'm running ifconfig nfe0 inet 10.1.1.5 netmask 255.255.255.0 and trying to ping other machines on the local network, I get the message Host is down, but it's not..
Output of ifconfig nfe0:
nfe0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> mtu 1500
media: Ethernet autoselect (none)
status: no carrier
inet6 xxxx:211:9ff:fec0:e597%nfe0 prefixlen 64 scopeid 0x1
inet 10.1.1.5 netmask 0xffffff00 broadcast 10.1.1.255
Why do I get the annoying message nfe0: no link ........... sleeping?
edit: Added some more info.
edit2: added ifconfig
February 12th, 2010, 01:40 AM
Odd. Status shows "no carrier". This means it doesn't think that the jack is plugged into the card.
Wait a minute, did you say you had two lines in /etc/hostname.nfe0. The first line is incorrect. There should be only one line there if you want a static IP:
What's happening is that when you have the dhcp line there, it is sending packets trying to connect to a DHCP server. Since you don't have the network card connected, that fails.
inet 10.1.1.5 255.255.255.0 10.1.1.255
Up the Irons
What Would Jimi Do? Smash amps. Burn guitar. Take the groupies home.
"Death Before Dishonour, my Friends!!" - Bruce D ickinson, Iron Maiden Aug 20, 2005 @ OzzFest
Down with Sharon Osbourne
"I wouldn't hire a butcher to fix my car. I also wouldn't hire a marketing firm to build my website." - Nilpo