Re: PXE-booting rescue mode

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Aug 17, 2009 at 9:12 AM, Anders
Blomdell<anders.blomdell@xxxxxxxxxxxxxx> wrote:
> Hi,
>
> In previous versions of Fedora (i.e. Fedora-9), it was possible to do a PXE-boot
> of a rescue image, by supplying a ks.cfg that looked something like:
>
>  lang en_US
>  keyboard sv-latin1
>
>  firewall --disabled
>  selinux --disabled
>
>  text
>
>  network --bootproto dhcp
>  nfs --server=<hostaddr> --dir=<dist>/Fedora-9
>
> which was very handy for partitioning disks, etc, with Fedora-10 this stopped
> working due to the following code at the end of rescue.py
>
>    if anaconda.isKickstart:
>        from kickstart import runPostScripts
>        runPostScripts(anaconda)
>    else:
>        runShell(screen, msgStr)
>
> and with Fedora-11 there is even more weirdness:
>
>        if anaconda.isKickstart:
>            log.info("No Linux partitions found")
>            screen.finish()
>            print(_("You don't have any Linux partitions.  Rebooting.\n"))
>            sys.exit(0)
>
> Is there any supported way to PXE-boot a rescue image for Fedora-11? At the
> moment I have put a slightly modified rescue.py in RHupdates (I know, it's a
> terrible hack...):
>
> --- /tmp/rescue.py      2009-06-02 21:11:19.000000000 +0200
> +++ rescue.py   2009-08-17 18:10:20.000000000 +0200
> @@ -193,6 +193,9 @@
>         screen.finish()
>
>  def runRescue(anaconda, instClass):
> +    if anaconda.id.ksdata.interactive.interactive:
> +        log.info("Fall back to interactive rescue mode (useful for PXE)")
> +        anaconda.isKickstart = False
>     for file in [ "services", "protocols", "group", "joe", "man.config",
>                   "nsswitch.conf", "selinux", "mke2fs.conf" ]:
>         try:
>
>
> /Anders
>

I did a simple variant that had this in the pxe/syslinux menu and
passed it as a kernel cmdline option like this:

label 3
  kernel vmlinuz
  IPAPPEND 2
  append initrd=initrd.img ramdisk_size=32705 ksdevice=bootif rescue
noipv6 dns=10.109.3.240 method=http://10.109.0.46/repo/DVD

_______________________________________________
Kickstart-list mailing list
Kickstart-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/kickstart-list

[Index of Archives]     [Red Hat General]     [CentOS Users]     [Fedora Users]     [Fedora Maintainers]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]

  Powered by Linux