Debian network cannot find eth after rebooting with new kernel
hi friends, I'm a newbee on kernel so I was trying to compile a new kernel.
I was doing that on a bandwagonhost vps and the compiling went well. then I just update-grub and the new kernel was shown on grub after rebooting. There was no panic and I accessed with the new kernel. The tricky thing was that, after going into with the new kernel, I noticed the VM cannot be accessed via ssh. I checked the sshd service was good and the ssh port was open. During that time, I checked ifconfig -a and found the eth. I thought it was the new kernel thing, so I switched back to the old kernel. Then everything went wrong... I cannot find eth via ifconfig -a and the network was not working...... I googled it, but still not working... So I'm here asking for advice&guidance, pls help. |
Try to have a look at the messages logged when the new kernel was booting up.
as root run this command: dmesg | more |
Do you know what type of VM your host is using? That might narrow down the module it uses for the network so you could try manually loading it with the modprobe command.
|
1 Attachment(s)
Quote:
Attachment 40007 Code:
[root /]# dmesg | grep eth |
Quote:
Code:
[root /]# dmesg | grep -I eth |
actually 5.10.0-8-amd64 was my old kernel, I updated it to 6.1.0. but cannot modprobe eth0 on both of them, all with Module eth0 not found in /lib/modules
Code:
[root /]# modprobe eth0 |
From your dmesg output, your system renamed eth0 to ens18 and eth1 to ens19. So the system is loading the modules for networking.
If you boot into the old kernel does the eth interfaces get renamed? Or yo can check in the ssh config and see if it is looking for a differently named network interface. |
Quote:
changed eth in /etc/network/interfaces to ens, then restarted the network.service and it's all good now. thanks again. may I ask why it was renamed to ens? the old kernel also renames it, did I do anything wrong on grub config. should not relate to the kernel compiling config right? |
All times are GMT -5. The time now is 11:07 AM. |