summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDirk von Suchodoletz2007-05-30 16:12:33 +0200
committerDirk von Suchodoletz2007-05-30 16:12:33 +0200
commitc80f287b64eb53e0cb961bc7f3e12ca878f120a5 (patch)
tree7d159faffaaed1b99132fcc1d500df8bc2e382b7
parent* added missing glibc-32bit to suse-10.2_x86_64 distro info (diff)
downloadcore-c80f287b64eb53e0cb961bc7f3e12ca878f120a5.tar.gz
core-c80f287b64eb53e0cb961bc7f3e12ca878f120a5.tar.xz
core-c80f287b64eb53e0cb961bc7f3e12ca878f120a5.zip
Fix for mkdxsinitrd (see r1114) and several testing stuff ...
git-svn-id: http://svn.openslx.org/svn/openslx/trunk@1116 95ad53e4-c205-0410-b2fa-d234c58c8868
-rw-r--r--Makefile3
-rwxr-xr-xinitramfs/initrd-stuff/init24
-rwxr-xr-xinitramfs/mkdxsinitrd22
3 files changed, 31 insertions, 18 deletions
diff --git a/Makefile b/Makefile
index d84fcd6b..f5d166e7 100644
--- a/Makefile
+++ b/Makefile
@@ -169,9 +169,10 @@ supported."; \
@ # copy license
@cp COPYING $(DESTDIR)$(SLX_BASE_PATH)/;
- @ # copy initramfs generator scripts (and inject SLX_CONFIG_PATH on the way):
+ @ # copy initramfs generator scripts (and inject SLX_CONFIG_PATH, SLX_SHARE_PATH on the way):
@cp ./initramfs/mkdxsinitrd $(DESTDIR)$(SLX_BIN_PATH)/; \
sed -e "s,@@@SLX_CONFIG_PATH@@@,$(SLX_CONFIG_PATH)," \
+ -e "s,@@@SLX_SHARE_PATH@@@,$(SLX_SHARE_PATH)," \
-i $(DESTDIR)$(SLX_BIN_PATH)/mkdxsinitrd;
@ # copy all PERL-scripts and their required modules:
diff --git a/initramfs/initrd-stuff/init b/initramfs/initrd-stuff/init
index 67344f93..0303d392 100755
--- a/initramfs/initrd-stuff/init
+++ b/initramfs/initrd-stuff/init
@@ -193,10 +193,10 @@ in $0\ncountry=\"${COUNTRY}\"" >> /etc/machine-setup
case $srvproto in
nfs)
# nfsroot consists now of two different parts
- root_path=/$(uri_token $rootfs path)
+ nfspath=/$(uri_token $rootfs path)
nfsserver=$(uri_token $rootfs server)
echo -e "\n# nfs root information gotten via kernel command \
-line in $0\n#nfsroot=\"${nfsserver}:${root_path}\"\n" >> /etc/machine-setup
+line in $0\n#nfsroot=\"${nfsserver}:${nfspath}\"\n" >> /etc/machine-setup
;;
*nbd)
nbdmod=$srvproto
@@ -226,8 +226,6 @@ line in $0\n#nfsroot=\"${nfsserver}:${root_path}\"\n" >> /etc/machine-setup
# deprecated: nfs server and path (will be removed soon)
nfsroot=*)
nfsroot=${opts#nfsroot=}
- #root_path=
- #nfsserver=
echo -e "\n# nfs root information gotten via kernel command line in \n\
$0\n# deprecated: please use rootfs=nfs://...\nnfsroot=\"${nfsroot}\"\n" \
>> /etc/machine-setup
@@ -306,6 +304,10 @@ else
fi
# load network adaptor modules
hwautocfg nwmod
+if [ -n "${essid}" ] ; then
+ echo "Starting shell for testing of WLAN setup procedure"
+ /bin/ash
+fi
# set up loopback networking
[ $DEBUGLEVEL -eq 20 ] && echo "** starting ip config at $(sysup)"
@@ -464,10 +466,18 @@ fi
# call function for nfs mounts
if [ -z "${nbdmod}" -a -z "${nbdserver}" ] ; then
[ $DEBUGLEVEL -eq 20 ] && echo "** started nfs mount"
+ # read in extended machine-setup
. /etc/machine-setup
- # check if nfsserver is set as variable @@@serverip@@@
- nfsserver=$(checkip $nfsserver)
- nfsroot=${nfsserver}:${root_path}
+ # prefer nfsserver and nfspath from kernel commandline over the information
+ # gotten from dhcp server
+ if [ -n "${nfsserver}" -a -n "${nfspath}" ] ; then
+ # check if nfsserver is set as variable @@@serverip@@@
+ nfsserver=$(checkip $nfsserver)
+ nfsroot=${nfsserver}:${nfspath}
+ else
+ # the root_path should contain server ip and path in nfsroot notation
+ nfsroot=${root_path}
+ fi
nfsmnt ${nfsroot} || error "$init_nfs"
[ $DEBUGLEVEL -eq 20 ] && echo "** finished nfs mount at $(sysup)"
fi
diff --git a/initramfs/mkdxsinitrd b/initramfs/mkdxsinitrd
index fef86d76..b7f11494 100755
--- a/initramfs/mkdxsinitrd
+++ b/initramfs/mkdxsinitrd
@@ -53,6 +53,7 @@ D_XFONTPATH="<set in ~/distro-config/distro file>"
D_DEFAULTCOUNTRY="<set in ~/distro-config/distro file>"
# read in the global settings
SLX_CONFIG_PATH=@@@SLX_CONFIG_PATH@@@
+SLX_SHARE_PATH=@@@SLX_SHARE_PATH@@@
[ -f $SLX_SHARE_PATH/settings.default ] && \
. $SLX_SHARE_PATH/settings.default
[ -f $SLX_CONFIG_PATH/settings ] && \
@@ -100,17 +101,18 @@ precheck() {
echo -e "\nYou don't have the needed permission. Please rerun as root user!\n"
exit 1
fi
+ # fixme:: Do we really need this!?
# Check for correct settings of SLX-Variables
- if [ "x" == "x$SLX_BASE_PATH" ]; then
- if [ "x$SLX_CONFIG_PATH" == "x@@@SLX_CONFIG_PATH@@@" ]; then
- echo "Please make sure you install the Open SLX Software properly,"
- echo "i.e. install it using the provided Makefile. Thanks."
- else
- echo "Essential configuration is missing. Please verify"
- echo "existence and correctness of $SLX_SHARE_PATH/settings.default"
- fi
- exit 1
- fi
+ #if [ "x" == "x$SLX_BASE_PATH" ]; then
+ # if [ "x$SLX_CONFIG_PATH" == "x@@@SLX_CONFIG_PATH@@@" ]; then
+ # echo "Please make sure you install the Open SLX Software properly,"
+ # echo "i.e. install it using the provided Makefile. Thanks."
+ # else
+ # echo "Essential configuration is missing. Please verify"
+ # echo "existence and correctness of $SLX_SHARE_PATH/settings.default"
+ # fi
+ # exit 1
+ #fi
}
# replaces which command to find executables inside ROOTDIR