=== kostkon_ is now known as kostkon === kostkon_ is now known as kostkon === hsmiths1 is now known as hsmiths === haggertk_ is now known as haggertk === Kamilion|ZNC is now known as Kamilion [12:07] Hi [12:09] I'm trying to build a booting/install system using ipxe. I'm trying to autoinstall ubuntu 22.04, but the problem I find is that I need to have at least 4gb or ram in that client machine in order it to be able to keep moving. Is there a way to load just a very small iso, or something like maybe an nfs server where to place just a bunch of files, and not all the big ISO? [12:17] no problem!: Thanks. I did it using nfs server... I needed to add a nfsroot parameter to kernel [12:45] what is the best log file you should try to find in order to figure out why autoinstaller/cloud-init are not reading (or failing) an attemp of autoinstall using ubuntu22.04? [12:46] I think my user-data is wqrong, but I don't kno what part, so a log file would be very helpful [13:28] OutOfService: /var/log/installer/subiquity-server-debug.log will be verbose but should have the information. If you like, pastebin it and I'll help look. [13:32] thanks a lot dbungert [13:33] I'll come back if needed [13:40] well, it seems Im gonna need some help. Do you need me to paste all the file, dbungert? [13:40] this is the parameters that I send to kernel: [13:40] ds='nocloud-net;s=http://ipxe.casa.lan/ipxe/configs/test3/' autoinstall [13:41] inside test3 I have three files. two empty meta-data and vendor-data, and a user-data taht seems not to be loaded in autoconfig/cloud-init [13:43] this is the subiquity-server-debug.log [13:43] https://pastebin.com/XSzEm7L3 [13:43] Seems that subiquito wants to go to the path in kernel parameters, but then... nothing else I can find util [13:44] OutOfService: That log says there is no autoinstall data. cloud-init may not have seen the config. I suspect ipxe quoting problems on the kernel command line. [13:45] i think the same. I'm having a look at this moment [13:45] I can load the user-data file in the browser [13:45] so.. should be kernel line [13:45] imgargs vmlinuz modprobe.backlist=megaraid_sas initrd=initrd netboot=nfs ip=dhcp nfsroot=10.0.0.13:${root_path}/images/${os_root}/ ds='nocloud-net;s=http://ipxe.casa.lan/ipxe/configs/test3/' autoinstall [13:46] does ipxe.casa.lan actually resolve under IPXE ? did yu try using the IP ? [13:46] where "os_root" is "ubuntu-22.04.2" and "rooth_path" is "/var/tftp/ipxe" [13:46] OutOfService: on the ephemeral install environment try `sudo cloud-init query userdaya` I expect it's empty. I'm guessing the `cat /proc/cmdline` doesn't actually contain the full set of kernel params ou expected to provide to the machine due to quoting issues? [13:46] `sudo cloud-init query userdata` rather [13:46] im using a vitual host, as i need the webserver to server another web site. But using the browser using the pxe.casa.lan... works good [13:47] ipxe needs to works fine and gets the ipxe file [13:48] blackboxsw I will. just one minute please :) [13:48] no worries OutOfService. nevermind on my commend about /proc/cmdline as you pasted debug.log above already had the related Kernel cmdline without 'autoinstall' parameter listed in that log line [13:48] blackboxsw this is the line from cmdline: "vmlinuz modprobe.backlist=megaraid_sas initrd=initrd netboot=nfs ip=dhcp nfsroot=10.0.0.13:/var/tftp/ipxe/images/ubuntu-22.04.2/ ds='nocloud-net;s=http://ipxe.casa.lan/ipxe/configs/test3/' autoinstall [13:48] " [13:50] https://imgur.com/a/G0DTsXg [13:50] I see that now :/. . so hrm. if you get a chance the values of `/run/cloud-init/ds-identify.log` may help tell what cloud-init thought it saw [13:50] OutOfService: +1 on your directory contents for the remote URL [13:51] https://imgur.com/a/G0DTsXg -> link updated [13:53] and this is from sudo cloud-init query metadata... [13:53] root@ubuntu-server:~# sudo cloud-init query userdata [13:53] root@ubuntu-server:~# [13:53] empty [13:54] the content from user-data: [13:54] #cloud-config [13:54] autoinstall: [13:54] version: 1 [13:54] identity: [13:54] hostname: hostname [13:54] username: username [13:54] locale: es_ES [13:54] smwall, but I think it should be working [13:55] the other two files are empty [13:55] OutOfService: I assume there is also a `password` under identity, just redacted here? The autoinstall itself looks fine if so. [13:56] badly assumed :) [13:56] could that be my bigg mistake? [13:56] I forgot to create de variable [13:57] sorry, the paremeter for the password [13:57] OutOfService: in your log above subiquity didn't see the autoinstall yet, so this would be a problem later [13:57] OutOfService: hrm ok not sure if the leading quote you have after ds='nocloud-net;s=http://blah/' is the problem [13:58] generally when I've quoted the ds=xxx string I use `ds=nocloud-net;s=http://blah/' [13:58] we can double check with a pastebin of /var/log/cloud-init.log. But I'm guessing that quoting is the problem [13:58] ok. I'll give it a try [14:00] cloud-init.log: [14:00] https://pastebin.com/yJEBgq3P [14:00] otherwise my guess is a network issue during boot where cloud-init retries the URL you provided and can't route to it for some reason... the cloud-init.log will tell us though [14:01] ok, I'll reboot now again in order to chek the parameters with no quotes [14:01] OutOfService: cloud-init is using nocloud data from /var/lib/cloud/seed/nocloud instead of the URL you provided. 2023-07-06 13:05:25,780 - stages.py[INFO]: Loaded datasource DataSourceNoCloud - DataSourceNoCloud [seed=/var/lib/cloud/seed/nocloud][dsmode=net] [14:01] I also think it is related [14:02] ok I'll dig through cloud-init.log to see why it isn't seeing the URL [14:05] dbungert, ogra, blackboxsw.. you were right with the quotes. Now it seems to be working as expetcted :) I can't emember where I got that idea to quote that line. I think it was an advice from someone using grub instead ipxe [14:05] https://imgur.com/a/G0DTsXg [14:05] thanks a lot, as always :) [14:06] hah, great ! [14:06] now I'll hace to fight with user-data contents... [14:07] are https://ubuntu.com/server/docs/install/autoinstall-reference all the options I can use in user-data? [14:07] I'd love to find something more.. specific [14:08] I found multiple examples for it to make it work, but in different ways. Now I cannot remember the differentes I found, but there were more than one. Small ones, but there were... [14:09] So I'd love to find all the possible options, and play a little bit with them [14:09] OutOfService: woot! ❤️ to start the day with a debugging success for us :) [14:10] you mean you want me to read? I can't undertand these symbols :( [14:10] OutOfService: autoinstall-reference has everything you can do under the `autoinstall` segment. If you want to use further cloud-init configuration for the target system, you can nest additional cloud-config like so: https://discourse.ubuntu.com/t/automated-server-installation/16612/59?u=dbungert [14:11] I'll start over there. Thanks so much!! [14:11] Welcome! Good luck! [14:13] wow!! what a goog starting point!! that post about which line is for.. is like a bright light for me. I didn't understand why mixing all the options never worked xD [14:13] why didn't i found that onm ubuntu documnetation? I spent hours and hours reading and loking for good doc [14:55] I'm talking with #ipxe guys, and the say kernel doesn't support resolving dns names. Is that true? I'd like to pass somw adrdesses to my kernel, but now it seems that I can only use ips instead [15:04] Name resolution is indeed something happening in userspace. [15:07] thanks for your help people [15:08] there si a vaue for the kernel cmdline https://www.kernel.org/doc/Documentation/filesystems/nfs/nfsroot.txt ... [15:08] *there is a [15:08] not sure if userspace picks that up tough [15:11] ogra: I wonder if that might be something like https://docs.kernel.org/networking/dns_resolver.html, where the kernel calls out to userspace? [15:13] could be ... i know the old initramfs-tools scripts we used to have were parsing the nfstroot= cmdline option from a script and feeding bits into userspace apps ... but things have changed since i touched the initrd last [15:15] so, you think I should try using dns0-ip=what_should_i_put_here? [15:18] i think it goes into the ip=... option appended with a colon [15:19] you mean something like ip=.my.dns.dame ? [15:19] the syntax for a non dhcp boot would be something like: ip=:::::::: [15:20] now you need to figure out how that works with dhcp 🙂 [15:20] perhaps just ip=dhcp:8.8.8.8 ... or some such ... not sure [15:21] I am using landscape-api snap with the create-script-attachment method, but the syntax for the file parameter is completely unclear, it is both the name of the attachment and its contents, the docs only state the http calls not snap or python. [15:22] https://dpaste.com/DWR7LBXXL [15:52] Finally I've written an email to the dev of nfsroot... I hope he has time and patiente to reply to me [16:55] OutOfService: what's the question, how to specify a dns server for initramfs-tools while getting the rest information from dhcp? [17:31] alkisg: he wants to specify "nfsroot=" using a DNS name rather than IP address [17:32] That's mounted using klibc's nfsmount, which doesn't support DNS [17:48] yeah that's what he was told [17:49] though someone else referred to initramfs doing the NFS mount [17:53] Yes, initramfs-tools parses nfsroot= and calls klibc nfsmount to do the mount