Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
[SOLVED] Interface enp3s0 does not exist.
View unanswered posts
View posts from last 24 hours

Goto page 1, 2  Next  
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware
View previous topic :: View next topic  
Author Message
tupn
n00b
n00b


Joined: 11 Sep 2019
Posts: 24

PostPosted: Mon Feb 10, 2020 7:24 am    Post subject: [SOLVED] Interface enp3s0 does not exist. Reply with quote

Greetings,

During my kernel configuration for Docker earlier today, I made the mistake of ignoring the emerge message after docker got installed (warning me about the kernel configs I needed to enable to ensure proper functionality) and instead followed Docker's wiki article to reconfigure my kernel. I recompiled, installed modules and installed the kernel with the new settings and afterwards rebooted my system.

Ever since, when I boot up, my net interface fails to start up:

Code:
Bringing up interface enp3s0
ERROR: Interface enp3s0 does not exist
Ensure that you have loaded the correct module for your hardware


Surprisingly, I also noted that, I must have committed yet another mistake, for I also lost my audio playback after the re-configuration, although, this is a small issue compared to losing my internet access, therefore it's not that important for the time being.

Now when I do ip addr, only two interfaces exist:

Code:
1. lo: <LOOPBACK,UP,LOWER_UP> ... state UNKNOWN ...
...
2. bond0: <BROADCAST,MULTICAST,MASTER> ... state DOWN...
...


I honestly don't know what to do now. It's clear that after I reconfigured the kernel and rebooted, my Ethernet connection vaporized.

Thank you,

tupn[/profile]


Last edited by tupn on Wed Feb 12, 2020 8:24 pm; edited 1 time in total
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 44921
Location: 56N 3W

PostPosted: Mon Feb 10, 2020 11:17 am    Post subject: Reply with quote

tupn,

grep your dmesg for eth0. If that's missing, the kernel module is not loaded.
udev mangles the name to enp3s0 later if you don't stop it.

bond0 is created as a synthetic interface of one or more physical interfaces.
The individual members of a bond do not get IP addresses, just the bond.
Its used to say make a 2Gbit interface out of two 1Gbit physical cards.

Whatever, it all starts with the kernel finding eth0
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
krinn
Watchman
Watchman


Joined: 02 May 2003
Posts: 7368

PostPosted: Mon Feb 10, 2020 1:53 pm    Post subject: Reply with quote

might help you :) https://forums.gentoo.org/viewtopic-p-7746228.html#7746228
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 44921
Location: 56N 3W

PostPosted: Mon Feb 10, 2020 2:09 pm    Post subject: Reply with quote

krinn,

That should be on the wiki.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
krinn
Watchman
Watchman


Joined: 02 May 2003
Posts: 7368

PostPosted: Mon Feb 10, 2020 3:34 pm    Post subject: Reply with quote

NeddySeagoon wrote:
krinn,

That should be on the wiki.

If someone wish add it, i won't claim any credits for it :)
Back to top
View user's profile Send private message
tupn
n00b
n00b


Joined: 11 Sep 2019
Posts: 24

PostPosted: Mon Feb 10, 2020 4:21 pm    Post subject: Reply with quote

NeddySeagoon wrote:
tupn,

grep your dmesg for eth0. If that's missing, the kernel module is not loaded.
udev mangles the name to enp3s0 later if you don't stop it.

bond0 is created as a synthetic interface of one or more physical interfaces.
The individual members of a bond do not get IP addresses, just the bond.
Its used to say make a 2Gbit interface out of two 1Gbit physical cards.

Whatever, it all starts with the kernel finding eth0


Greetings neddy,

Thank you

I executed the grep for the dmesg looking for "eth0":

Code:
 dmesg | grep -iC 5 "eth0"


And effectively, it returned no results, this means I should re-load the correspondent module. What is the name of the module I should look for the "eth0" interface? I'm honestly clueless about that.

Greetings krinn,

Thank you, I'll shortly check the link to see if it helps too.
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 44921
Location: 56N 3W

PostPosted: Mon Feb 10, 2020 7:13 pm    Post subject: Reply with quote

tupn,

There are lots of different ethernet drivers. You need the right one for your hardware.
eth0 is the first ethernet interface detected by the kernel, eth1 the second and so on.

To determine the module you need, we need to see the ethernet lines from
Code:
lspci -nnk

Let me do a worked example, you follow the process, not the actual module I end up with, unless you need the same module as me.

You may have more that one network card. Apply this process to them all.
Code:
$  lspci -nnk | grep net
0a:06.0 Ethernet controller [0200]: Realtek Semiconductor Co., Ltd. RTL8169 PCI Gigabit Ethernet Controller [10ec:8169] (rev 10)
   Subsystem: Realtek Semiconductor Co., Ltd. RTL8169/8110 Family PCI Gigabit Ethernet NIC [10ec:8169]

So I have a Realtek RTL8169/8110 Family card.
The important bit is the 10ec:8169 at the end of the first line. 10ec is the vendor ID and 8169 is the device ID.
Go to google. Put 10ec:8169 pci linux into the search box. You use your vendor ID and device ID.
Repeat for each interface.

My first hit is
Code:
https://cateee.net/lkddb/web-lkddb/R8169.html

The top line is
Code:
CONFIG_R8169: Realtek 8169/8168/8101/8125 ethernet support

CONFIG_R8169 is the kernel configuration symbol name I need.
If you have several interfaces, you will generate a list of required symbol names.

Go to the kernel build procees.
In menuconfig, press / to search and enter the first symbol name that you need. The CONFIG_ part can be omitted.
Press the digit next to your symbol name to go there.
Select it as * built in, as you want it all the time.

If the search fails, your symbol depends on something that is off, so your symbol is hidden.
Come out of the search and press 'z'. That toggles the display of hidden symbols.
Repeat the search. Go to the option you would like to select.
Read its Depends on: in the help.

Your symbol will be hidden until the Depends on: boolean expression evaluates to true.
Applying the process above recursively, fix your Depends on: boolean expression.
Now select the option you really wanted.

Repeat for any other interfaces you have.

Rebuild and reinstall your kernel. It that worked, after the reboot, your network interface should appear.
Do check you are running your new kernel. The date and time in
Code:
uname -a
is the build date and time of the running kernel.
If it looks wrong, you are probably not running the kernel you think you are.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
tupn
n00b
n00b


Joined: 11 Sep 2019
Posts: 24

PostPosted: Mon Feb 10, 2020 10:16 pm    Post subject: Reply with quote

Greetings neddy,
Thank you again

I performed the lspci nnk grep and it gave me the name of the module I should load on my kernel (CONFIG_NET_VENDOR_ATHEROS)

This is where things started getting odd. I went to my make menuconfig, found the setting, and to my surprise, it was already activated. I then proceeded to de-activate it, recompile & install and rebooted, and, activate it again (with all it's modules, to be sure) and recompiled & installed and rebooted yet again. Now, I ran the command:

Code:
uname -a

And the output was
Code:
Linux (domain) 5.3.2 #1 SAP Tue Oct 8 13:04:51 CST 2019 (my cpu info)

As you stated, my kernel version is fine (I started with the 4.19.66 kernel and then upgraded to 5.3.2, in October), however, the date is way off by four months.

I then went to my grub and I could see various entries:

Gentoo GNU/Linux, with Linux x86_64 - 5.3.2-gentoo (the one it's currently booting to by default)
Gentoo GNU/Linux, with Linux 5.3.2-gentoo (the odd one)
Gentoo GNU/Linux, with Linux 4.19.66-gentoo

When I try to boot into the second kernel entry, it fails to boot (stating that the root device could not be found in this device). However I can not into the first one (x86_64 5.3.2/default grub entry and 4.19.66), both with no Ethernet access.

And as previously stated, the uname -a brings a wrong build date

Now, I should also mention that, after building my kernel earlier this week and installing it with support for Docker (or so did I think), and after rebooting, when the interface issue appeared, I attempted to rollback to my previous config file from October by copying it from /boot/ into my current config (bad mistake, as the uname -a seems to denote):

Code:
cp /boot/config-5.3.2-gentoo /usr/src/linux/.config


Afterwards I proceeded to make and make install, and reboot (all of this was prior to creating the thread, but still, my apologies for not stating this in the OP in the first place). Seems like my disorganized way of handling this hasn't helped at all.

Should I start by cleaning all my kernel sources from my system and grub, building, installing and re-writing the current install to the grub config file?

My apologies again, for I'm not being too clear/consistent with this issue and it seems to run even deeper than I thought.
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 44921
Location: 56N 3W

PostPosted: Mon Feb 10, 2020 11:09 pm    Post subject: Reply with quote

tupn,

Lets start with the easy things that trip people up first.
Boot your gentoo, with no network and look at the output of
Code:
date

That's your system time, it should be within a second or two of your wall clock time.

The no network is important. We want to check system time before its corrected by ntpd.
The other way to do this is to look in the BIOS but the BIOS will be UTC.

If your time is not correct all sorts of strange things happen with build systems. Especially if your time takes a step back.
*NIX time must be monotonic.

If your system clock is OK, what do you have in /boot.
Code:
ls -l /boot

If you have a separate /boot partition, the right answer is nothing because its not mounted by default.
The give away is that the grub directory will be missing if this is not the real boot.
This /boot is the mount point where your boot partition will be mounted. Anything here will be hidden by that.
Code:
mount /boot
and look again. Even if the file names are the same, the timestamps are different.
This is the boot that grub will see and use.

Its a popular error to forget to mount /boot before installing the kernel. Then the kernel is correctly installed to the wrong location and grub cannot use it.
If this is your problem, be sure /boot is mounted then repeat the make install and updating grub.cfg steps.

If your time was correct, the kernel build was probably good. Then the reboot should produce the
Code:
uname -a
you are expecting.

No need to rip anything out or rebuild yet.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
tupn
n00b
n00b


Joined: 11 Sep 2019
Posts: 24

PostPosted: Tue Feb 11, 2020 12:36 am    Post subject: Reply with quote

NeddySeagoon wrote:
tupn,

Lets start with the easy things that trip people up first.
Boot your gentoo, with no network and look at the output of
Code:
date

That's your system time, it should be within a second or two of your wall clock time.

The no network is important. We want to check system time before its corrected by ntpd.
The other way to do this is to look in the BIOS but the BIOS will be UTC.

If your time is not correct all sorts of strange things happen with build systems. Especially if your time takes a step back.
*NIX time must be monotonic.

If your system clock is OK, what do you have in /boot.
Code:
ls -l /boot

If you have a separate /boot partition, the right answer is nothing because its not mounted by default.
The give away is that the grub directory will be missing if this is not the real boot.
This /boot is the mount point where your boot partition will be mounted. Anything here will be hidden by that.
Code:
mount /boot
and look again. Even if the file names are the same, the timestamps are different.
This is the boot that grub will see and use.

Its a popular error to forget to mount /boot before installing the kernel. Then the kernel is correctly installed to the wrong location and grub cannot use it.
If this is your problem, be sure /boot is mounted then repeat the make install and updating grub.cfg steps.

If your time was correct, the kernel build was probably good. Then the reboot should produce the
Code:
uname -a
you are expecting.

No need to rip anything out or rebuild yet.


Greetings,
Thank you again neddy,

My wall clock (and UTC) indicates: HH:MM:SS

So I ran date, with no network:
Code:
date
mon feb 10 HH:MM+1:SS ... on tty

Now, I went to the BIOS and checked my UTC time:
Code:
HH:MM+1:SS

So both, in comparison to UTC and Wall clock are showing over a time discrepancy of +1 minute.

Running ls -l /boot:
Code:

total 87496
-rw-r--r-- 1 root root  164147 sep 18 17:26 config-4.19.66-gentoo
-rw-r--r-- 1 root root  171834 feb 10 15:27 config-5.3.2-gentoo
-rw-r--r-- 1 root root  171774 feb 10 15:06 config-5.3.2-gentoo.old
-rw-r--r-- 1 root root  177068 feb  1 21:56 config-5.5.0-gentoo
-rw-r--r-- 1 root root  178149 feb  1 20:55 config-5.5.0-gentoo.old
drwxr-xr-x 2 root root    1024 ago 28 12:43 efi
drwxr-xr-x 6 root root    1024 feb 10 00:58 grub
-rw-r--r-- 1 root root 7834504 ago 28 12:04 initramfs-genkernel-x86_64-4.19.66-gentoo
-rw-r--r-- 1 root root 8141668 oct  8 13:21 initramfs-genkernel-x86_64-5.3.2-gentoo
-rw-r--r-- 1 root root 6513312 ago 28 11:52 kernel-genkernel-x86_64-4.19.66-gentoo
-rw-r--r-- 1 root root 6755488 oct  8 13:08 kernel-genkernel-x86_64-5.3.2-gentoo
drwx------ 2 root root   12288 ago 28 10:10 lost+found
-rw-r--r-- 1 root root 3283350 sep 18 17:26 System.map-4.19.66-gentoo
-rw-r--r-- 1 root root 3507816 feb 10 15:27 System.map-5.3.2-gentoo
-rw-r--r-- 1 root root 3507816 feb 10 15:06 System.map-5.3.2-gentoo.old
-rw-r--r-- 1 root root 3935629 feb  1 21:56 System.map-5.5.0-gentoo
-rw-r--r-- 1 root root 4065320 feb  1 20:55 System.map-5.5.0-gentoo.old
-rw-r--r-- 1 root root 3278524 ago 28 11:52 System.map-genkernel-x86_64-4.19.66-gentoo
-rw-r--r-- 1 root root 3457019 oct  8 13:08 System.map-genkernel-x86_64-5.3.2-gentoo
-rw-r--r-- 1 root root 6529696 sep 18 17:26 vmlinuz-4.19.66-gentoo
-rw-r--r-- 1 root root 6845600 feb 10 15:27 vmlinuz-5.3.2-gentoo
-rw-r--r-- 1 root root 6845600 feb 10 15:06 vmlinuz-5.3.2-gentoo.old
-rw-r--r-- 1 root root 6935712 feb  1 21:56 vmlinuz-5.5.0-gentoo
-rw-r--r-- 1 root root 7271584 feb  1 20:55 vmlinuz-5.5.0-gentoo.old

unfortunately shows an output too, which means that by default, my /boot/ partition is getting mounted (it can also be seen when I run mount /boot, as it warns me that /boot is already mounted on /dev/sda*.
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 44921
Location: 56N 3W

PostPosted: Tue Feb 11, 2020 12:52 am    Post subject: Reply with quote

tupn,

Its not wrong to have boot auto mounted, it just not the gentoo standard.
A 1 minute difference is fine.

Your new kernel is there
Code:
-rw-r--r-- 1 root root 6845600 feb 10 15:27 vmlinuz-5.3.2-gentoo
so your kernel install worked correctly.
To boot that kernel, you need an entry in /boot/grub/grub.cfg.
It will start
Code:
linux vmlinuz-5.3.2-gentoo


If its missing, rewrite /boot/grub/grub.cfg.
If its there, make a note of where it is in the menu structure than try to boot it. It need not be the default kernel.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
tupn
n00b
n00b


Joined: 11 Sep 2019
Posts: 24

PostPosted: Tue Feb 11, 2020 2:28 am    Post subject: Reply with quote

NeddySeagoon wrote:
tupn,

Its not wrong to have boot auto mounted, it just not the gentoo standard.
A 1 minute difference is fine.

Your new kernel is there
Code:
-rw-r--r-- 1 root root 6845600 feb 10 15:27 vmlinuz-5.3.2-gentoo
so your kernel install worked correctly.
To boot that kernel, you need an entry in /boot/grub/grub.cfg.
It will start
Code:
linux vmlinuz-5.3.2-gentoo


If its missing, rewrite /boot/grub/grub.cfg.
If its there, make a note of where it is in the menu structure than try to boot it. It need not be the default kernel.


Greetings neddy,

Thank you again

Indeed, the linux vmlinuz-5.3.2-gentoo existed in the grub.cfg file, but just in case, I re wrote the entry with grub-mkconfig. Now, when I boot to my 5.3.2 entry (not the default), during boot I still get the following error:
Code:
Could not find the root block device in UUID= <my uuid>

Which is odd, so I checked my grub.cfg to see if the root block device was the same as the one from my old kernel sources and of course, my default one, and, indeed:
(cat of my grub.cfg in the pastebin link)
Code:
 https://pastebin.com/cqwfcC41

Seems that we are getting closer to solving this.
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 44921
Location: 56N 3W

PostPosted: Tue Feb 11, 2020 11:42 am    Post subject: Reply with quote

tupn,

Explain how you configure and build your kernel please.

Code:
Could not find the root block device in UUID=
shows that the kernel could not locate the filesystem with your UUID.
The kernel can't do this unaided. It needs the userspace mount utility. Which must be provided in an initrd.

Genkernel builds you a fully modular kernel and puts the modules and user space tools into the initrd.
The kernel can identify bits of itself so that modules made or another kernel cannot be loaded into some other kernel.
This approach means that every time you rebuild the kernel, you must also rebuild the initrd, so that you have matching modules.

There is another approach that does not need an initrd.
Everything to mount root must be built into the kernel because any modules required will be on the root filesystem.
You may not use a module, stored on the root filesystem to mount the root filesystem to read the module required to mount the root filesystem.

You are booting your
Code:
-rw-r--r-- 1 root root 6845600 feb 10 15:27 vmlinuz-5.3.2-gentoo

The matching initrd is
Code:
-rw-r--r-- 1 root root 8141668 oct  8 13:21 initramfs-genkernel-x86_64-5.3.2-gentoo

except that from the build date, its not matching, so the modules needed won't load into your new kernel.

This brings us to the second approach to building your own kernel. Everything to mount root must be built into the kernel.
That's not a lot. Its the SCSI stack, to use your HDD controller, The root filesystem driver, to read the root filesystem and the partition table code to read the partition table on the drive housing the root filesystem.
As you won't have an initrd, root=UUID=... in grub.cfg will fail by design.
You must either use the block device name root=/dev/... which is not very robust because device names can change if you add or remove a device.
Using root=PARTUUID= is something the kernel understands.
PARTUUID is a property of a partition. UUID is a property of a filesystem.

e.g. here is my /dev/sde1 showing both its UUID= and PARTUUID=
Code:
$ blkid
/dev/sde1: UUID="c400b18c-0210-4338-a0fd-f437ecbaaf99" BLOCK_SIZE="1024" TYPE="ext4" PARTLABEL="ext4" PARTUUID="150e6ef1-7ba8-409c-9c3f-dbdecdc9f18b"


There is one more wart. Users with root on raid or inside LVM (or both) still need an initrd to assemble the raid and start LVM. However, it won't contain any kernel modules.

Long story short ... and dirty hack
Edit your grub.cfg to swap out root=UUID=... root=PARTUUID=<some other number> and it might just work.
This is test only. You manual edit will be reverted next time you rewrite grub.cnf but that can be fixed too.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
tupn
n00b
n00b


Joined: 11 Sep 2019
Posts: 24

PostPosted: Tue Feb 11, 2020 12:07 pm    Post subject: Reply with quote

NeddySeagoon wrote:
tupn,

Explain how you configure and build your kernel please.

Code:
Could not find the root block device in UUID=
shows that the kernel could not locate the filesystem with your UUID.
The kernel can't do this unaided. It needs the userspace mount utility. Which must be provided in an initrd.

Genkernel builds you a fully modular kernel and puts the modules and user space tools into the initrd.
The kernel can identify bits of itself so that modules made or another kernel cannot be loaded into some other kernel.
This approach means that every time you rebuild the kernel, you must also rebuild the initrd, so that you have matching modules.

There is another approach that does not need an initrd.
Everything to mount root must be built into the kernel because any modules required will be on the root filesystem.
You may not use a module, stored on the root filesystem to mount the root filesystem to read the module required to mount the root filesystem.

You are booting your
Code:
-rw-r--r-- 1 root root 6845600 feb 10 15:27 vmlinuz-5.3.2-gentoo

The matching initrd is
Code:
-rw-r--r-- 1 root root 8141668 oct  8 13:21 initramfs-genkernel-x86_64-5.3.2-gentoo

except that from the build date, its not matching, so the modules needed won't load into your new kernel.

This brings us to the second approach to building your own kernel. Everything to mount root must be built into the kernel.
That's not a lot. Its the SCSI stack, to use your HDD controller, The root filesystem driver, to read the root filesystem and the partition table code to read the partition table on the drive housing the root filesystem.
As you won't have an initrd, root=UUID=... in grub.cfg will fail by design.
You must either use the block device name root=/dev/... which is not very robust because device names can change if you add or remove a device.
Using root=PARTUUID= is something the kernel understands.
PARTUUID is a property of a partition. UUID is a property of a filesystem.

e.g. here is my /dev/sde1 showing both its UUID= and PARTUUID=
Code:
$ blkid
/dev/sde1: UUID="c400b18c-0210-4338-a0fd-f437ecbaaf99" BLOCK_SIZE="1024" TYPE="ext4" PARTLABEL="ext4" PARTUUID="150e6ef1-7ba8-409c-9c3f-dbdecdc9f18b"


There is one more wart. Users with root on raid or inside LVM (or both) still need an initrd to assemble the raid and start LVM. However, it won't contain any kernel modules.

Long story short ... and dirty hack
Edit your grub.cfg to swap out root=UUID=... root=PARTUUID=<some other number> and it might just work.
This is test only. You manual edit will be reverted next time you rewrite grub.cnf but that can be fixed too.


Greetings neddy,
Thank you once again

For the first two times, I've configured and rebuilt kernel with genkernel, automatically. This in it's place has, as far as I understand, auto-creates the matching initramfs. So the issue here is that: Each time I've manually compiled the kernel, and booted the default option, I might've been using since at least October, the kernel that matches the initramfs auto-generated by genkernel in October. For, when I've been building my kernel manually, I: import my old options (make defoldconfig), configure any settings in case I need to (make menuconfig), build (make -j5 && make modules) and install (make install). Afterwards, I write to the grub.cfg, but I never generate my own initramfs.

So, I've been doing it the wrong way all this time, by not generating my initramfs for this new kernels and instead, using the Oct one.

As soon as I can, I will do the PARTUUID hack and report back

(messaged edited, sent itself too early by accident)
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 44921
Location: 56N 3W

PostPosted: Tue Feb 11, 2020 12:17 pm    Post subject: Reply with quote

tupn,

Importing your old options is fine unless they were originally set by genkernel.
That would give you a modular SCSI stack with no way of loading the modules.

What of my test at the end of my previons post?

I suspect you will get a Kernel panic ... unknown-device(0,0) error.
The numbers there are important.

That can be fixed too.
We will need your whole
Code:
lspci -knn
output and your entire kernel .config file.
The kernel .config file is far too big for a post, so it must go to a pastebin.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
tupn
n00b
n00b


Joined: 11 Sep 2019
Posts: 24

PostPosted: Tue Feb 11, 2020 12:29 pm    Post subject: Reply with quote

NeddySeagoon wrote:
tupn,

Importing your old options is fine unless they were originally set by genkernel.
That would give you a modular SCSI stack with no way of loading the modules.

What of my test at the end of my previons post?

I suspect you will get a Kernel panic ... unknown-device(0,0) error.
The numbers there are important.

That can be fixed too.
We will need your whole
Code:
lspci -knn
output and your entire kernel .config file.
The kernel .config file is far too big for a post, so it must go to a pastebin.


Greetings neddy,
Thank you once again

Right now I don't have access to desktop, when I'm back, I'll be sure to try the PARTUUID hack, and in case a kernel panic occurs at boot, I will post my lspci -knn and my kernel config file.
Back to top
View user's profile Send private message
tupn
n00b
n00b


Joined: 11 Sep 2019
Posts: 24

PostPosted: Tue Feb 11, 2020 7:29 pm    Post subject: Reply with quote

NeddySeagoon wrote:
tupn,

Importing your old options is fine unless they were originally set by genkernel.
That would give you a modular SCSI stack with no way of loading the modules.

What of my test at the end of my previons post?

I suspect you will get a Kernel panic ... unknown-device(0,0) error.
The numbers there are important.

That can be fixed too.
We will need your whole
Code:
lspci -knn
output and your entire kernel .config file.
The kernel .config file is far too big for a post, so it must go to a pastebin.


Greetings neddy,

Thank you once again
I executed the blkid command and received my partuuid for my rootfs:

Code:
 /dev/sda1: UUID="B307-CBBA" TYPE="vfat" PARTLABEL="EFI" PARTUUID="2f7b39c7-1917-44a3-892b-861e3fb491af"
/dev/sda2: UUID="f0b1a0f6-f4d2-409d-8384-f9e0ab7b1075" TYPE="ext4" PARTLABEL="boot" PARTUUID="20e956ff-dfa1-4756-b2e5-89a65cc753a9"
/dev/sda3: UUID="aa9d78b5-b5b8-413b-98fa-da8a3f8f0eb0" TYPE="swap" PARTLABEL="swap" PARTUUID="2af83d55-3eae-470a-a255-5506b9597170"
/dev/sda4: UUID="b95fec38-4c15-4ec1-95f7-a738a4a0b980" TYPE="ext4" PARTLABEL="rootfs" PARTUUID="fd1f2268-ee4a-4bb2-8b5a-f2aef292e3e3"
 


I then replaced the correspondent entry's root=UUID with root=PARTUUID={rootfs partuuid}
I rebooted and selected the 5.3.2 entry on grub, and this time the error tells me that the block device PARTUUID={rootfs partuuid} is not a valid root device.

Here is the output of my lspci -knn:

Code:
  00:00.0 Host bridge [0600]: Intel Corporation 4th Gen Core Processor DRAM Controller [8086:0c00] (rev 06)
    Subsystem: Micro-Star International Co., Ltd. [MSI] 4th Gen Core Processor DRAM Controller [1462:7815]
    Kernel driver in use: hsw_uncore
00:01.0 PCI bridge [0604]: Intel Corporation Xeon E3-1200 v3/4th Gen Core Processor PCI Express x16 Controller [8086:0c01] (rev 06)
    Kernel driver in use: pcieport
00:14.0 USB controller [0c03]: Intel Corporation 8 Series/C220 Series Chipset Family USB xHCI [8086:8c31] (rev 05)
    Subsystem: Micro-Star International Co., Ltd. [MSI] 8 Series/C220 Series Chipset Family USB xHCI [1462:7815]
    Kernel driver in use: xhci_hcd
    Kernel modules: xhci_pci
00:16.0 Communication controller [0780]: Intel Corporation 8 Series/C220 Series Chipset Family MEI Controller #1 [8086:8c3a] (rev 04)
    Subsystem: Micro-Star International Co., Ltd. [MSI] 8 Series/C220 Series Chipset Family MEI Controller [1462:7815]
00:1a.0 USB controller [0c03]: Intel Corporation 8 Series/C220 Series Chipset Family USB EHCI #2 [8086:8c2d] (rev 05)
    Subsystem: Micro-Star International Co., Ltd. [MSI] 8 Series/C220 Series Chipset Family USB EHCI [1462:7815]
    Kernel driver in use: ehci-pci
00:1b.0 Audio device [0403]: Intel Corporation 8 Series/C220 Series Chipset High Definition Audio Controller [8086:8c20] (rev 05)
    Subsystem: Micro-Star International Co., Ltd. [MSI] 8 Series/C220 Series Chipset High Definition Audio Controller [1462:d815]
    Kernel modules: snd_hda_intel
00:1c.0 PCI bridge [0604]: Intel Corporation 8 Series/C220 Series Chipset Family PCI Express Root Port #1 [8086:8c10] (rev d5)
    Kernel driver in use: pcieport
00:1c.1 PCI bridge [0604]: Intel Corporation 8 Series/C220 Series Chipset Family PCI Express Root Port #2 [8086:8c12] (rev d5)
    Kernel driver in use: pcieport
00:1c.3 PCI bridge [0604]: Intel Corporation 8 Series/C220 Series Chipset Family PCI Express Root Port #4 [8086:8c16] (rev d5)
    Kernel driver in use: pcieport
00:1c.4 PCI bridge [0604]: Intel Corporation 8 Series/C220 Series Chipset Family PCI Express Root Port #5 [8086:8c18] (rev d5)
    Kernel driver in use: pcieport
00:1d.0 USB controller [0c03]: Intel Corporation 8 Series/C220 Series Chipset Family USB EHCI #1 [8086:8c26] (rev 05)
    Subsystem: Micro-Star International Co., Ltd. [MSI] 8 Series/C220 Series Chipset Family USB EHCI [1462:7815]
    Kernel driver in use: ehci-pci
00:1f.0 ISA bridge [0601]: Intel Corporation Z87 Express LPC Controller [8086:8c44] (rev 05)
    Subsystem: Micro-Star International Co., Ltd. [MSI] Z87 Express LPC Controller [1462:7815]
    Kernel modules: lpc_ich
00:1f.2 SATA controller [0106]: Intel Corporation 8 Series/C220 Series Chipset Family 6-port SATA Controller 1 [AHCI mode] [8086:8c02] (rev 05)
    Subsystem: Micro-Star International Co., Ltd. [MSI] 8 Series/C220 Series Chipset Family 6-port SATA Controller 1 [AHCI mode] [1462:7815]
    Kernel driver in use: ahci
    Kernel modules: ahci
00:1f.3 SMBus [0c05]: Intel Corporation 8 Series/C220 Series Chipset Family SMBus Controller [8086:8c22] (rev 05)
    Subsystem: Micro-Star International Co., Ltd. [MSI] 8 Series/C220 Series Chipset Family SMBus Controller [1462:7815]
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation GM204 [GeForce GTX 980] [10de:13c0] (rev a1)
    Subsystem: eVga.com. Corp. GM204 [GeForce GTX 980] [3842:3988]
    Kernel driver in use: nvidia
    Kernel modules: nouveau, nvidia_drm, nvidia
01:00.1 Audio device [0403]: NVIDIA Corporation GM204 High Definition Audio Controller [10de:0fbb] (rev a1)
    Subsystem: eVga.com. Corp. GM204 High Definition Audio Controller [3842:3988]
    Kernel modules: snd_hda_intel
03:00.0 Ethernet controller [0200]: Qualcomm Atheros Killer E220x Gigabit Ethernet Controller [1969:e091] (rev 13)
    Subsystem: Micro-Star International Co., Ltd. [MSI] Killer E220x Gigabit Ethernet Controller [1462:7815]
    Kernel modules: alx
04:00.0 USB controller [0c03]: Renesas Technology Corp. uPD720202 USB 3.0 Host Controller [1912:0015] (rev 02)
    Subsystem: Micro-Star International Co., Ltd. [MSI] uPD720202 USB 3.0 Host Controller [1462:7815]
    Kernel driver in use: xhci_hcd
    Kernel modules: xhci_pci
05:00.0 SATA controller [0106]: ASMedia Technology Inc. ASM1062 Serial ATA Controller [1b21:0612] (rev 01)
    Subsystem: Micro-Star International Co., Ltd. [MSI] ASM1062 Serial ATA Controller [1462:7815]
    Kernel driver in use: ahci
    Kernel modules: ahci
 


And here is the output of my kernel's .config:

Code:
 https://pastebin.com/3NbkVKRm
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 44921
Location: 56N 3W

PostPosted: Tue Feb 11, 2020 8:22 pm    Post subject: Reply with quote

tupn,

Lets go through your kernel.

Code:
CONFIG_MSDOS_PARTITION=y
CONFIG_EFI_PARTITION=y
Good. That covers most things that a PC will see.

Code:
CONFIG_SCSI=y
Good. All block devices are SCSI now. No matter how they are wired.

Code:
CONFIG_BLK_DEV_SD=m
Thats the disk driver top layer. Since you don't have an initrd to load it from, it must be built in.
In menuconfig, change the <M> to <*>.

Code:
CONFIG_BLK_DEV_SR=m
CONFIG_CHR_DEV_SG=m
are for optical drives and should be built in too. It will not affect booting.

Turm off
Code:
CONFIG_SCSI_LOWLEVEL=y
its for real SCSI and you don't have any.
As its a menu item, all the options in the menu will be removed too.

Code:
CONFIG_ATA=y
Good. That's a menu and your HDD controller driver is there.
Code:
CONFIG_SATA_AHCI=m
but its a module and it must be built in.

Turn off
Code:
CONFIG_ATA_SFF=y
Its another menu for things you don't have.

I forgot to ask what your root filesystem was but they are all configured as =m
Code:
CONFIG_EXT2_FS=m
CONFIG_EXT3_FS=m
CONFIG_EXT4_FS=m
...
The one you need to mount root must be built in.

What brought you here was your ethernet driver, which is
Code:
CONFIG_ALX=m
That's OK.

It would have been in the initrd but will load after root is mounted.

I have not checked things you don't nee to mount root.

Fix your kernel configuration using menuconfig to change the <M> to <*> as I've indicated above, then rebuild and install your kernel.
If you find that <*> cannot be selected, go up the menu structue and change parent <M> to <*> too.
Eventually, you will be able to set <*> on your selected option.

On to your next Gentoo learning opportunity :)
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
dmpogo
Advocate
Advocate


Joined: 02 Sep 2004
Posts: 2650
Location: Canada

PostPosted: Tue Feb 11, 2020 8:46 pm    Post subject: Reply with quote

Code:

Code:
CONFIG_EXT2_FS=m
CONFIG_EXT3_FS=m
CONFIG_EXT4_FS=m
...


I recall that you do not need ext3 as a separate module anymore, ext4 driver does ext3 if needed.
Back to top
View user's profile Send private message
tupn
n00b
n00b


Joined: 11 Sep 2019
Posts: 24

PostPosted: Tue Feb 11, 2020 9:46 pm    Post subject: Reply with quote

NeddySeagoon wrote:
tupn,

Lets go through your kernel.

Code:
CONFIG_MSDOS_PARTITION=y
CONFIG_EFI_PARTITION=y
Good. That covers most things that a PC will see.

Code:
CONFIG_SCSI=y
Good. All block devices are SCSI now. No matter how they are wired.

Code:
CONFIG_BLK_DEV_SD=m
Thats the disk driver top layer. Since you don't have an initrd to load it from, it must be built in.
In menuconfig, change the <M> to <*>.

Code:
CONFIG_BLK_DEV_SR=m
CONFIG_CHR_DEV_SG=m
are for optical drives and should be built in too. It will not affect booting.

Turm off
Code:
CONFIG_SCSI_LOWLEVEL=y
its for real SCSI and you don't have any.
As its a menu item, all the options in the menu will be removed too.

Code:
CONFIG_ATA=y
Good. That's a menu and your HDD controller driver is there.
Code:
CONFIG_SATA_AHCI=m
but its a module and it must be built in.

Turn off
Code:
CONFIG_ATA_SFF=y
Its another menu for things you don't have.

I forgot to ask what your root filesystem was but they are all configured as =m
Code:
CONFIG_EXT2_FS=m
CONFIG_EXT3_FS=m
CONFIG_EXT4_FS=m
...
The one you need to mount root must be built in.

What brought you here was your ethernet driver, which is
Code:
CONFIG_ALX=m
That's OK.

It would have been in the initrd but will load after root is mounted.

I have not checked things you don't nee to mount root.

Fix your kernel configuration using menuconfig to change the <M> to <*> as I've indicated above, then rebuild and install your kernel.
If you find that <*> cannot be selected, go up the menu structue and change parent <M> to <*> too.
Eventually, you will be able to set <*> on your selected option.

On to your next Gentoo learning opportunity :)


Greetings neddy,
Thank you once again

Good news, I rebuilt and installed the kernel with the options you told me to include, and the root device was finally able to be located and mounted in the 5.3.2 entry (not the default). However, my enp3s0 interface is still unable to be found by the system at boot. Also I noted that when booting to the 5.3.2 entry (not the default), my USB keyboard is not detected, which means that right know, I need to include support for USB devices.
Also regarding the:
Code:
CONFIG_ALX = m

In my kernel, should I include it instead of modularizing it to see if I can regain my network interface? Or is it considered a bad practice?
Back to top
View user's profile Send private message
dmpogo
Advocate
Advocate


Joined: 02 Sep 2004
Posts: 2650
Location: Canada

PostPosted: Tue Feb 11, 2020 9:59 pm    Post subject: Reply with quote

Re practice about modules and built in drivers. I tend to built in everything which drives non-hot-pluggable hardware, and what is known not to fail. modules help if firmware hangs, and you can reinitialize it reloading the module, or if it is infrequently used and/or pluggable hardware.
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 44921
Location: 56N 3W

PostPosted: Tue Feb 11, 2020 10:19 pm    Post subject: Reply with quote

tupn,

That's progress :)

I wrote this guide a wee while ago.
You need much more coffee now, as there are many more kernel options and the detail has changed over the years but the method is still sound.

For fixed devices, that you always need, configure the code as <*>
The possible exception is devices that require firmware as the firmware must be included in the kernel too.

For things that come and go, <M> mostly works. I say mostly because there are a few things that do not auto load still.
You can either make them built in or add the module names to /etc/config.d/modules. See the comments in the file.

Lets see if we can fix your keyboard. Once that works you can try
Code:
dmesg | grep eth0
to see if its name has changed and
Code:
modprobe alx
to try to load the module by hand.
I guess you have a USB keyboard?

We need its vendor and device IDs. Please post the output of
Code:
lsusb

We can look for reasons why your USB stick isn't seen too.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
tupn
n00b
n00b


Joined: 11 Sep 2019
Posts: 24

PostPosted: Tue Feb 11, 2020 10:26 pm    Post subject: Reply with quote

Greetings,
Thank you all
Update: I built in support for my keyboard ( (XHCI_HCD) USB 3.0 ) and my keyboard works again. startx fails because of the Nvidia kernel module, which means that I should build the necessary options in my kernel to enable proper Nvidia's support
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 44921
Location: 56N 3W

PostPosted: Tue Feb 11, 2020 10:30 pm    Post subject: Reply with quote

tupn,

Well done. If you want the evil nvidia binary blob, its more about what you must leave out.
If you want nouveau, you need ta add things in.

There are wiki pages for both.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
tupn
n00b
n00b


Joined: 11 Sep 2019
Posts: 24

PostPosted: Tue Feb 11, 2020 10:38 pm    Post subject: Reply with quote

NeddySeagoon wrote:
tupn,

That's progress :)

I wrote this guide a wee while ago.
You need much more coffee now, as there are many more kernel options and the detail has changed over the years but the method is still sound.

For fixed devices, that you always need, configure the code as <*>
The possible exception is devices that require firmware as the firmware must be included in the kernel too.

For things that come and go, <M> mostly works. I say mostly because there are a few things that do not auto load still.
You can either make them built in or add the module names to /etc/config.d/modules. See the comments in the file.

Lets see if we can fix your keyboard. Once that works you can try
Code:
dmesg | grep eth0
to see if its name has changed and
Code:
modprobe alx
to try to load the module by hand.
I guess you have a USB keyboard?

We need its vendor and device IDs. Please post the output of
Code:
lsusb

We can look for reasons why your USB stick isn't seen too.


Greeting neddy,

Thank you once again

I ran
Code:
dmesg | grep eth0

And the output was empty
I then ran
Code:
modprobe alx
ERROR: could not insert 'alx': Invalid argument

And it returned an error

I will also read the Nvidia & nouveau wiki articles to see which one should I build in support for now, prior to the kernel reinstall, I had nvidia support and nouveau was disabled. Will it affect in some way if I disable Nvidia support and return to nouveau?
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware All times are GMT
Goto page 1, 2  Next
Page 1 of 2

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum