From b4e1bf572ebf1c766cf40bd30fd0ccafda245a01 Mon Sep 17 00:00:00 2001 From: adv Date: Thu, 12 Jan 2012 20:34:55 +0000 Subject: [PATCH] #460 #456 oginit ro images - ogprotocol nfs git-svn-id: https://opengnsys.es/svn/branches/version1.0@2431 a21b9725-9963-47de-94b9-378ad31fedc9 --- includes/etc/initramfs-tools/scripts/ogfunctions | 7 ++++--- includes/etc/initramfs-tools/scripts/oginit | 2 +- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/includes/etc/initramfs-tools/scripts/ogfunctions b/includes/etc/initramfs-tools/scripts/ogfunctions index 773e413..17130d3 100644 --- a/includes/etc/initramfs-tools/scripts/ogfunctions +++ b/includes/etc/initramfs-tools/scripts/ogfunctions @@ -248,7 +248,8 @@ ogUpdateInitrd () { cd /tmp mkdir /tmp/cache - mount -t reiserfs LABEL=CACHE /tmp/cache || return + TYPE=$(blkid | grep CACHE | awk -F"TYPE=" '{print $2}' | tr -d \") + mount -t $TYPE LABEL=CACHE /tmp/cache || return mkdir /tmp/cache/boot @@ -314,7 +315,7 @@ ogConnect () case "$PROTOCOL" in nfs) - nfsmount -o nolock${READONLY} ${SERVER}:${SRC} ${DST} + nfsmount ${SERVER}:${SRC} ${DST} -o nolock${READONLY} 2> /dev/null || mount.nfs ${SERVER}:${SRC} ${DST} -o nolock${READONLY} ;; smb) mount.cifs //${SERVER}/${SRC} ${DST} ${OPTIONS}${READONLY} @@ -342,7 +343,7 @@ ogConnectOgLive () mount -t $TYPE LABEL=$LABEL $DSTOGLIVE if [ $? != 0 ] then - mount -t reiserfs LABEL=CACHE $DSTOGLIVE + mount LABEL=CACHE $DSTOGLIVE export LOCALMEDIA=CACHE fi else diff --git a/includes/etc/initramfs-tools/scripts/oginit b/includes/etc/initramfs-tools/scripts/oginit index cc179f9..95efe28 100755 --- a/includes/etc/initramfs-tools/scripts/oginit +++ b/includes/etc/initramfs-tools/scripts/oginit @@ -102,7 +102,7 @@ mountroot () [ "$ogdebug" == "true" ] && ogYesNo --timeout 5 --default no "Stop before connect with REPOSITORY STORAGE on $OGSERVERIMAGES : y/N " [ $? == 0 ] && sh || echo " " - ogConnect $OGSERVERIMAGES $OGPROTOCOL $SRCOGIMAGES $DSTOGIMAGES + ogConnect $OGSERVERIMAGES $OGPROTOCOL $SRCOGIMAGES $DSTOGIMAGES ,ro [ "$ogdebug" == "true" ] && ogYesNo --timeout 5 --default no "Stop before doing the postconfiguration: y/N "