Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 15 Jun 2018 22:08:19 +0000
From:      B J <va6bmj@gmail.com>
To:        Polytropon <freebsd@edvax.de>
Cc:        freebsd@dreamchaser.org, Chris Gordon <freebsd@theory14.net>,  freebsd-questions <freebsd-questions@freebsd.org>,  Erich Dollansky <freebsd.ed.lists@sumeritec.com>
Subject:   Re: Problems Connecting Laptop To Modem
Message-ID:  <CAP7QzkMwLex37Ayv2e-P59jrmeLJA2i1y8nuTCw%2Bcjxmmp9nnw@mail.gmail.com>
In-Reply-To: <20180615233707.8645c246.freebsd@edvax.de>
References:  <CAP7QzkM7QnymxoOz_ZEUebaOMcE%2BwWmpv7sz6-SzjC0BHG6LCA@mail.gmail.com> <20180613102426.3874c581.freebsd.ed.lists@sumeritec.com> <CAP7QzkM0FdUMwtG3TDtW11T-ZTQ8QC2p6qHWn2BjEjPC8jXG9w@mail.gmail.com> <20180613162137.5cc6794a.freebsd.ed.lists@sumeritec.com> <CAP7QzkOzK=7u5Vf0FLdiz6f1%2BSbhme3RpF9MpYUoAJLqTH15qw@mail.gmail.com> <3E3890A6-72F9-4D80-A021-837FFDB35A39@theory14.net> <CAP7QzkNK2qfAL=2-og5oyAY9KLuYVXCfbZ_akbWoEP-xwCP%2BJw@mail.gmail.com> <20180614093928.6f39434e.freebsd.ed.lists@sumeritec.com> <CAP7QzkN6jtukm-ieWEaPsuo6bCTJh0xLdJYOdALVUs6fgSJtwg@mail.gmail.com> <20180614161923.5246ae81.freebsd.ed.lists@sumeritec.com> <CAP7QzkPL5732dh3%2BVmbT6mXxkiYGjUOgiHvUwWBJRk2VJK-y2w@mail.gmail.com> <20180615102548.1c686d1b.freebsd.ed.lists@sumeritec.com> <CAP7QzkODpMCy1TNRpC_-oVmatXE7V1h%2BZEds1R%2B2UCFCu76C%2BA@mail.gmail.com> <ef7f1a05-68c7-c787-5d73-c9848e30acf3@dreamchaser.org> <CAP7QzkPg%2BmQCEePf_DVZCuwybL3MLcNXAgfp1yRETk0qR50BhA@mail.gmail.com> <20180615233707.8645c246.freebsd@edvax.de>

next in thread | previous in thread | raw e-mail | index | archive | help
<snip>

> From your netstat output (later on), it seems that you
> connect to 192.168.0.1, so if this really is the IP of
> one of your machines, there's a big problem with your
> current configuration.

<snip>

> At the moment, it doesn't look like a hardware issue.

The laptop is second-hand.  It was in rough shape when I got it from
the previous owners so I'm thinking that there might be an on-board
hardware malfunction.  It might be the hard drive as it didn't want to
boot at first because of, if I remember correctly, some corrupted
sectors.

I have some extra HDs on hand.  I might try swapping one of those with
the one that's in the machine, installing FreeBSD, and then seeing if
I get the same problem.

Since the laptop's not essential to what I do at home, I may as well
have a bit of fun with it, right?

>
> My suggestion:
>
> Take a machine that properly connects to your modem/router and
> gains Internet access this way as desired. Collect information
> about which values exist on your network. Don't guess values. :-)
>
> The following commands should work on FreeBSD and Linux:
>
> 	# arp -a
>
> 	# netstat -rn
>
> 	# ifconfig -a
>
> (depending on Linux, the "ip" program has to be used instead)
>
> Even though it might sound stupid, use pen & paper to make a
> small diagram of your network. Write down the IPs and other
> elements of the configuration.
>
> If you have a Linux live system connecting without any further
> configuration, it's quite possible you have a DHCP server in
> your modem/router running. In that case, don't try to configure
> things manually, it will just interfere with this mechanism.
> Instead, use
>
> 	ifconfig_nfe0="DHCP"
>
> in /etc/rc.conf. A variation is
>
> 	ifconfig_nfe0="SYNCDHCP"
>
> Check /etc/rc.conf for duplicate entries. The _last_ entry
> of the same kind will be in effect, as it's basically just
> a shell script with assignments to shell variables.
>
> Of course you need to specify the default router address, but
> don't guess it - determine it from a different system. If it
> is the _default_ address that your modem/router uses (and you
> didn't change it), maybe consult its documentation, the address
> should be listed there. It can be things like 192.168.0.1,
> 192.168.1.1, 192.168.178.1, who knows.
>
> Check if HDCP populated /etc/resolv.conf. In many settings,
> the modem/router will also be a nameserver (even if it just
> "relays" your queries and the replies). This means: The IP
> you're seeing there is the IP of your modem/router.
>
> In worst case, don't configure anything in /etc/rc.conf and do
> a little experimentation. Run a tcpdump (or maybe Wireshark,
> ex Ethereal) on your network interface and then do all the steps
> manually: Configure the interface, set default routing, try to
> obtain an IP via DHCP (using dhclient), and see it /etc/resolv.conf
> gets populated (which DHCP should fill with the correct values).
> Then try to ping internally with IP, extermally with IP, try to
> resolve a hostname, ping it, open a browser for a HTTP connection,
> and so on. Monitor what you're doing as initially mentioned (to
> see if you actually _see_ what you expect, like ARP messages,
> a DHCP handshake, ICMP pings, and HTTP traffic). If this all
> works, make the settings permanent - even if you only verified
> that using DHCP was the correct thing to begin with. :-)
>
> Good luck!

<snip>

> PS.
> "Trial & error" is not a programming concept. ;-)

I've been writing code off and on for more than 40 years, going back
to the days of WATFOR and WATFIV.  Trial-and-error programming helped
me finish my B. Sc.

Thanks to everyone for all the advice and information.

Two things have come from this.  One is that I finally set up my tower
machines so that the systems on them are now nearly identical to what
I have on my laptop.  I've been meaning to do this for years but I had
little incentive to do so.

The second one is that I'm learning something about networking, which
should help me with what I have at home.

BMJ



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CAP7QzkMwLex37Ayv2e-P59jrmeLJA2i1y8nuTCw%2Bcjxmmp9nnw>