Re: [PATCH 4/5] Prevent low-level formatting of DASDs in rescue mode (#582638)

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

 



On 04/16/2010 05:16 PM, Hans de Goede wrote:
> Note I'm not completely happy with how this looks, I wonder if it wouldn't
> be better to make questionInitializeDASD simply return True or False and
> always allow installs to continue with unformatted DASD's if the user
> chooses so.

Yeah, this is currently under discussion.
Independent of this your patch looks good, so ack.

> ---
>  rescue.py       |    4 ++++
>  storage/dasd.py |    4 ++++
>  2 files changed, 8 insertions(+), 0 deletions(-)
> 
> diff --git a/rescue.py b/rescue.py
> index 269b9b3..8f6c956 100644
> --- a/rescue.py
> +++ b/rescue.py
> @@ -118,6 +118,10 @@ class RescueInterface(InstallInterfaceBase):
>          # Never reinit VG's in rescue mode!
>          return False
> 
> +    def questionInitializeDASD(self, c, devs):
> +        # Special return value to let dasd.py know we're rescue mode
> +        return "rescue"
> +
>      def shutdown (self):
>          pass
> 
> diff --git a/storage/dasd.py b/storage/dasd.py
> index 304099d..a8ee27a 100644
> --- a/storage/dasd.py
> +++ b/storage/dasd.py
> @@ -128,6 +128,10 @@ class DASD:
>              if rc == 1:
>                  log.info("    not running dasdfmt, exiting installer")
>                  sys.exit(0)
> +            # Check for special rescue mode return
> +            elif rc == "rescue":
> +                log.info("    rescue mode: not running dasdfmt")
> +                return
> 
>          argv = ["-y", "-P", "-d", "cdl", "-b", "4096"]
> 

Steffen

Linux on System z Development

IBM Deutschland Research & Development GmbH
Vorsitzender des Aufsichtsrats: Martin Jetter
Geschäftsführung: Dirk Wittkopp
Sitz der Gesellschaft: Böblingen
Registergericht: Amtsgericht Stuttgart, HRB 243294


_______________________________________________
Anaconda-devel-list mailing list
Anaconda-devel-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/anaconda-devel-list


[Index of Archives]     [Kickstart]     [Fedora Users]     [Fedora Legacy List]     [Fedora Maintainers]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]
  Powered by Linux