mirror of
https://github.com/motioneye-project/motioneyeos.git
synced 2025-07-27 05:06:39 +00:00
Show OS info to console when booting and shutting down
This commit is contained in:
parent
5bee97e17f
commit
a614df3f41
@ -5,7 +5,8 @@ PID_FILE=/tmp/rc.pid
|
|||||||
|
|
||||||
source /etc/init.d/base
|
source /etc/init.d/base
|
||||||
|
|
||||||
echo "---- shutting down ${OS_NAME} ${OS_VERSION} ----" >> ${BOOT_LOG}
|
echo
|
||||||
|
echo "---- shutting down ${OS_NAME} ${OS_VERSION} ----" | tee -a ${BOOT_LOG}
|
||||||
|
|
||||||
# stop all init scripts in /etc/init.d,
|
# stop all init scripts in /etc/init.d,
|
||||||
# executing them in reverse numerical order.
|
# executing them in reverse numerical order.
|
||||||
@ -19,4 +20,3 @@ pid=$(cat ${PID_FILE})
|
|||||||
while kill -0 ${pid} 2>/dev/null; do
|
while kill -0 ${pid} 2>/dev/null; do
|
||||||
sleep 1
|
sleep 1
|
||||||
done
|
done
|
||||||
|
|
||||||
|
@ -12,7 +12,7 @@ set +a
|
|||||||
|
|
||||||
source /etc/init.d/base
|
source /etc/init.d/base
|
||||||
|
|
||||||
echo "---- booting ${OS_NAME} ${OS_VERSION} ----" >> ${TMP_BOOT_LOG}
|
echo "---- booting ${OS_NAME} ${OS_VERSION} ----" | tee -a ${TMP_BOOT_LOG}
|
||||||
|
|
||||||
# start all init scripts in /etc/init.d,
|
# start all init scripts in /etc/init.d,
|
||||||
# executing them in numerical order.
|
# executing them in numerical order.
|
||||||
@ -28,4 +28,3 @@ while kill -0 ${pid} 2>/dev/null; do
|
|||||||
done
|
done
|
||||||
|
|
||||||
test -d $(dirname ${BOOT_LOG}) && cat ${TMP_BOOT_LOG} >> ${BOOT_LOG}
|
test -d $(dirname ${BOOT_LOG}) && cat ${TMP_BOOT_LOG} >> ${BOOT_LOG}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user