[opensuse] LEap with root on nfs share
Hello, anybody got sorted out how to start a Leap system with the root filesystem on a nfs share? How did you bild the initrd? Regards Daniel -- Daniel Spannbauer Systemadministration marco Systemanalyse und Entwicklung GmbH Tel +49 8333 9233-27 Fax -11 Rechbergstr. 4-6, D 87727 Babenhausen Mobil +49 171 4033220 http://www.marco.de/ Email ds@marco.de Geschäftsführer Martin Reuter HRB 171775 Amtsgericht München -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse+owner@opensuse.org
Daniel Spannbauer wrote:
Hello,
anybody got sorted out how to start a Leap system with the root filesystem on a nfs share?
Yep, I have plenty of those. Works very well.
How did you bild the initrd?
AFAIR, the one that is built during installation does not work. To build a working initrd: a) boot installer over pxe, install onto nfs. b) boot installer over pxe, ssh shell. c) mount nfs on /mnt d) bind mount /proc /dev und /sys e) chroot into /mnt f) mkinitrd. -- Per Jessen, Zürich (6.4°C) http://www.dns24.ch/ - your free DNS host, made in Switzerland. -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse+owner@opensuse.org
Per Jessen wrote:
Daniel Spannbauer wrote:
Hello,
anybody got sorted out how to start a Leap system with the root filesystem on a nfs share?
Yep, I have plenty of those. Works very well.
I'm just doing another install now, Tumbleweed - I'll take notes, but I'm pretty certain my earlier description is good. -- Per Jessen, Zürich (8.0°C) http://www.dns24.ch/ - free dynamic DNS, made in Switzerland. -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse+owner@opensuse.org
Per Jessen wrote:
AFAIR, the one that is built during installation does not work. To build a working initrd:
a) boot installer over pxe, install onto nfs. b) boot installer over pxe, ssh shell. c) mount nfs on /mnt d) bind mount /proc /dev und /sys e) chroot into /mnt
e1) rm /etc/resolv.conf e2) edit /etc/resolv.conf (nameserver, search) This is to make sure names on the command line can be properly resolved. My nfs root server is called 'rootserver.example.com'. -- Per Jessen, Zürich (13.0°C) http://www.hostsuisse.com/ - virtual servers, made in Switzerland. -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse+owner@opensuse.org
Am 3/1/20 um 2:58 PM schrieb Per Jessen:
Per Jessen wrote:
AFAIR, the one that is built during installation does not work. To build a working initrd:
a) boot installer over pxe, install onto nfs. b) boot installer over pxe, ssh shell. c) mount nfs on /mnt d) bind mount /proc /dev und /sys e) chroot into /mnt e1) rm /etc/resolv.conf e2) edit /etc/resolv.conf (nameserver, search)
This is to make sure names on the command line can be properly resolved. My nfs root server is called 'rootserver.example.com'.
Should be done by the dehclient I think. But anyway: tried it with the beta of 15.2...got also errors at creating the initrd. Regards Daniel -- Daniel Spannbauer Systemadministration marco Systemanalyse und Entwicklung GmbH Tel +49 8333 9233-27 Fax -11 Rechbergstr. 4-6, D 87727 Babenhausen Mobil +49 171 4033220 http://www.marco.de/ Email ds@marco.de Geschäftsführer Martin Reuter HRB 171775 Amtsgericht München -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse+owner@opensuse.org
Daniel Spannbauer wrote:
Am 3/1/20 um 2:58 PM schrieb Per Jessen:
Per Jessen wrote:
AFAIR, the one that is built during installation does not work. To build a working initrd:
a) boot installer over pxe, install onto nfs. b) boot installer over pxe, ssh shell. c) mount nfs on /mnt d) bind mount /proc /dev und /sys e) chroot into /mnt e1) rm /etc/resolv.conf e2) edit /etc/resolv.conf (nameserver, search)
This is to make sure names on the command line can be properly resolved. My nfs root server is called 'rootserver.example.com'.
Should be done by the dehclient I think.
Yes, but not when you have chrooted.
But anyway: tried it with the beta of 15.2...got also errors at creating the initrd.
Haha, I did the same yesterday, tried with 15.2. I did wonder if I should write to tell you. After I re-built the initrd, I put a serial console on, but all I got was: [ 139.843403] dracut-initqueue[456]: mount.nfs: Resource temporarily unavailable [ 268.612177] dracut-initqueue[456]: Warning: dracut-initqueue timeout - starting timeout scripts [ 269.188159] dracut-initqueue[456]: Warning: dracut-initqueue timeout - starting timeout scripts [ 269.744169] dracut-initqueue[456]: Warning: dracut-initqueue timeout - starting timeout scripts I'm going to try with 15.1 today - I have working systems with both 15.0 and 15.1. -- Per Jessen, Zürich (6.5°C) http://www.hostsuisse.com/ - dedicated server rental in Switzerland. -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse+owner@opensuse.org
Am 3/2/20 um 9:56 AM schrieb Per Jessen:
Daniel Spannbauer wrote:
Am 3/1/20 um 2:58 PM schrieb Per Jessen:
Per Jessen wrote:
AFAIR, the one that is built during installation does not work. To build a working initrd:
a) boot installer over pxe, install onto nfs. b) boot installer over pxe, ssh shell. c) mount nfs on /mnt d) bind mount /proc /dev und /sys e) chroot into /mnt e1) rm /etc/resolv.conf e2) edit /etc/resolv.conf (nameserver, search)
This is to make sure names on the command line can be properly resolved. My nfs root server is called 'rootserver.example.com'. Should be done by the dehclient I think. Yes, but not when you have chrooted.
Jup, you are right. Even with mounted /var.....
But anyway: tried it with the beta of 15.2...got also errors at creating the initrd. Haha, I did the same yesterday, tried with 15.2. I did wonder if I should write to tell you.
After I re-built the initrd, I put a serial console on, but all I got was:
[ 139.843403] dracut-initqueue[456]: mount.nfs: Resource temporarily unavailable [ 268.612177] dracut-initqueue[456]: Warning: dracut-initqueue timeout - starting timeout scripts [ 269.188159] dracut-initqueue[456]: Warning: dracut-initqueue timeout - starting timeout scripts [ 269.744169] dracut-initqueue[456]: Warning: dracut-initqueue timeout - starting timeout scripts
I'm going to try with 15.1 today - I have working systems with both 15.0 and 15.1.
My errors where caused by a missing name resolution (/etc/resolv.conf) and a missing paket dhcp-client. No, it builds without errors. But when I boot via pxe it starts directly into systemd emergency mode, bit I can't do any input on the system. What a mess..... Regards Daniel -- Daniel Spannbauer Systemadministration marco Systemanalyse und Entwicklung GmbH Tel +49 8333 9233-27 Fax -11 Rechbergstr. 4-6, D 87727 Babenhausen Mobil +49 171 4033220 http://www.marco.de/ Email ds@marco.de Geschäftsführer Martin Reuter HRB 171775 Amtsgericht München -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse+owner@opensuse.org
Daniel Spannbauer wrote:
My errors where caused by a missing name resolution (/etc/resolv.conf) and a missing paket dhcp-client. No, it builds without errors.
Hmm, there should be no need for dhclient, we have wicked.
But when I boot via pxe it starts directly into systemd emergency mode, bit I can't do any input on the system.
Yes, that is more or less I have in 15.2 right now. I've now installed dhp-client, and I'll try it again.
What a mess.....
It seems dracut is to blame for 15.2 and Tumbleweed, but it actually works very well - once you get it working :-) -- Per Jessen, Zürich (7.1°C) http://www.dns24.ch/ - your free DNS host, made in Switzerland. -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse+owner@opensuse.org
Per Jessen wrote:
Daniel Spannbauer wrote:
My errors where caused by a missing name resolution (/etc/resolv.conf) and a missing paket dhcp-client. No, it builds without errors.
Hmm, there should be no need for dhclient, we have wicked.
But when I boot via pxe it starts directly into systemd emergency mode, bit I can't do any input on the system.
Yes, that is more or less I have in 15.2 right now. I've now installed dhp-client, and I'll try it again.
What a mess.....
It seems dracut is to blame for 15.2 and Tumbleweed, but it actually works very well - once you get it working :-)
If anyone is listening - the problem is in the /etc/resolv.conf before the NFS root can be mounted. There is no "nameserver x.x.x.x" directive. This file is built by the dracut scripts based on DHCP information, but somehow "nameserver" was omitted. -- Per Jessen, Zürich (7.1°C) http://www.dns24.ch/ - free dynamic DNS, made in Switzerland. -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse+owner@opensuse.org
Per Jessen wrote:
If anyone is listening - the problem is in the /etc/resolv.conf before the NFS root can be mounted. There is no "nameserver x.x.x.x" directive. This file is built by the dracut scripts based on DHCP information, but somehow "nameserver" was omitted.
I think there is a logical failure in /usr/lib/dracut/modules.d/35network-legacy/ifup.sh function 'dhcp_wicked_apply', line 75. It creates a temp resolv.conf, then if /etc/resolv.conf does not exist, the temp is copied over, otherwise /etc/resolv.conf is edited. A "nameserver x.x.x.x" is only added when the file is edited, not when it is copied. bug#1165547 -- Per Jessen, Zürich (6.8°C) -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse+owner@opensuse.org
On Tuesday, 3 March 2020 21:57:53 ACDT Per Jessen wrote:
Per Jessen wrote: [...]
If anyone is listening - the problem is in the /etc/resolv.conf before the NFS root can be mounted. There is no "nameserver x.x.x.x" directive. This file is built by the dracut scripts based on DHCP information, but somehow "nameserver" was omitted.
Is the DHCP server correctly providing the dns server address(es) as part of the DHCP offer? -- ============================================================== Rodney Baker VK5ZTV rodney.baker@iinet.net.au CCNA #CSCO12880208 ============================================================== -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse+owner@opensuse.org
Rodney Baker wrote:
On Tuesday, 3 March 2020 21:57:53 ACDT Per Jessen wrote:
Per Jessen wrote: [...]
If anyone is listening - the problem is in the /etc/resolv.conf before the NFS root can be mounted. There is no "nameserver x.x.x.x" directive. This file is built by the dracut scripts based on DHCP information, but somehow "nameserver" was omitted.
Is the DHCP server correctly providing the dns server address(es) as part of the DHCP offer?
Yep, all the options are present. I have fixed the script and added a patch to the bugreport. -- Per Jessen, Zürich (7.9°C) http://www.dns24.ch/ - your free DNS host, made in Switzerland. -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse+owner@opensuse.org
On 03/03/2020 12.27, Per Jessen wrote:
Per Jessen wrote:
It seems dracut is to blame for 15.2 and Tumbleweed, but it actually works very well - once you get it working :-)
If anyone is listening - the problem is in the /etc/resolv.conf before the NFS root can be mounted. There is no "nameserver x.x.x.x" directive. This file is built by the dracut scripts based on DHCP information, but somehow "nameserver" was omitted.
But the dhcp protocol usually also tells what nameserver to use, dynamically. -- Cheers / Saludos, Carlos E. R. (from oS Leap 15.0 x86_64 (Minas Tirith))
Carlos E. R. wrote:
On 03/03/2020 12.27, Per Jessen wrote:
Per Jessen wrote:
It seems dracut is to blame for 15.2 and Tumbleweed, but it actually works very well - once you get it working :-)
If anyone is listening - the problem is in the /etc/resolv.conf before the NFS root can be mounted. There is no "nameserver x.x.x.x" directive. This file is built by the dracut scripts based on DHCP information, but somehow "nameserver" was omitted.
But the dhcp protocol usually also tells what nameserver to use, dynamically.
Correct, but that information has to be put into /etc/resolv.conf to be of any use :-) -- Per Jessen, Zürich (7.8°C) http://www.hostsuisse.com/ - virtual servers, made in Switzerland. -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse+owner@opensuse.org
On 03/03/2020 15.03, Per Jessen wrote:
Carlos E. R. wrote:
On 03/03/2020 12.27, Per Jessen wrote:
Per Jessen wrote:
It seems dracut is to blame for 15.2 and Tumbleweed, but it actually works very well - once you get it working :-)
If anyone is listening - the problem is in the /etc/resolv.conf before the NFS root can be mounted. There is no "nameserver x.x.x.x" directive. This file is built by the dracut scripts based on DHCP information, but somehow "nameserver" was omitted.
But the dhcp protocol usually also tells what nameserver to use, dynamically.
Correct, but that information has to be put into /etc/resolv.conf to be of any use :-)
By some automated process, I suppose. Possibly on a tmpfs, so /run/somewhere - I assume that the root is not writeable? -- Cheers / Saludos, Carlos E. R. (from oS Leap 15.0 x86_64 (Minas Tirith))
Carlos E. R. wrote:
On 03/03/2020 15.03, Per Jessen wrote:
Carlos E. R. wrote:
On 03/03/2020 12.27, Per Jessen wrote:
Per Jessen wrote:
It seems dracut is to blame for 15.2 and Tumbleweed, but it actually works very well - once you get it working :-)
If anyone is listening - the problem is in the /etc/resolv.conf before the NFS root can be mounted. There is no "nameserver x.x.x.x" directive. This file is built by the dracut scripts based on DHCP information, but somehow "nameserver" was omitted.
But the dhcp protocol usually also tells what nameserver to use, dynamically.
Correct, but that information has to be put into /etc/resolv.conf to be of any use :-)
By some automated process, I suppose.
By a dracut script. 35network-legacy/ifup.sh
Possibly on a tmpfs, so /run/somewhere - I assume that the root is not writeable?
Yes, root is not yet mounted. The initrd has just been unpacked and is now being initialised so root can be mounted. -- Per Jessen, Zürich (7.9°C) http://www.cloudsuisse.com/ - your owncloud, hosted in Switzerland. -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse+owner@opensuse.org
If anyone is listening - the problem is in the /etc/resolv.conf before the NFS root can be mounted. There is no "nameserver x.x.x.x" directive. This file is built by the dracut scripts based on DHCP information, but somehow "nameserver" was omitted.
Have you configured your nfsroot correctly? see https://www.kernel.org/doc/Documentation/filesystems/nfs/nfsroot.txt for diskless nfs config -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse+owner@opensuse.org
participants (5)
-
Carlos E. R.
-
Daniel Spannbauer
-
Per Jessen
-
PGNet Dev
-
Rodney Baker