Re: [PLUG] Understanding Networking Components [SOLVED]

2012-04-03 Thread Larry Brigman
Yes, you are correct. A static config won't take the interface down so it
won't flush the routes.
On Apr 3, 2012 5:28 PM, "Mike Connors"  wrote:

> >
> > > > It shouldn't be in a "running" state unless there is physical
> > > connectivity
> > > > and packets are flowing across the interface.
> > >
> > >The eth0 interface is not RUNNING, but the routes are there and so
> is
> > > the
> > > constipation.
> > >
> > Actually you are wrong on this point.  As you stated earlier today, once
> > you 'ifconfig eth0 down' things worked.  If that was truely the case then
> > the interface was up but
> > without a carrier.  The routes would remain intact as the kernel doesn't
> > know when or if the network carrier will return.
> >
> > Larry - I also found that statement confusing, however from my own
> testing
> I think it's behaving that way do the static ip config of eth0.
>
> With a static ip addr config for eth0 in /etc/network/interfaces, ifup /
> ifdown will insert and remove the default route. However, the state as
> shown by ifconfig never shows as "running" because there is no carrier.
>
> However, if there wasn't a static ip addr config for eth0 and it was up I
> would expect no routes for that interface to be injected in the routing
> table because there's nothing configured and with no carrier, the eth0
> interface isn't learning any routes to propagate.
> ___
> PLUG mailing list
> PLUG@lists.pdxlinux.org
> http://lists.pdxlinux.org/mailman/listinfo/plug
>
___
PLUG mailing list
PLUG@lists.pdxlinux.org
http://lists.pdxlinux.org/mailman/listinfo/plug


Re: [PLUG] Understanding Networking Components [SOLVED]

2012-04-03 Thread Mike Connors
>
> > > It shouldn't be in a "running" state unless there is physical
> > connectivity
> > > and packets are flowing across the interface.
> >
> >The eth0 interface is not RUNNING, but the routes are there and so is
> > the
> > constipation.
> >
> Actually you are wrong on this point.  As you stated earlier today, once
> you 'ifconfig eth0 down' things worked.  If that was truely the case then
> the interface was up but
> without a carrier.  The routes would remain intact as the kernel doesn't
> know when or if the network carrier will return.
>
> Larry - I also found that statement confusing, however from my own testing
I think it's behaving that way do the static ip config of eth0.

With a static ip addr config for eth0 in /etc/network/interfaces, ifup /
ifdown will insert and remove the default route. However, the state as
shown by ifconfig never shows as "running" because there is no carrier.

However, if there wasn't a static ip addr config for eth0 and it was up I
would expect no routes for that interface to be injected in the routing
table because there's nothing configured and with no carrier, the eth0
interface isn't learning any routes to propagate.
___
PLUG mailing list
PLUG@lists.pdxlinux.org
http://lists.pdxlinux.org/mailman/listinfo/plug


Re: [PLUG] Understanding Networking Components [SOLVED]

2012-04-03 Thread Rich Shepard
On Tue, 3 Apr 2012, Larry Brigman wrote:

> Actually you are wrong on this point.  As you stated earlier today, once
> you 'ifconfig eth0 down' things worked.  If that was truely the case then
> the interface was up but without a carrier.  The routes would remain
> intact as the kernel doesn't know when or if the network carrier will
> return.

Larry,

   I'm not a network admin so when I see that an interface is up but not
running I assume it's not working. What I uderstand you tell me is that
regardless of whether an interface is running, if it's up the kernel sees
it.

   The Dell, and previous portables, have all been configured the same way
and this issue never came up. Next time I have the Dell at a wifi hot spot
I'll look at the routing table and see what it shows.

Thanks,

Rich

___
PLUG mailing list
PLUG@lists.pdxlinux.org
http://lists.pdxlinux.org/mailman/listinfo/plug


Re: [PLUG] Understanding Networking Components [SOLVED]

2012-04-03 Thread Larry Brigman
On Tue, Apr 3, 2012 at 1:33 PM, Rich Shepard wrote:

> On Tue, 3 Apr 2012, Mike Connors wrote:
>
> > I cannot get my eth0 to go in / out of the "running" state by running
> ifup
> > / ifdown, although it works with the loopback interface.
>
>On Slackware, using 'ifconfig eth0 up|down' I can.
>
> > Also, two default routes on the same network and I have no problems.
>
>Same here with all hosts other than this one Sony Vaio.
>
> > So if the only difference between your two laptops in terms of wireless,
> is
> > the radio and more importantly the driver. Which you had problems with
> > previously. I'm inclined to believe that driver is not functioning the
> way
> > it should be.
> >
> > It shouldn't be in a "running" state unless there is physical
> connectivity
> > and packets are flowing across the interface.
>
>The eth0 interface is not RUNNING, but the routes are there and so is
> the
> constipation.
>
Actually you are wrong on this point.  As you stated earlier today, once
you 'ifconfig eth0 down' things worked.  If that was truely the case then
the interface was up but
without a carrier.  The routes would remain intact as the kernel doesn't
know when or if the network carrier will return.
___
PLUG mailing list
PLUG@lists.pdxlinux.org
http://lists.pdxlinux.org/mailman/listinfo/plug


Re: [PLUG] Understanding Networking Components [SOLVED]

2012-04-03 Thread Rich Shepard
On Tue, 3 Apr 2012, Mike Connors wrote:

> I cannot get my eth0 to go in / out of the "running" state by running ifup
> / ifdown, although it works with the loopback interface.

   On Slackware, using 'ifconfig eth0 up|down' I can.

> Also, two default routes on the same network and I have no problems.

   Same here with all hosts other than this one Sony Vaio.

> So if the only difference between your two laptops in terms of wireless, is
> the radio and more importantly the driver. Which you had problems with
> previously. I'm inclined to believe that driver is not functioning the way
> it should be.
>
> It shouldn't be in a "running" state unless there is physical connectivity
> and packets are flowing across the interface.

   The eth0 interface is not RUNNING, but the routes are there and so is the
constipation.

> As for the script idea, why not just remove the "allow-hotplug eth0"
> statement from your /etc/network/interfaces file

   'Cause Slackware doesn't have that file. We have /etc/rc.d/rc.inet1.conf
where the ethernet and wireless interfaces are configured (but the latter
isn't in any case).

   May well be a still-immature driver since this version of the wireless
chip came out only last November.

   I need a script to keep things simple for the user. And, I have such a
script using 'ip' which I did not know existed before.

Thanks,

Rich

___
PLUG mailing list
PLUG@lists.pdxlinux.org
http://lists.pdxlinux.org/mailman/listinfo/plug


Re: [PLUG] Understanding Networking Components [SOLVED]

2012-04-03 Thread Rich Shepard
On Tue, 3 Apr 2012, Rich Shepard wrote:

>   Now, what I'd like from you networking gurus is a script I can put in
> rc.local to test if wlan0 is RUNNING. And, if it is, to take down eth0.
> This way eth0 is taken out of the stack when the system boots and dhcpcd
> sees a WAP, but otherwise it is turned on and RUNNING to use the attached
> cable.

   I have a working script. It uses 'ip' to show what's on wlan0 and brings
eth0 up or down depending on the results.

Rich


___
PLUG mailing list
PLUG@lists.pdxlinux.org
http://lists.pdxlinux.org/mailman/listinfo/plug


Re: [PLUG] Understanding Networking Components [SOLVED]

2012-04-03 Thread Mike Connors
>
>   Running 'ifconfig -a' showed routes for both eth0 and wlan0, but only the
> latter was RUNNING. So, as root, I ran 'ifconfig eth0 down' to remove the
> routes and ... voila! That was the problem.
>
> Now, what I'd like from you networking gurus is a script I can put in
> rc.local to test if wlan0 is RUNNING. And, if it is, to take down eth0.
> This
> way eth0 is taken out of the stack when the system boots and dhcpcd sees a
> WAP, but otherwise it is turned on and RUNNING to use the attached cable.
>

I'm glad to hear you got this sorted out. If the interface is down (not
running) any routes for that interface should not be included in the
routing table. Which is what confused me and why I thought you had a stale
route table cache entry.

I cannot get my eth0 to go in / out of the "running" state by running ifup
/ ifdown, although it works with the loopback interface.

Also, two default routes on the same network and I have no problems.

:~# netstat -r
Kernel IP routing table
Destination Gateway Genmask Flags   MSS Window  irtt
Iface
10.0.0.0*   255.255.255.0   U 0 0  0
wlan0
10.0.0.0*   255.255.255.0   U 0 0  0
eth0
default 10.0.0.10.0.0.0 UG0 0  0
eth0
default 10.0.0.10.0.0.0 UG0 0  0
wlan0

So if the only difference between your two laptops in terms of wireless, is
the radio and more importantly the driver. Which you had problems with
previously. I'm inclined to believe that driver is not functioning the way
it should be.

It shouldn't be in a "running" state unless there is physical connectivity
and packets are flowing across the interface.

As for the script idea, why not just remove the "allow-hotplug eth0"
statement from your /etc/network/interfaces file

allow-hotplug eth0
iface eth0 inet dhcp

"When the Linux kernel detects the physical interface eth0, the *
allow-hotplug* stanza causes ifup to bring up the interface."

That should keep the interface down and trouble free. Then just plug in the
cable and "ifup eth0".
___
PLUG mailing list
PLUG@lists.pdxlinux.org
http://lists.pdxlinux.org/mailman/listinfo/plug


Re: [PLUG] Understanding Networking Components [SOLVED]

2012-04-03 Thread Rich Shepard
On Mon, 2 Apr 2012, Russell Johnson wrote:

> Nothing would be going out eth0, since it's not connected to anything,
> and, as per Rich's message, it's not in a running state. As I recall, the
> IPs Rich reported are in two different subnets, so, in theory, the IP
> stack should try both routes, if there are two routes in the routing
> table.

   Running 'ifconfig -a' showed routes for both eth0 and wlan0, but only the
latter was RUNNING. So, as root, I ran 'ifconfig eth0 down' to remove the
routes and ... voila! That was the problem.

   I've run linux on the previous 6 portables and did not have this issue
with any of them, including my older Sony Vaio. But, this new Sony Vaio does
have this issue.

   Now, what I'd like from you networking gurus is a script I can put in
rc.local to test if wlan0 is RUNNING. And, if it is, to take down eth0. This
way eth0 is taken out of the stack when the system boots and dhcpcd sees a
WAP, but otherwise it is turned on and RUNNING to use the attached cable.

   Such a script is needed for the Sony's user because it requires no
knowledge or skill to properly set up the networking interfaces.

Thanks very much to all of you,

Rich

___
PLUG mailing list
PLUG@lists.pdxlinux.org
http://lists.pdxlinux.org/mailman/listinfo/plug