mirror of
https://mojerepo.cf/NeoBoot/NeoBoot-9.git
synced 2025-10-30 23:55:46 +01:00
update 8.13
This commit is contained in:
@@ -1,11 +1,9 @@
|
||||
#!/bin/sh
|
||||
|
||||
#!/bin/sh
|
||||
TARGET=Flash
|
||||
NEODEVICE=`cat /usr/lib/enigma2/python/Plugins/Extensions/NeoBoot/.location`
|
||||
IMAGEKATALOG=ImageBoot
|
||||
UPLOADKATALOG=ImagesUpload
|
||||
|
||||
|
||||
if [ ! -e $NEODEVICE$IMAGEKATALOG/.neonextboot ]; then
|
||||
mnttest="nouuid"
|
||||
if [ -e $NEOBOOT/bin/install ]; then
|
||||
@@ -37,7 +35,7 @@ if [ ! -e $NEODEVICE$IMAGEKATALOG/.neonextboot ]; then
|
||||
ln -sfn /sbin/init.sysvinit /sbin/init
|
||||
echo "Flash " > $NEODEVICE$IMAGEKATALOG/.neonextboot
|
||||
echo "Error - Back to Flash... "
|
||||
sleep 5; reboot -f
|
||||
sleep 5; #reboot -f
|
||||
fi
|
||||
|
||||
if [ -f $NEODEVICE$IMAGEKATALOG/.neonextboot ]; then
|
||||
@@ -48,62 +46,60 @@ fi
|
||||
if [ $TARGET = "Flash" ]; then
|
||||
echo "BOOTNEO is booting image from " $TARGET
|
||||
/usr/bin/showiframe /usr/lib/enigma2/python/Plugins/Extensions/NeoBoot/neowait.mvi > /dev/null 2>&1
|
||||
sleep 3
|
||||
sleep 3
|
||||
ln -sfn /sbin/init.sysvinit /sbin/init
|
||||
reboot -f
|
||||
#reboot -f
|
||||
else
|
||||
######### test boot new imaga>>>>
|
||||
VUMODEL=$( cat /proc/stb/info/vumodel )
|
||||
BOXNAME=$( cat /etc/hostname)
|
||||
DIRECTORY=ImageBoot
|
||||
UPLOAD=ImagesUpload
|
||||
DEVICEBOOT=`cat /usr/lib/enigma2/python/Plugins/Extensions/NeoBoot/.location`
|
||||
if [ -e $DEVICEBOOT$DIRECTORY/$TARGET/.control_ok ]; then
|
||||
[ $PL ] && echo "Nie ma bledu, normalny start image..." || echo "No Error - Booting image normal..."
|
||||
elif [ -e $DEVICEBOOT$DIRECTORY/$TARGET/.control_boot_new_image ]; then
|
||||
echo "First start image - The first attempt to launch a new image... "; rm -f $DEVICEBOOT$DIRECTORY/$TARGET/.control_boot_new_image
|
||||
else
|
||||
if [ -f `cat /usr/lib/enigma2/python/Plugins/Extensions/NeoBoot/.location`$IMAGEKATALOG/$TARGET/boot/zImage.$BOXNAME ]; then
|
||||
VUMODEL=`cat /proc/stb/info/vumodel`
|
||||
BOXNAME=`cat /etc/hostname`
|
||||
if [ ! -e $DEVICEBOOT$DIRECTORY/$TARGET/.control_ok ] ; then
|
||||
if [ $BOXNAME = "vuultimo4k" ] || [ $BOXNAME = "vusolo4k" ] || [ $BOXNAME = "vuuno4kse" ] || [ $BOXNAME = "vuuno4k" ]; then
|
||||
if [ -d /proc/stb ] ; then
|
||||
echo " Install kernel image flash.... " $BOXNAME
|
||||
dd if=$DEVICEBOOT$UPLOAD/.kernel/flash-kernel-$VUMODEL.bin of=/dev/mmcblk0p1
|
||||
fi
|
||||
elif [ $BOXNAME = "vuzero4k" ] ; then
|
||||
if [ -d /proc/stb ] ; then
|
||||
echo " Install kernel image flash.... " $BOXNAME
|
||||
dd if=$DEVICEBOOT$UPLOAD/.kernel/flash-kernel-$VUMODEL.bin of=/dev/mmcblk0p4
|
||||
fi
|
||||
elif [ $BOXNAME = "vuduo4k" ] ; then
|
||||
if [ -d /proc/stb ] ; then
|
||||
echo " Install kernel image flash.... " $BOXNAME
|
||||
dd if=$DEVICEBOOT$UPLOAD/.kernel/flash-kernel-$VUMODEL.bin of=/dev/mmcblk0p6
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
echo "Wrong kernel. Press number 3" > $DEVICEBOOT$UPLOAD/.kernel/used_flash_kernel
|
||||
ln -sfn /sbin/init.sysvinit /sbin/init
|
||||
echo "Flash " > $DEVICEBOOT$DIRECTORY/.neonextboot
|
||||
echo "Error - NeoBoot he can not run it image !!! "
|
||||
echo "Restart STB - Back to Flash... "
|
||||
/usr/bin/showiframe /usr/lib/enigma2/python/Plugins/Extensions/NeoBoot/error.mvi > /dev/null 2>&1
|
||||
sleep 10; #reboot -f
|
||||
fi
|
||||
|
||||
######### test boot new imaga>>>>
|
||||
VUMODEL=$( cat /proc/stb/info/vumodel )
|
||||
BOXNAME=$( cat /etc/hostname)
|
||||
DIRECTORY=ImageBoot
|
||||
UPLOAD=ImagesUpload
|
||||
DEVICEBOOT=`cat /usr/lib/enigma2/python/Plugins/Extensions/NeoBoot/.location`
|
||||
if [ -e $DEVICEBOOT$DIRECTORY/$TARGET/.control_ok ]; then
|
||||
[ $PL ] && echo "Nie ma bledu, normalny start image..." || echo "No Error - Booting image normal..."
|
||||
else
|
||||
######### test boot new image<<<<<
|
||||
if [ -e $NEODEVICE$IMAGEKATALOG/$TARGET/usr/bin/enigma2_pre_start.sh ] ; then
|
||||
rm -f $NEODEVICE$IMAGEKATALOG/$TARGET/usr/bin/enigma2_pre_start.sh
|
||||
fi
|
||||
cp -f /usr/lib/enigma2/python/Plugins/Extensions/NeoBoot/files/mountpoint.sh $NEODEVICE$IMAGEKATALOG/$TARGET/usr/bin/enigma2_pre_start.sh
|
||||
|
||||
VUMODEL=`cat /proc/stb/info/vumodel`
|
||||
BOXNAME=`cat /etc/hostname`
|
||||
if [ -e $DEVICEBOOT$DIRECTORY/$TARGET/.control_boot_new_image ]; then
|
||||
echo "First start image - The first attempt to launch a new image... "; rm -f $DEVICEBOOT$DIRECTORY/$TARGET/.control_boot_new_image
|
||||
else
|
||||
if [ ! -e $DEVICEBOOT$DIRECTORY/$TARGET/.control_ok ] ; then
|
||||
if [ $BOXNAME = "vuultimo4k" ] || [ $BOXNAME = "vusolo4k" ] || [ $BOXNAME = "vuuno4kse" ] || [ $BOXNAME = "vuuno4k" ]; then
|
||||
if [ -d /proc/stb ] ; then
|
||||
echo " Install kernel image flash.... " $BOXNAME
|
||||
dd if=$DEVICEBOOT$UPLOAD/.kernel/flash-kernel-$VUMODEL.bin of=/dev/mmcblk0p1
|
||||
fi
|
||||
elif [ $BOXNAME = "vuzero4k" ] ; then
|
||||
if [ -d /proc/stb ] ; then
|
||||
echo " Install kernel image flash.... " $BOXNAME
|
||||
dd if=$DEVICEBOOT$UPLOAD/.kernel/flash-kernel-$VUMODEL.bin of=/dev/mmcblk0p4
|
||||
fi
|
||||
elif [ $BOXNAME = "vuduo4k" ] ; then
|
||||
if [ -d /proc/stb ] ; then
|
||||
echo " Install kernel image flash.... " $BOXNAME
|
||||
dd if=$DEVICEBOOT$UPLOAD/.kernel/flash-kernel-$VUMODEL.bin of=/dev/mmcblk0p6
|
||||
fi
|
||||
fi
|
||||
echo "Wrong kernel. Press number 3" > $DEVICEBOOT$UPLOAD/.kernel/used_flash_kernel
|
||||
ln -sfn /sbin/init.sysvinit /sbin/init
|
||||
echo "Flash " > $DEVICEBOOT$DIRECTORY/.neonextboot
|
||||
echo "Error - NeoBoot he can not run it image !!! "
|
||||
echo "Restart STB - Back to Flash... "
|
||||
sleep 5; reboot -f
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
######### test boot new image<<<<<
|
||||
|
||||
if [ -e $NEODEVICE$IMAGEKATALOG/$TARGET/usr/bin/enigma2_pre_start.sh ] ; then
|
||||
rm -f $NEODEVICE$IMAGEKATALOG/$TARGET/usr/bin/enigma2_pre_start.sh
|
||||
fi
|
||||
cp -f /usr/lib/enigma2/python/Plugins/Extensions/NeoBoot/files/mountpoint.sh $NEODEVICE$IMAGEKATALOG/$TARGET/usr/bin/enigma2_pre_start.sh
|
||||
|
||||
#mount $NEODEVICE /media/neoboot
|
||||
|
||||
if [ -e $NEODEVICE$IMAGEKATALOG/$TARGET/usr/bin/enigma2_pre_start.sh ] ; then
|
||||
#mount $NEODEVICE /media/neoboot
|
||||
if [ -e $NEODEVICE$IMAGEKATALOG/$TARGET/usr/bin/enigma2_pre_start.sh ] ; then
|
||||
orgimag=`mount | sed '/sd/!d' | cut -d" " -f1`
|
||||
for item in $orgimag; do
|
||||
ohdd=`echo $item | cut -d"/" -f3`
|
||||
@@ -126,14 +122,10 @@ else
|
||||
echo ok
|
||||
fi
|
||||
done
|
||||
fi
|
||||
|
||||
chmod 0755 $NEODEVICE$IMAGEKATALOG/$TARGET/usr/bin/enigma2_pre_start.sh
|
||||
#chattr -i $LOCATION$IMAGEBOOT/$TARGET/usr/bin/enigma2_pre_start.sh
|
||||
echo "NeoBOOT created the file mount enigma2_pre_start.sh "
|
||||
sleep 2
|
||||
|
||||
|
||||
fi
|
||||
chmod 0755 $NEODEVICE$IMAGEKATALOG/$TARGET/usr/bin/enigma2_pre_start.sh
|
||||
echo "NeoBOOT created the file mount enigma2_pre_start.sh "
|
||||
sleep 2
|
||||
fi
|
||||
|
||||
exit 0
|
||||
|
||||
Reference in New Issue
Block a user