watch dueros, restart if pid_num less than 2

Change-Id: I48b8097908908dbc5ae2e784d960527cb3e4c95d
Signed-off-by: hertz.wang <wangh@rock-chips.com>
This commit is contained in:
hertz.wang
2018-08-27 11:51:43 +08:00
parent 8277126a79
commit da24018288

View File

@ -4,7 +4,7 @@ sleep 5
while true;do
pid_num=`pidof duer_linux alsa_audio_main_service | wc -w`
if [ $pid_num -ne 2 ] ;then
if [ $pid_num -lt 2 ] ;then
echo "duer_linux|alsa_audio_main_service died, restart it."
/oem/dueros_service.sh restart
fi