Page 1 of 1

Network connections come up after ifdown'ing them?[Solved]

Posted: 30 Jan 2015, 13:56
by rgroner
I'm using Porteus to test a network switch. The way we test it is we have 8 ethernet interfaces connected to the 8 ports of the switch. We turn on one ethernet interface at a time (ifconfig eth1 up), download some data from the attached network, and then turn off the interface (ifconfig eth1 down).

The test works great, as long as only one interface is up at a time. If more than 1 is up, then the test can silently fail because there would be multiple paths to the attached network, which means we're not necessarily testing the interface we want.

I'm using python to do all of this, to form the commands and then execute them. I take each ethernet interface down (ifconfig eth0 down), and then check ifconfig to make sure the interface IS down (ifconfig | grep eth0). When they are all down, I can begin the test. However, I have seen several times now that after I put the last ethernet interface down (ifconfig eth7 down), that suddenly ethernet interfaces are coming up and getting IP addresses. I execute (ifconfig | grep 192.168) and it shows several entries. That causes the test to stop because there should not have been any ethernet interfaces up and running.

That's all background.

Is there some reason an ethernet interface would come back up after it has been taken down? And if there there a way to keep that from happening? I need the ethernet interfaces to only come up when I want them to.

Re: Network connections come up after ifdown'ing them?

Posted: 30 Jan 2015, 17:13
by fanthom
have you stopped Network Manager in the system?
please boot with 'nonetwork' cheatcode and that should resolve this.

Re: Network connections come up after ifdown'ing them?

Posted: 30 Jan 2015, 18:58
by rgroner
Hmm....shoulda known there was a cheatcode for that. there anything they can't do?? :good:

It appears to be better far no interfaces are resurrecting themselves.