LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Guessnet-ifupdown sees no device – and then in some case founds it though (https://www.linuxquestions.org/questions/linux-newbie-8/guessnet-ifupdown-sees-no-device-%96-and-then-in-some-case-founds-it-though-4175432334/)

HRS1064 10-15-2012 01:04 PM

Guessnet-ifupdown sees no device – and then in some case founds it though
 
I have my /etc/network/interfaces configured for multiple interface profiles to be chosen by guessnet script. That's because I want to use my laptop both at work (static address) and at home (dhcp). The file looks like so:

Code:

# The loopback network interface
auto lo
iface lo inet loopback

# The primary network interface
auto eth0
#allow-hotplug eth0
mapping eth0
        script guessnet-ifupdown
        map verbose: true
        #autofilter: true
        map eth0-work
        map eth0-home       
iface eth0 inet static
        address 213.175.108.176
        netmask 255.255.255.0
        network 213.175.108.0
        broadcast 213.175.108.255
        gateway 213.175.108.254
        # dns-* options are implemented by the resolvconf package, if installed
        dns-nameservers 213.175.108.2 195.13.129.5 91.198.156.20
        dns-search cfi.lu.lv
        test peer address 213.175.108.254 mac 58:8d:09:13:31:40

iface eth0-home inet dhcp
        #actually don't know how to check dhcp, but it will automatically fall back to the none :)
        test peer address 46.109.88.1
iface none inet dhcp

But when the script is run at startup by ifupdown, it outputs the following:

Code:

guessnet: Link beat detection (mii) failed: No such device
guessnet: 0 candidate profiles
guessnet: Interface eth0 was down: initializing for broadcast
guessnet: Sending 10 ARP probes, 1 every second...
Internet Systems Consortium DHCP Client 4.1.1-P1
Copyright 2004-2010 Internet Systems Consortium.
All rights reserved.
For info, please visit https://www.isc.org/software/dhcp/

Listening on LPF/eth0/04:7d:7b:8d:5a:23
Sending on  LPF/eth0/04:7d:7b:8d:5a:23
Sending on  Socket/fallback
DHCPDISCOVER on eth0 to 255.255.255.255 port 67 interval 6
DHCPDISCOVER on eth0 to 255.255.255.255 port 67 interval 13
DHCPOFFER from 46.109.88.1
DHCPREQUEST on eth0 to 255.255.255.255 port 67
DHCPACK from 46.109.88.1
bound to 81.198.37.234 -- renewal in 1688 seconds.

That's the case if I try to invoke the interface at home - script falls back to "none" and manages to configure eth0. But when I am at work this, of course, do not work. What could be the reason? Thanks in advance!

P. S.
uname -r output:
3.2.0-0.bpo.3-amd64
I am on Debian 6.0.5; the laptop model is Lenovo IdeaPad Z580A. Ethernet controller is: Realtek Semiconductor Co., Ltd. RTL8101E/RTL8102E PCI Express Fast Ethernet controller (rev 05) (output from lspci).

purevw 10-16-2012 09:43 AM

Quote:

iface eth0 inet static
address 213.175.108.176
netmask 255.255.255.0
network 213.175.108.0
broadcast 213.175.108.255
gateway 213.175.108.254
# dns-* options are implemented by the resolvconf package, if installed
dns-nameservers 213.175.108.2 195.13.129.5 91.198.156.20
dns-search cfi.lu.lv
test peer address 213.175.108.254 mac 58:8d:09:13:31:40
Just guessing, but shouldn't that read "iface eth0-work inet static"? Other than that, I would just verify that the IP address is allowed by the router and that it's not already in use by someone else. I am not familiar with guessnet, but with normal ifup, I thought that "broadcast" would be the hostname of your computer or any name you want to broadcast to the network and "network" would be the domain or possibly workgroup name.

HRS1064 10-16-2012 10:28 AM

Quote:

Originally Posted by purevw (Post 4807209)
Just guessing, but shouldn't that read "iface eth0-work inet static"?

My shame :) It was indeed so some time ago. This syntax error appeared when I was trying to use one single configuration only (when at work), but that does not matter here. Nevertheless, fixing that error gives no help - "No such device" persists.

And actually internet did work via eth0 at work with all static settings listed - when I was using the laptop at work only (and the system was also installed at work with all static data entered that time). Problems started when I began to seech how to use internet both at work and at home.

Also, I could notice that "No such device" appears at home, too - where dhcp is present. So it seems to me there is no trouble with ifupdown settings...

HRS1064 10-21-2012 01:16 PM

Possibly traced
 
Dealing with another problem, noticed such a message on rebuilding initrd:

W: Possible missing firmware /lib/firmware/rtl_nic/rtl8168f-2.fw for module r8169
W: Possible missing firmware /lib/firmware/rtl_nic/rtl8168f-1.fw for module r8169

So I will try to dig forward in this direction and report here, despite being a complete fool :) Maybe somebody else will ever had a similar problem.

purevw 10-22-2012 07:10 AM

If you haven't already found it,: http://www.realtek.com/Downloads/dow...&GetDown=false

Realtek lists many Linux drivers for your NIC. I assume that the proprietary driver would have it's own firmware. Hope this helps.

HRS1064 10-22-2012 01:39 PM

Thank you for the link, I have already installed these non-free firmware packages from Debian testing repository (and update-initramfs does not complain since), but - I am heavily puzzled :) The device had worked well with one static configuration before I decided to try guessnet. It works well when guessnet falls back to the "none" option and chooses dhcp. Why guessnet does not see it before ?!..

And what is interesting. If I add some dummy interface configuration (static) with "missing-cable" test, guessnet initially displays message "0 candidate profiles" and then... obviously selects the dummy profile (not the "none" profile), as there are no messages from DHCP client further.

So it seems to me that guessnet is the only program that has problem with managing my Ethernet controller... What should I do now?..

HRS1064 11-03-2012 11:37 AM

Could anybody help me, please? :)


All times are GMT -5. The time now is 09:57 AM.