mirror of
https://github.com/Ysurac/openmptcprouter-vps.git
synced 2025-03-09 15:50:00 +00:00
Fix script for kernel binary install
This commit is contained in:
parent
269b986cbe
commit
7ce28a9481
1 changed files with 7 additions and 5 deletions
|
@ -199,14 +199,14 @@ fi
|
||||||
echo "Install mptcp kernel and shadowsocks..."
|
echo "Install mptcp kernel and shadowsocks..."
|
||||||
apt-get update
|
apt-get update
|
||||||
sleep 2
|
sleep 2
|
||||||
apt-get -y install dirmngr patch
|
apt-get -y install dirmngr patch rename curl libcurl4 unzip
|
||||||
|
|
||||||
if [ "$SOURCES" = "yes" ]; then
|
if [ "$SOURCES" = "yes" ]; then
|
||||||
wget -O /tmp/linux-image-${KERNEL_RELEASE}_amd64.deb ${VPSURL}kernel/linux-image-${KERNEL_RELEASE}_amd64.deb
|
wget -O /tmp/linux-image-${KERNEL_RELEASE}_amd64.deb ${VPSURL}kernel/linux-image-${KERNEL_RELEASE}_amd64.deb
|
||||||
wget -O /tmp/linux-headers-${KERNEL_RELEASE}_amd64.deb ${VPSURL}kernel/linux-headers-${KERNEL_RELEASE}_amd64.deb
|
wget -O /tmp/linux-headers-${KERNEL_RELEASE}_amd64.deb ${VPSURL}kernel/linux-headers-${KERNEL_RELEASE}_amd64.deb
|
||||||
# Rename bzImage to vmlinuz, needed when custom kernel was used
|
# Rename bzImage to vmlinuz, needed when custom kernel was used
|
||||||
cd /boot
|
cd /boot
|
||||||
apt-get -y install rename curl libcurl4 unzip git
|
apt-get -y install git
|
||||||
rename 's/^bzImage/vmlinuz/s' * >/dev/null 2>&1
|
rename 's/^bzImage/vmlinuz/s' * >/dev/null 2>&1
|
||||||
#apt-get -y install linux-mptcp
|
#apt-get -y install linux-mptcp
|
||||||
#dpkg --remove --force-remove-reinstreq linux-image-${KERNEL_VERSION}-mptcp
|
#dpkg --remove --force-remove-reinstreq linux-image-${KERNEL_VERSION}-mptcp
|
||||||
|
@ -220,9 +220,11 @@ if [ "$SOURCES" = "yes" ]; then
|
||||||
else
|
else
|
||||||
cd /boot
|
cd /boot
|
||||||
rename 's/^bzImage/vmlinuz/s' * >/dev/null 2>&1
|
rename 's/^bzImage/vmlinuz/s' * >/dev/null 2>&1
|
||||||
echo "Install kernel linux-image-${KERNEL_RELEASE}"
|
if [ "$(dpkg -l | grep linux-image-${KERNEL_VERSION} | grep ${KERNEL_PACKAGE_VERSION})" = "" ]; then
|
||||||
echo "\033[1m !!! if kernel install fail run: dpkg --remove --force-remove-reinstreq linux-image-${KERNEL_VERSION}-mptcp !!! \033[0m"
|
echo "Install kernel linux-image-${KERNEL_RELEASE}"
|
||||||
apt-get -y install linux-image-${KERNEL_VERSION}-mptcp=${KERNEL_PACKAGE_VERSION} linux-headers-${KERNEL_VERSION}-mptcp=${KERNEL_PACKAGE_VERSION}
|
echo "\033[1m !!! if kernel install fail run: dpkg --remove --force-remove-reinstreq linux-image-${KERNEL_VERSION}-mptcp !!! \033[0m"
|
||||||
|
apt-get -y install linux-image-${KERNEL_VERSION}-mptcp=${KERNEL_PACKAGE_VERSION} linux-headers-${KERNEL_VERSION}-mptcp=${KERNEL_PACKAGE_VERSION}
|
||||||
|
fi
|
||||||
fi
|
fi
|
||||||
# Check if mptcp kernel is grub default kernel
|
# Check if mptcp kernel is grub default kernel
|
||||||
echo "Set MPTCP kernel as grub default..."
|
echo "Set MPTCP kernel as grub default..."
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue