<div class="gmail_quote">On Fri, Aug 27, 2010 at 12:09 PM, Lance Gropper <span dir="ltr"><<a href="mailto:streamscalelance@gmail.com" target="_blank">streamscalelance@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">

Hello Dan:<div><br></div><div>My script already figures out the device - the problem is using that device in the harddrive statement, by putting the harddrive statement in the %pre isn't working...</div><div><br></div>



<div>Lance<br></div></blockquote><div><br></div></div>We use the same temporary file mechanism that you do, where the kickstart file includes a temporary file written by %pre, but we don't use the harddrive command <br>
to tell anaconda where to find the media.  I guess that anaconda resolves where to get too early for the temporary file mechanism to work.<br><br>What I was saying before should work ... but more detail is needed.  We modify the ks= command to make it dynamically depend on the name of the USB volume.<br>

<br>When we build our DVD, we have an isolinux.cfg that includes:<br>    kernel vmlinuz<br>    append selinux=0 initrd=initrd.img ks=cdrom:/upgrade.cfg <br><br>Once we have the ISO, we make our USB disk bootable with parted, and then build a labeled vfat partition:<br>
    mkfs.vfat -n MINE /dev/sde1<br><br>After we've transferred the ISO onto a USB with livecd-iso-to-disk, we modify syslinux.cfg to change the ks= line:<br>
    kernel vmlinuz<br>    append initrd=initrd.img repo=hd:UUID=6D6C-9D8A:/ ks=hd:LABEL=MINE:/upgrade.cfg <br><br>We never have to tell anaconda where to find the media.<br><br>I hadn't noticed the UUID in there before, it must be exactly what is suggested by Bryan.  I suspect that using the UUID= would work just as well as the LABEL=,<br>
and vice versa.<br>
<br>Hopefully, this helps, but I inherited this build from someone else ... I just got the USB install to work yesterday.<br><br>