Can't connect to anything

jayxkanz666

Member


Messages: 32

Hey there! So, I'm pretty new to to the FreeBSD forums (signed up today), and I seem to be having a strange issue with internet on FreeBSD.
The internet worked fine for about 1 hour a couple of days ago, then suddenly stopped working.
My Ethernet controller is a Qualcomm Atheros AR8162 Fast Ethernet (rev 10) and my WiFi controller is a Broadcom Limited BCM43142 802.11b/g/n (rev 01) (I'm pretty sure this one doesn't work on FreeBSD, so I'm trying to get the Ethernet to work).
I've tried reinstalling FreeBSD multiple times and switching between DHCP and a static IP, but that didn't help.

Here's my rc.conf:
Code:
hostname="jayxbsd"
kldload_i915kms="i915kms"
zfs_enable="YES"
ifconfig_alc0="DHCP"
samba_enable="YES"
Here's the output of netstat -rn:
Code:
Routing tables

Internet:
Destination      Gateway      Flags      Netif expire
default            192.168.0.1  UGS       alc0
127.0.0.0/8     127.0.0.1      UGS       lo0
127.0.0.1         link#2          UH         lo0
192.168.0.0/24 link#1          U           alc0

Internet6:
Destination        Gateway      Flags      Netif expire
::/96                 ::1               UGRS     lo0
::1                    link#2           UH         lo0
::ffff:0.0.0.0/96 ::1                UGRS     lo0
fe80::/10          ::1                UGRS     lo0
fe80::1%lo0      link#2           U           lo0
ff02::/16           ::1                UGRS     lo0
My router gateway is 192.168.0.1 if you're wondering.

 

forquare

Well-Known Member

Reaction score: 123
Messages: 271

Welcome to the forums :)

Can you ping IP addresses? E.g. Your default gateway? Something on the internet like 8.8.8.8?

If you can, double check /etc/resolv.conf is correct. It should look something like:

Code:
nameserver 192.168.0.1
 
OP
OP
jayxkanz666

jayxkanz666

Member


Messages: 32

Thanks for the welcome!

No, I can not ping anything. Not my router or anything on the internet.

My /etc/resolv.conf is:
Code:
nameserver 192.168.0.1
This has been bothering me for days, and I can't figure out what's wrong.
 
OP
OP
jayxkanz666

jayxkanz666

Member


Messages: 32

ifconfig says:
Code:
alc0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500
    options=c319a<TXCSUM,VLAN_MTU,VLAN_HWTAGGING,VLAN_HWCSUM,TSO4,WOL_MCAST,WOL_MAGIC,VLAN_HWTSO,LINKSTATE>
    ether 20:89:84:96:53:a3
    inet 0.0.0.0 netmask 0xff000000 broadcast 255.255.255.255
    inet 169.254.211.214 netmask 0xffff0000 broadcast 169.254.255.255
    nd6 options=29<PERFORMNUD,IFDISABLED,AUTO_LINKLOCAL>
    media: Ethernet autoselect (100baseTX <full-duplex>)
    status: active
lo0: flags=8049<UP,LOOPBACK,RUNNING,MULTICAST> metric 0 mtu 16384
    options=600003<RXCSUM,TXCSUM,RXCSUM_IPV6,TXCSUM_IPV6>
    inet6 ::1 prefixlen 128
    inet6 fe80::1%lo0 prefixlen 64 scopeid 0x2
    inet 127.0.0.1 netmask 0xff000000
    nd6 options=21<PERFORMNUD,AUTO_LINKLOCAL>
    groups: lo
I think it has 2 inet addresses because I have both dhclient and dhcpcd.
That shouldn't matter though and it's not a router problem because when I run
Code:
# dhclient alc0
tcpdump shows that my router is replying and giving a DHCP offer, dhclient just isn't accepting it. dhcpcd is just assigning a IPv4LL address which is completely useless.
 

ShelLuser

Son of Beastie

Reaction score: 1,702
Messages: 3,514

No, I can not ping anything. Not my router or anything on the internet.
What are the actual error messages you got? Unless you share that then all we can do is guess. Can you share some output by any chance?
 
OP
OP
jayxkanz666

jayxkanz666

Member


Messages: 32

What are the actual error messages you got? Unless you share that then all we can do is guess. Can you share some output by any chance?
With dhclient I get
Code:
error: sendto: No route to host
And with dhcpcd(IPv4LL) I get
Code:
error: sendto: Host is down
 

ShelLuser

Son of Beastie

Reaction score: 1,702
Messages: 3,514

With dhclient I get
Code:
error: sendto: No route to host
That seems quite off. What command did you try? Also try using the -d parameter and see what the output tells you.

Also: what error did you get when you used ping?

(edit): also: how did you use ping? With an IP address or hostname?
 

balanga

Son of Beastie

Reaction score: 111
Messages: 2,732

Personally, I would try installing FreeBSD using the mini-memstick image... That establishes an Internet connection if it can and then you don't subsequently need to figure out how to set it up.
 
OP
OP
jayxkanz666

jayxkanz666

Member


Messages: 32

That seems quite off. What command did you try? Also try using the -d parameter and see what the output tells you.

Also: what error did you get when you used ping?

(edit): also: how did you use ping? With an IP address or hostname?
No, I meant if I use dhcpcd/dhclient, that's what ping outputs. I used an IP address, namely 8.8.8.8

Outputs:
Code:
[jayxkanz@jayxbsd ~]$ sudo dhclient alc0
DHCPDISCOVER on alc0 to 255.255.255.255 port 67 interval 4
DHCPDISCOVER on alc0 to 255.255.255.255 port 67 interval 10
DHCPDISCOVER on alc0 to 255.255.255.255 port 67 interval 15
DHCPDISCOVER on alc0 to 255.255.255.255 port 67 interval 7
DHCPDISCOVER on alc0 to 255.255.255.255 port 67 interval 14
DHCPDISCOVER on alc0 to 255.255.255.255 port 67 interval 9
DHCPDISCOVER on alc0 to 255.255.255.255 port 67 interval 2
No DHCPOFFERS received.
No working leases in persistent database - sleeping.

[jayxkanz@jayxbsd ~]$ sudo dhcpcd -d alc0
using config file `/usr/local/etc/dhcpcd.conf'
dhcpcd-7.0.0-alpha starting
alc0: executing `/usr/local/libexec/dhcpcd-run-hooks' PREINIT
alc0: executing `/usr/local/libexec/dhcpcd-run-hooks' CARRIER
DUID 00:01:00:01:20:b6:f9:9e:20:89:84:96:53:a3
alc0: IAID 84:96:53:a3
alc0: delaying IPv6 router solicitation for 0.6 seconds
alc0: delaying IPv4 for 0.4 seconds
alc0: soliciting a DHCP lease
alc0: sending DISCOVER (xid 0x1a6336b3), next in 3.9 seconds
alc0: soliciting an IPv6 router
alc0: sending Router Solicitation
alc0: sending DISCOVER (xid 0x1a6336b3), next in 7.5 seconds
alc0: sending Router Solicitation
alc0: using IPv4LL address 169.254.211.214
alc0: adding route to 169.254.0.0/16
alc0: adding default route
alc0: ARP announcing 169.254.211.214 (1 of 2), next in 2.0 seconds
alc0: executing `/usr/local/libexec/dhcpcd-run-hooks' IPV4LL
forking to background
forked to background, child pid 10284
 

balanga

Son of Beastie

Reaction score: 111
Messages: 2,732

If you managed to install over your network, then networking was working fine when you installed, so something has changed... Maybe check your cabling...
 
OP
OP
jayxkanz666

jayxkanz666

Member


Messages: 32

If you managed to install over your network, then networking was working fine when you installed, so something has changed... Maybe check your cabling...
Cables are fine. The internet did *not* work in the installer. I used the memstick image, not the mini-memstick one.
 

ShelLuser

Son of Beastie

Reaction score: 1,702
Messages: 3,514

I used the memstick image for all of my reinstalls.
Then something doesn't add up. Because that image requires an Internet connection in order to download the rest *, yet what you showed above demonstrated that your machine can't get an IP address because no DHCP server can be reached.

And the odds that a live system would work after which the installed system would fail are quite slim.

What FreeBSD version are you trying to install / use anyway?

* Wrong conclusion on my part.
 
OP
OP
jayxkanz666

jayxkanz666

Member


Messages: 32

Then something doesn't add up. Because that image requires an Internet connection in order to download the rest, yet what you showed above demonstrated that your machine can't get an IP address because no DHCP server can be reached.

And the odds that a live system would work after which the installed system would fail are quite slim.

What FreeBSD version are you trying to install / use anyway?
FreeBSD 12.0-CURRENT
 

ShelLuser

Son of Beastie

Reaction score: 1,702
Messages: 3,514

FreeBSD 12.0-CURRENT
There's your problem then; that's a developer snapshot which is basically unstable. There are no guarantees that it'll run at all. You'd normally only use this to look for problems (and possible answers) yourself, in fact that's more or less expected.

My suggestion is to stick with a public release instead which is also actually supported. Like FreeBSD 11.
 
OP
OP
jayxkanz666

jayxkanz666

Member


Messages: 32

There's your problem then; that's a developer snapshot which is basically unstable. There are no guarantees that it'll run at all. You'd normally only use this to look for problems (and possible answers) yourself, in fact that's more or less expected.

My suggestion is to stick with a public release instead which is also actually supported. Like FreeBSD 11.
I wouldn't say that's the problem, because I've tried 11-RELEASE too and have the same issue.
 

ShelLuser

Son of Beastie

Reaction score: 1,702
Messages: 3,514

I wouldn't say that's the problem, because I've tried 11-RELEASE too and have the same issue.
Hmm, I carefully re-read the whole thread again and noticed that I overlooked one comment: that you also didn't have an Internet connection during the installation phase (I am curious how you checked though). I edited my previous post accordingly because I also drew a wrong conclusion there.

Even so: using 12-CURRENT wasn't a good decision. There's a reason why this forum doesn't officially support that version and even somewhat discourages its use.

Right now I can only conclude that the cause of this problem lies elsewhere (also because things used to work, then suddenly didn't and reinstalling (thus also rebooting) didn't change anything). What does the output of ifconfig alc0 look like?

The only possibilities I can come up with right now is a hardware problem somewhere, or maybe some kind of negotiation problem between your NIC and the router. Although uncommon it is possible that if both the NIC and the router port are set to auto-negotiate that clashes can happen, usually resulting in less optimal settings but I could imagine that in extreme cases no valid connection gets setup (though do I find that scenario highly unlikely).

You said it worked for a few hours then stopped. Tried turning the PC off for a few hours and then tried again? Wouldn't solve anything but could get you leads to the cause of all this.
 

balanga

Son of Beastie

Reaction score: 111
Messages: 2,732

No. I don't feel like reinstalling it again because I actually have some important stuff on that harddrive now.
You can always try installing on a USB device, even a micro SDHC card. You could mount the other drive and copy the important stuff in case it gets lost.
 
OP
OP
jayxkanz666

jayxkanz666

Member


Messages: 32

Hmm, I carefully re-read the whole thread again and noticed that I overlooked one comment: that you also didn't have an Internet connection during the installation phase (I am curious how you checked though). I edited my previous post accordingly because I also drew a wrong conclusion there.

Even so: using 12-CURRENT wasn't a good decision. There's a reason why this forum doesn't officially support that version and even somewhat discourages its use.

Right now I can only conclude that the cause of this problem lies elsewhere (also because things used to work, then suddenly didn't and reinstalling (thus also rebooting) didn't change anything). What does the output of ifconfig alc0 look like?

The only possibilities I can come up with right now is a hardware problem somewhere, or maybe some kind of negotiation problem between your NIC and the router. Although uncommon it is possible that if both the NIC and the router port are set to auto-negotiate that clashes can happen, usually resulting in less optimal settings but I could imagine that in extreme cases no valid connection gets setup (though do I find that scenario highly unlikely).

You said it worked for a few hours then stopped. Tried turning the PC off for a few hours and then tried again? Wouldn't solve anything but could get you leads to the cause of all this.
Hey, thanks for the help. I do not believe that it is a hardware problem since Ethernet/WiFi works fine on my Linux installation.
I've had the computer turned off for several hours (even though I doubt that would fix anything).

As you requested, here is the output of ifconfig alc0:
Code:
    alc0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500
    options=c319a<TXCSUM,VLAN_MTU,VLAN_HWTAGGING,VLAN_HWCSUM,TSO4,WOL_MCAST,WOL_MAGIC,VLAN_HWTSO,LINKSTATE>
    ether 20:89:84:96:53:a3
    inet 169.254.211.214 netmask 0xffff0000 broadcast 169.254.255.255 
    inet 0.0.0.0 netmask 0xff000000 broadcast 255.255.255.255 
    inet6 fe80::2289:84ff:fe96:53a3%alc0 prefixlen 64 scopeid 0x1 
    inet6 fe80::ab27:7ab:84d:58c0%alc0 prefixlen 64 scopeid 0x1 
    nd6 options=1<PERFORMNUD>
    media: Ethernet autoselect (100baseTX <full-duplex>)
    status: active
 

balanga

Son of Beastie

Reaction score: 111
Messages: 2,732

Hey, thanks for the help. I do not believe that it is a hardware problem since Ethernet/WiFi works fine on my Linux installation.
I've had the computer turned off for several hours (even though I doubt that would fix anything).

As you requested, here is the output of ifconfig alc0:
Code:
    inet 169.254.211.214 netmask 0xffff0000 broadcast 169.254.255.255
That sounds as though you are not getting an IP address assigned from the DHCP server...
 

tingo

Daemon

Reaction score: 373
Messages: 1,981

Why does your machine have an APIPA IP address? How is your machine connected to your internet? via a switch or something?
You haven't accidentally connected it a a machine running Windows of some sort?
 
Top