X-Git-Url: http://git.ipfire.org/?a=blobdiff_plain;f=config%2Frootfiles%2Fcore%2F76%2Fupdate.sh;h=c572e7cc2b3df039175058aff338d6c488e2092c;hb=dd62fd25cde358524861fdd8e20aed1a83c6a6da;hp=12d6b1c0fb3d1f7170d72a8de312c6e7cc866142;hpb=dc3c6687c9c78f7e94f06f6c327d8f14777da179;p=people%2Fteissler%2Fipfire-2.x.git diff --git a/config/rootfiles/core/76/update.sh b/config/rootfiles/core/76/update.sh index 12d6b1c0f..c572e7cc2 100644 --- a/config/rootfiles/core/76/update.sh +++ b/config/rootfiles/core/76/update.sh @@ -118,7 +118,7 @@ tar cJvf /var/ipfire/backup/core-upgrade$core_$KVER.tar.xz \ # Check diskspace on root ROOTSPACE=`df / -Pk | sed "s| * | |g" | cut -d" " -f4 | tail -n 1` -if [ $ROOTSPACE -lt 70000 ]; then +if [ $ROOTSPACE -lt 100000 ]; then /usr/bin/logger -p syslog.emerg -t ipfire \ "core-update-$core: ERROR cannot update because not enough free space on root." exit 2 @@ -175,10 +175,23 @@ esac rm -rf /srv/web/ipfire/html/themes/ipfire # rename /etc/modprobe.d files -for i in $(find /etc/modprobe.d/* | grep -v ".conf") +for i in $(find /etc/modprobe.d/* | grep -v ".conf"); do mv $i $i.conf done +# Move /var/run to /run. +if [ -L "/run" ]; then + rm -f /run +fi + +mkdir -p /run +if mountpoint /var/run; then + mount --move /var/run /run + rm -rf /var/run +fi + +ln -svf ../run /var/run + # #Extract files tar xavf /opt/pakfire/tmp/files* --no-overwrite-dir -p --numeric-owner -C / @@ -254,6 +267,7 @@ sed -i -e "s/tty1 9600$/tty1 9600 --noclear/g" /etc/inittab sed -i -e "s/^proc/#proc/g" /etc/fstab sed -i -e "s/^sysfs/#sysfs/g" /etc/fstab sed -i -e "s/^devpts/#devpts/g" /etc/fstab +sed -i -e "s|^none\s/var/run|#none /var/run|/g" /etc/fstab # Convert udev persistent network rules sed -i -e "s/SYSFS{/ATTR{/g" /etc/udev/rules.d/30-persistent-network.rules @@ -327,7 +341,7 @@ rm -rf /opt/pakfire/db/*/meta-linux-pae if [ ! "$(grep "^flags.* pae " /proc/cpuinfo)" == "" ]; then ROOTSPACE=`df / -Pk | sed "s| * | |g" | cut -d" " -f4 | tail -n 1` BOOTSPACE=`df /boot -Pk | sed "s| * | |g" | cut -d" " -f4 | tail -n 1` - if [ $BOOTSPACE -lt 8000 -o $ROOTSPACE -lt 70000 ]; then + if [ $BOOTSPACE -lt 9000 -o $ROOTSPACE -lt 90000 ]; then /usr/bin/logger -p syslog.emerg -t ipfire \ "core-update-$core: WARNING not enough space for pae kernel." else