Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 548490 - Determining Network Interface Name
Summary: Determining Network Interface Name
Status: RESOLVED FIXED
Alias: None
Product: [OLD] Docs on www.gentoo.org
Classification: Unclassified
Component: Installation Handbook (show other bugs)
Hardware: AMD64 Linux
: Normal normal (vote)
Assignee: Matthew Marchese
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-05-03 13:37 UTC by John L. Poole
Modified: 2016-01-16 00:58 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description John L. Poole 2015-05-03 13:37:37 UTC
The AMD64 Handbook at https://wiki.gentoo.org/wiki/Handbook:AMD64/Installation/Networking has:

Automatic network detection
...
 the remainder of this document, we will assume that the interface is called eth0.

Then several pages later at https://wiki.gentoo.org/wiki/Handbook:AMD64/Installation/System#Networking_information

under Configuring the network there is:

If after booting the system we find out that the assumption about the network interface name (which is currently documented as eth0) was wrong, then execute the following steps to rectify this:

    Update the /etc/conf.d/net file with the correct interface name (like enp3s0 instead of eth0)
    Create new symbolic link (like /etc/init.d/net.enp3s0)
    Remove the old symbolic link (rm /etc/init.d/net.eth0)
    Add the new one to the default runlevel
    Remove the old one using rc-update del net.eth0 default

The problem I ran into is I got the the above stage and my network connection which automatically was configured for my by the Install Disk could not be configured because it was renamed and not the assumed eth0.  At this point, I had no tools to determine what the name assigned to my network had been.

The above statements suggesting "correcting" assume the user knew what the name of the network interface was.  I did not and there I found myself without the means to determine (since lspci was not a standard installed tool).  I posted this issue in the Gentoo Forum and there were several suggestions, the best of which I this is to instruct the user to "look in /sys/class/net"

I am assuming the looking at /sys/class/net at that time during an installation will work; it certainly does a completed system.  May of the the other suggestions word on a completed system or one that has extra tools installed and did not take into account what the user is faced with at the point of the installation where everything may not be complete.

See https://forums.gentoo.org/viewtopic.php?p=7741906#7741906 for dicussion.
Some of the suggestions I had tried when I was in that point and they did not reveal the name assigned to the interface.  I finally ended up reboot with the Install Disk and visually capturing the network assigned name during boot up before login of root.

Reproducible: Always

Steps to Reproduce:
1.Install a new system using the AMD64 Handbook.

Actual Results:  
could not determine what the name assigned to my network interface was

Expected Results:  
Should be able to determine the name, or should have been warned to note the name earlier on in the Busy Box session for future reference.
Comment 1 charles17 2015-05-03 15:49:35 UTC
Sounds like one more good reason for dropping the Gentoo net.* scripts stuff from the handbook. See Bug 534752
Comment 2 Matthew Marchese Gentoo Infrastructure gentoo-dev 2016-01-15 23:07:51 UTC
You seem to have skipped the first part of the network section:

https://wiki.gentoo.org/wiki/Handbook:AMD64/Installation/Networking#Automatic_network_detection

If you look at the first paragraph and the following command-line output in the link above you can see the ifconfig utility (which is included on all minimal install CDs) is used to determine the network interface name. The handbook cannot include cases for every interface name because many exist, therefore we assume the standard old name and move on.

Perhaps next time you can simply ping someone for support in #gentoo before you open a bug.

With that being said, I'll add a little more information to the handbook so it's abundantly clear, and I'll provide a link back to said information so that users who jump around or miss sections will know where to find the information.

You can see the new information here:

https://wiki.gentoo.org/wiki/Handbook:AMD64/Installation/Networking#Determine_interface_names

Charles, someone missing a section in the handbook is no valid reason to drop support for the network interface scripts. :)
Comment 3 John L. Poole 2016-01-16 00:58:38 UTC
Thank you for attending to this and improving the documentation.

I opened a topic on the forum and filed a bug at the suggestion of a veteran member, charles17, after I had disclosed:

   I had tried "ifconfig -a" and only "lo" showed up.