diff options
author | Mike Fulbright <msf@redhat.com> | 2001-04-04 21:03:53 +0000 |
---|---|---|
committer | Mike Fulbright <msf@redhat.com> | 2001-04-04 21:03:53 +0000 |
commit | 17ca67e561a29698f7351a3027e2674bd70e0f4d (patch) | |
tree | 06f7d04302d2e00ecbe8ad4940bd2f13bef7d0aa /rescue.py | |
parent | 63ebeff438ea90e8dbc9cdf30f70948179f23874 (diff) | |
download | anaconda-17ca67e561a29698f7351a3027e2674bd70e0f4d.tar.gz anaconda-17ca67e561a29698f7351a3027e2674bd70e0f4d.tar.xz anaconda-17ca67e561a29698f7351a3027e2674bd70e0f4d.zip |
allow use of 'nomount' commandline option to prevent rescue mode from trying to mount root directory.
Diffstat (limited to 'rescue.py')
-rw-r--r-- | rescue.py | 11 |
1 files changed, 7 insertions, 4 deletions
@@ -24,7 +24,7 @@ class RescueInterface: def __init__(self, screen): self.screen = screen -def runRescue(url, serial): +def runRescue(url, serial, mountroot): from fstab import NewtFstab @@ -32,6 +32,12 @@ def runRescue(url, serial): log.open (serial, 0, 0, 1) + for file in [ "services", "protocols", "group" ]: + os.symlink('/mnt/runtime/etc/' + file, '/etc/' + file) + + if (not mountroot): + os.execv("/bin/sh", [ "-/bin/sh" ]) + try: fstab = NewtFstab(1, serial, 0, 0, None, None, None, 0, [], 0, 0, requireBlockDevices = 0) @@ -133,9 +139,6 @@ def runRescue(url, serial): screen.finish() - for file in [ "services", "protocols", "group" ]: - os.symlink('/mnt/runtime/etc/' + file, '/etc/' + file) - if rootmounted: print print _("Your system is mounted under the /mnt/sysimage directory.") |