git://git.onelab.eu
/
bootmanager.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
1f05fa7
)
patch from Marc F to optionally pull in extra kexec args from /kargs.txt
author
Aaron Klingaman
<alk@cs.princeton.edu>
Fri, 2 Dec 2005 01:40:22 +0000
(
01:40
+0000)
committer
Aaron Klingaman
<alk@cs.princeton.edu>
Fri, 2 Dec 2005 01:40:22 +0000
(
01:40
+0000)
source/steps/ChainBootNode.py
patch
|
blob
|
history
diff --git
a/source/steps/ChainBootNode.py
b/source/steps/ChainBootNode.py
index
170437f
..
a83474a
100644
(file)
--- a/
source/steps/ChainBootNode.py
+++ b/
source/steps/ChainBootNode.py
@@
-180,9
+180,23
@@
def Run( vars, log ):
except IOError:
log.write( "Couldn't read /proc/modules, continuing.\n" )
except IOError:
log.write( "Couldn't read /proc/modules, continuing.\n" )
+
+ kargs = "ramdisk_size=8192"
+ try:
+ kargsfb = open("/kargs.txt","r")
+ moreargs = kargsfb.readline()
+ kargsfb.close()
+ moreargs = moreargs.strip()
+ log.write( 'Parsed in "%s" kexec args from /kargs.txt\n' % moreargs )
+ kargs = kargs + " " + moreargs
+ except IOError:
+ # /kargs.txt does not exist, which is fine. Just kexec with default
+ # kargs, which is ramdisk_size=8192
+ pass
+
try:
try:
- utils.sysexec(
"kexec --force --initrd=/tmp/initrd "
\
-
"--append=ramdisk_size=8192 /tmp/kernel"
)
+ utils.sysexec(
'kexec --force --initrd=/tmp/initrd '
\
+
'--append="%s" /tmp/kernel' % kargs
)
except BootManagerException, e:
# if kexec fails, we've shut the machine down to a point where nothing
# can run usefully anymore (network down, all modules unloaded, file
except BootManagerException, e:
# if kexec fails, we've shut the machine down to a point where nothing
# can run usefully anymore (network down, all modules unloaded, file