mirror of
https://github.com/vincentmli/bpfire.git
synced 2026-05-06 13:06:11 +02:00
Start Core Update 158
Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
This commit is contained in:
@@ -1 +0,0 @@
|
||||
../../../common/Canary-Stability
|
||||
@@ -1 +0,0 @@
|
||||
../../../common/Convert-TNEF
|
||||
@@ -1 +0,0 @@
|
||||
../../../common/Convert-UUlib
|
||||
@@ -1 +0,0 @@
|
||||
../../../common/Crypt-PasswdMD5
|
||||
@@ -1 +0,0 @@
|
||||
../../../common/Digest
|
||||
@@ -1 +0,0 @@
|
||||
../../../../common/aarch64/linux
|
||||
@@ -1 +0,0 @@
|
||||
../../../../common/aarch64/linux-initrd
|
||||
@@ -1 +0,0 @@
|
||||
../../../../common/aarch64/lm_sensors
|
||||
@@ -1 +0,0 @@
|
||||
../../../common/apache2
|
||||
@@ -1 +0,0 @@
|
||||
../../../../common/armv5tel/linux-initrd-multi
|
||||
@@ -1 +0,0 @@
|
||||
../../../../common/armv5tel/linux-multi
|
||||
@@ -1 +0,0 @@
|
||||
../../../../common/armv5tel/lm_sensors
|
||||
@@ -1 +0,0 @@
|
||||
../../../common/bash
|
||||
@@ -1 +0,0 @@
|
||||
../../../common/boost
|
||||
@@ -1 +0,0 @@
|
||||
../../../common/collectd
|
||||
@@ -1 +0,0 @@
|
||||
../../../common/curl
|
||||
@@ -1 +0,0 @@
|
||||
../../../common/ddns
|
||||
@@ -1 +0,0 @@
|
||||
../../../common/dejavu-fonts-ttf
|
||||
@@ -1 +0,0 @@
|
||||
../../../common/expat
|
||||
@@ -1 +0,0 @@
|
||||
../../../common/file
|
||||
@@ -1,6 +0,0 @@
|
||||
srv/web/ipfire/cgi-bin/getrrdimage.cgi
|
||||
srv/web/ipfire/cgi-bin/iptables.cgi
|
||||
srv/web/ipfire/html/themes/ipfire/include/css/style.css
|
||||
usr/local/bin/getipstat
|
||||
usr/sbin/unbound-dhcp-leases-bridge
|
||||
var/ipfire/network-functions.pl
|
||||
@@ -1 +0,0 @@
|
||||
../../../common/fuse
|
||||
@@ -1 +0,0 @@
|
||||
../../../common/glib
|
||||
@@ -1 +0,0 @@
|
||||
../../../../common/i586/linux
|
||||
@@ -1 +0,0 @@
|
||||
../../../../common/i586/linux-initrd
|
||||
@@ -1 +0,0 @@
|
||||
../../../../common/i586/lm_sensors
|
||||
@@ -1 +0,0 @@
|
||||
../../../common/iproute2
|
||||
@@ -1 +0,0 @@
|
||||
../../../common/iputils
|
||||
@@ -1 +0,0 @@
|
||||
../../../common/less
|
||||
@@ -1 +0,0 @@
|
||||
../../../common/libaio
|
||||
@@ -1 +0,0 @@
|
||||
../../../common/libarchive
|
||||
@@ -1 +0,0 @@
|
||||
../../../common/libcap-ng
|
||||
@@ -1 +0,0 @@
|
||||
../../../common/libedit
|
||||
@@ -1 +0,0 @@
|
||||
../../../common/libevent2
|
||||
@@ -1 +0,0 @@
|
||||
../../../common/libgcrypt
|
||||
@@ -1 +0,0 @@
|
||||
../../../common/libgpg-error
|
||||
@@ -1 +0,0 @@
|
||||
../../../common/libjpeg
|
||||
@@ -1 +0,0 @@
|
||||
../../../common/libupnp
|
||||
@@ -1 +0,0 @@
|
||||
../../../common/libxcrypt
|
||||
@@ -1 +0,0 @@
|
||||
../../../common/libxml2
|
||||
@@ -1 +0,0 @@
|
||||
../../../common/libxslt
|
||||
@@ -1 +0,0 @@
|
||||
../../../common/newt
|
||||
@@ -1 +0,0 @@
|
||||
../../../common/openssh
|
||||
@@ -1 +0,0 @@
|
||||
../../../common/pixman
|
||||
@@ -1 +0,0 @@
|
||||
../../../common/poppler
|
||||
@@ -1 +0,0 @@
|
||||
../../../common/poppler-data
|
||||
@@ -1 +0,0 @@
|
||||
../../../common/ppp
|
||||
@@ -1 +0,0 @@
|
||||
../../../common/python3-daemon
|
||||
@@ -1 +0,0 @@
|
||||
../../../common/readline
|
||||
@@ -1 +0,0 @@
|
||||
../../../common/sqlite
|
||||
@@ -1 +0,0 @@
|
||||
../../../common/squid
|
||||
@@ -1 +0,0 @@
|
||||
../../../common/sudo
|
||||
@@ -1 +0,0 @@
|
||||
../../../../common/x86_64/linux
|
||||
@@ -1 +0,0 @@
|
||||
../../../../common/x86_64/linux-initrd
|
||||
@@ -1 +0,0 @@
|
||||
../../../../common/x86_64/lm_sensors
|
||||
@@ -1 +0,0 @@
|
||||
../../../common/xfsprogs
|
||||
@@ -24,70 +24,14 @@
|
||||
. /opt/pakfire/lib/functions.sh
|
||||
/usr/local/bin/backupctrl exclude >/dev/null 2>&1
|
||||
|
||||
core=157
|
||||
|
||||
exit_with_error() {
|
||||
# Set last succesfull installed core.
|
||||
echo $(($core-1)) > /opt/pakfire/db/core/mine
|
||||
# force fsck at next boot, this may fix free space on xfs
|
||||
touch /forcefsck
|
||||
# don't start pakfire again at error
|
||||
killall -KILL pak_update
|
||||
/usr/bin/logger -p syslog.emerg -t ipfire \
|
||||
"core-update-${core}: $1"
|
||||
exit $2
|
||||
}
|
||||
core=158
|
||||
|
||||
# Remove old core updates from pakfire cache to save space...
|
||||
for (( i=1; i<=$core; i++ )); do
|
||||
rm -f /var/cache/pakfire/core-upgrade-*-$i.ipfire
|
||||
done
|
||||
|
||||
KVER="xxxKVERxxx"
|
||||
|
||||
# Backup uEnv.txt if exist
|
||||
if [ -e /boot/uEnv.txt ]; then
|
||||
cp -vf /boot/uEnv.txt /boot/uEnv.txt.org
|
||||
fi
|
||||
|
||||
# Do some sanity checks.
|
||||
case $(uname -r) in
|
||||
*-ipfire-kirkwood)
|
||||
exit_with_error "ERROR cannot update. kirkwood kernel was not supported." 1
|
||||
;;
|
||||
*-ipfire*)
|
||||
# Ok.
|
||||
;;
|
||||
*)
|
||||
exit_with_error "ERROR cannot update. No IPFire Kernel." 1
|
||||
;;
|
||||
esac
|
||||
if [ -e /boot/grub/grub.conf ]; then
|
||||
exit_with_error "ERROR unsupported GRUB1/pygrub found!" 1
|
||||
fi
|
||||
|
||||
# Check diskspace on root
|
||||
ROOTSPACE=`df / -Pk | sed "s| * | |g" | cut -d" " -f4 | tail -n 1`
|
||||
|
||||
if [ $ROOTSPACE -lt 100000 ]; then
|
||||
exit_with_error "ERROR cannot update because not enough free space on root." 2
|
||||
exit 2
|
||||
fi
|
||||
|
||||
# Remove the old kernel
|
||||
rm -rf /boot/System.map-*
|
||||
rm -rf /boot/config-*
|
||||
rm -rf /boot/ipfirerd-*
|
||||
rm -rf /boot/initramfs-*
|
||||
rm -rf /boot/vmlinuz-*
|
||||
rm -rf /boot/uImage-*-ipfire-*
|
||||
rm -rf /boot/zImage-*-ipfire-*
|
||||
rm -rf /boot/uInit-*-ipfire-*
|
||||
rm -rf /boot/dtb-*-ipfire-*
|
||||
rm -rf /lib/modules
|
||||
|
||||
# Remove files
|
||||
rm -rf /usr/lib/libboost*.so.1.71.0
|
||||
|
||||
# Stop services
|
||||
|
||||
@@ -103,46 +47,10 @@ ldconfig
|
||||
# Filesytem cleanup
|
||||
/usr/local/bin/filesystem-cleanup
|
||||
|
||||
# Fix file permissions changed
|
||||
chmod -s /usr/bin/gpg
|
||||
chmod -x \
|
||||
/var/ipfire/fwhosts/icmp-types \
|
||||
/var/ipfire/ovpn/ovpn-leases.db
|
||||
|
||||
chown -R root:root \
|
||||
/var/ipfire/updatexlrator/bin \
|
||||
/var/ipfire/urlfilter/bin
|
||||
|
||||
chown root:root \
|
||||
/srv/web/ipfire/cgi-bin/cachemgr.cgi
|
||||
|
||||
# Delete scrubbed files
|
||||
rm -f \
|
||||
/usr/lib/dma-mbox-create \
|
||||
/usr/lib/openssh/ssh-keysign
|
||||
|
||||
# Start services
|
||||
/etc/init.d/sshd restart
|
||||
/etc/init.d/apache restart
|
||||
/etc/init.d/collectd restart
|
||||
/etc/init.d/squid restart
|
||||
|
||||
# remove lm_sensor config after collectd was started
|
||||
# to reserch sensors at next boot with updated kernel
|
||||
rm -f /etc/sysconfig/lm_sensors
|
||||
|
||||
# Upadate Kernel version uEnv.txt
|
||||
if [ -e /boot/uEnv.txt ]; then
|
||||
sed -i -e "s/KVER=.*/KVER=${KVER}/g" /boot/uEnv.txt
|
||||
fi
|
||||
|
||||
# call user update script (needed for some arm boards)
|
||||
if [ -e /boot/pakfire-kernel-update ]; then
|
||||
/boot/pakfire-kernel-update ${KVER}
|
||||
fi
|
||||
|
||||
# This update needs a reboot...
|
||||
touch /var/run/need_reboot
|
||||
#touch /var/run/need_reboot
|
||||
|
||||
# Finish
|
||||
/etc/init.d/fireinfo start
|
||||
Reference in New Issue
Block a user