<table cellspacing="0" cellpadding="0" border="0" ><tr><td valign="top" style="font: inherit;"><font face="arial"><span style="font-size: 10pt;">Hi Andrew,</span></font><div><blockquote style="font-family: arial; font-size: 10pt; border-left-width: 2px; border-left-style: solid; border-left-color: rgb(16, 16, 255); margin-left: 5px; padding-left: 5px; "><div id="yiv589329958"><div class="yiv589329958gmail_extra"><div class="yiv589329958gmail_quote"><blockquote class="yiv589329958gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex;">
[...]<br>
(1) PX<span>E b</span>ooting Ubuntu does need to use the {linux, initrd.gz} in netboot subdirectory. I finally dug out enough Ubuntu documentation on Ubuntu Web site to confirm what we have learned from trials and errors.<br></blockquote>
<div><br></div><div>This makes sense. Perhaps the Ubuntu distro import needs to be updated to properly pull in the netboot kernel and ramdisk. </div><div><br></div><div><br></div></div></div></div></blockquote><font face="arial"><span style="font-size: 13.333333015441895px;">Indeed! This follow-up is cc-ed to James.</span></font></div><div><font face="arial"><span style="font-size: 13.333333015441895px;"><br></span></font><blockquote style="font-family: arial; font-size: 10pt; border-left-width: 2px; border-left-style: solid; border-left-color: rgb(16, 16, 255); margin-left: 5px; padding-left: 5px; "><div><div class="yiv589329958gmail_extra"><div class="yiv589329958gmail_quote"><blockquote class="yiv589329958gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex;"><br>
On the other hand, I still have a few other issues with my home lab setup (where dnsmasq acts as a proxy, not authoriative DHCP server), e.g.:<br>
<br>
(a) d-i netcfg/get_hostname string $hostname doesn't take effect. Instead, the randomly assigned device name by 2Wire 3600HGV is used<br></blockquote><div><br></div><div>Unfortunately this is how Debian preseed currently works. See here: <a rel="nofollow" target="_blank" href="http://www.debian.org/releases/squeeze/example-preseed.txt">http://www.debian.org/releases/squeeze/example-preseed.txt</a> and search for "hostname and domain names"</div><div><br></div></div></div></div></blockquote><font face="arial"><span style="font-size: 13.333333015441895px;">I know why now. With Debian, I see no way of getting around it. I can use -kopts to put a boot parameter to disable the DHCP server's network interface autoconfiguration, but in my home lab, debian-installer started prompting for IP address etc, despite the fact that I had got all these defined and getks shows such info :-( </span></font></div><div><font face="arial"><span
style="font-size: 13.333333015441895px;"><br></span></font></div><div><font face="arial"><span style="font-size: 13.333333015441895px;">So, at least for me, the best option seems to use the 'Template Files' in either profile or system, together with the use of the the preseed/late_command to overwrite what the 2Wire DHCP fed to debian-installer.</span><br><br></font><blockquote style="font-family: arial; font-size: 10pt; border-left-width: 2px; border-left-style: solid; border-left-color: rgb(16, 16, 255); margin-left: 5px; padding-left: 5px; "><div><div class="yiv589329958gmail_extra"><div class="yiv589329958gmail_quote">
<div><br></div><blockquote class="yiv589329958gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex;">
(b) I am still struggling with the use of the last two snippets in the preseed file, i.e.<br>
<div class="yiv589329958im"><br>
[...]<br> d-i preseed/late_command string chroot /target sh -c ' \</div><div class="yiv589329958im"> $SNIPPET('download_config_files_deb')</div><div class="yiv589329958im"> $SNIPPET('post_run_deb')</div><div class="yiv589329958im">
'; \</div><div class="yiv589329958im"> $SNIPPET('kickstart_done')</div>
<br>
Despite what I set for the 'Template Files' and rendered seed file from cobbler system getks, none of the files got into the installed system.<br>
<br>
I will simplfy it, do more tests after work, and see if I can find a clue...<br></blockquote><blockquote class="yiv589329958gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex;"><br></blockquote></div></div></div></blockquote><font face="arial"><span style="font-size: 13.333333015441895px;"><div><font face="arial"><span style="font-size: 13.333333015441895px;"><br></span></font></div></span></font><font face="arial, helvetica, sans-serif" style="font-size: 13.333333015441895px; ">I deleted the following in the sample.sed:</font></div><div><font face="arial, helvetica, sans-serif" style="font-size: 13.333333015441895px; "><br></font></div><div><font style="font-size: 13.333333015441895px; "><div><font face="courier, monaco, monospace, sans-serif"> 130 d-i preseed/late_command string chroot /target sh -c ' \</font></div><div><font face="courier,
monaco, monospace, sans-serif"> 131 $SNIPPET('download_config_files_deb')</font></div><div><font face="courier, monaco, monospace, sans-serif"> 132 $SNIPPET('post_run_deb')</font></div><div><font face="courier, monaco, monospace, sans-serif"> 133 '; \</font></div><div><font face="courier, monaco, monospace, sans-serif"> 134 $SNIPPET('kickstart_done')</font></div><div style="font-family: arial, helvetica, sans-serif; "><br></div></font></div><div><span style="font-size: 13.333333015441895px; font-family: arial, helvetica, sans-serif; ">and replaced them with the following: </span></div><div><font face="arial"><span style="font-size: 13.333333015441895px;"><br></span></font></div><div><span style="font-size: 13.333333015441895px; "><font face="courier, monaco, monospace, sans-serif">d-i preseed/late_command string wget
http://192.168.1.3/cblr/svc/op/template/system/nb1/path/_etc_hosts.new -O /target/etc/hosts;...</font></span></div><div><span style="font-size: 13.333333015441895px; "><font face="courier, monaco, monospace, sans-serif"><br></font></span></div><div><span style="font-size: 13.333333015441895px; "><font face="arial, helvetica, sans-serif">and it worked! </font></span></div><div><span style="font-size: 13.333333015441895px; "><font face="arial, helvetica, sans-serif"><br></font></span></div><div><span style="font-size: 13.333333015441895px; "><font face="arial, helvetica, sans-serif">Many thanks for your hints below. They are really useful! It would have taken me much longer to discover such info from Debian's manual set! </font></span></div><div><span style="font-size: 13.333333015441895px; "><font face="arial, helvetica, sans-serif"><br></font></span></div><div><span style="font-size: 13.333333015441895px; "><font face="arial, helvetica,
sans-serif">I also found that in the bundled </font><font face="courier, monaco, monospace, sans-serif">sample.seed</font><font face="arial, helvetica, sans-serif">, the following are potentially confusing to preseed newbies like me:</font></span></div><div><font face="arial, helvetica, sans-serif"><span style="font-size: 13.333333015441895px;"><br></span></font></div><div><span style="font-size: 13.333333015441895px; "><div><font face="courier, monaco, monospace, sans-serif"> 115 # This first command is run as early as possible, just after preseeding is read.</font></div><div><font face="courier, monaco, monospace, sans-serif"> 116 # d-i preseed/early_command string [command]</font></div><div><font face="courier, monaco, monospace, sans-serif"> 117 d-i preseed/early_command string \</font></div><div><font face="courier, monaco, monospace, sans-serif"> 118
$SNIPPET('kickstart_start')</font></div><div><font face="courier, monaco, monospace, sans-serif"> 119 # This command is run immediately before the partitioner starts. It may be</font></div><div><font face="courier, monaco, monospace, sans-serif"> 120 # useful to apply dynamic partitioner preseeding that depends on the state</font></div><div><font face="courier, monaco, monospace, sans-serif"> 121 # of the disks (which may not be visible when preseed/early_command runs).</font></div><div><font face="courier, monaco, monospace, sans-serif"> 122 # d-i partman/early_command \</font></div><div><font face="courier, monaco, monospace, sans-serif"> 123 # string debconf-set partman-auto/disk "\$(list-devices disk | head -n1)"</font></div><div><span style="font-family: courier, monaco, monospace, sans-serif; "><br></span></div><div><font
face="arial, helvetica, sans-serif">IMHO, they should be placed before these:</font></div><div><font face="courier, monaco, monospace, sans-serif"><br></font></div><div><font face="courier, monaco, monospace, sans-serif"><div> 43 # Disk Partitioning</div><div> 44 # Use LVM, and wipe out anything that already exists</div><div> 45 d-i partman-auto/method string lvm</div><div> 46 d-i partman-lvm/device_remove_lvm boolean true</div><div> 47 d-i partman-md/device_remove_md boolean true</div><div> 48 d-i partman-lvm/confirm boolean true</div><div> 49 </div><div> 50 # You can choose one of the three predefined partitioning recipes:</div><div> 51 # - atomic: all files in one partition</div><div> 52 # - home: separate /home partition</div><div> 53 #
- multi: separate /home, /usr, /var, and /tmp partitions</div><div> 54 d-i partman-auto/choose_recipe select atomic</div><div> 55 </div><div> 56 # This makes partman automatically partition without confirmation, provided</div><div> 57 # that you told it what to do using one of the methods above.</div><div> 58 d-i partman-partitioning/confirm_write_new_label boolean true</div><div> 59 d-i partman/choose_partition select finish</div><div> 60 d-i partman/confirm boolean true</div><div> 61 d-i partman/confirm_nooverwrite boolean true</div><div> 62 </div><div> 63 # If you just want to change the default filesystem from ext3 to something</div><div> 64 # else, you can do that without providing a full recipe.</div><div> 65 # d-i
partman/default_filesystem string ext4</div></font></div></span></div><div><blockquote style="font-size: 10pt; border-left-width: 2px; border-left-style: solid; border-left-color: rgb(16, 16, 255); margin-left: 5px; padding-left: 5px; "><div class="yiv589329958gmail_extra"><div class="yiv589329958gmail_quote"><div style="font-family: arial; ">Try substituting the 'chroot /target' with 'in-target'. Also make sure that there isn't a line break between the snippets or else they will be interpreted as a new line. Some times it also helps to download a script and place it in /target/tmp and then run in-target bash /tmp/<script.sh> so then you don't need to worry about newlines. Also, all of your SNIPPET entries should either be on a single line or have their newline characters escaped prior to templateing. For example</div>
<div style="font-family: arial; "><br></div><div style="font-family: arial; "><div class="yiv589329958im"> d-i preseed/late_command string chroot /target sh -c ' \</div><div class="yiv589329958im"> $SNIPPET('download_config_files_deb') \</div><div class="yiv589329958im"> $SNIPPET('post_run_deb') \</div>
<div class="yiv589329958im"> '; \</div><div class="yiv589329958im"> $SNIPPET('kickstart_done')</div></div><div style="font-family: arial; "><br></div><div style="font-family: arial; ">If you have access to the system while it is installing you can press Alt-F2 and get a shell or Alt-F4 to get the logging console. With the shell you can go to /var/log and look at the preseed file to see how it renders on the system. It is also useful to sometimes "break" the preseed so that the installation hangs at a certain point and run your snippets by hand to see if you receive any errors.</div>
<div style="font-family: arial; "><br></div><div style="font-family: arial; ">Regards,</div><div style="font-family: arial; "><br></div><div style="font-family: arial; ">Andrew</div></div></div></blockquote><font face="arial"><span style="font-size: 13.333333015441895px;">Best Regards,</span></font></div><div><font face="arial"><span style="font-size: 13.333333015441895px;"><br></span></font></div><div><font face="arial"><span style="font-size: 13.333333015441895px;">-- Zack</span></font></div></td></tr></table>