gpt-2741gnac_root_files/_mtdblock5.img.extracted/squashfs-root/usr/script/syslogd.sh
2023-11-26 03:26:24 -03:00

30 lines
No EOL
509 B
Bash
Executable file

#!/bin/sh
SL_CONF=/etc/syslog.conf
if [ -f $SL_CONF ] ; then
chmod +x $SL_CONF
. $SL_CONF
else
exit 0
fi
logMode=$Mode
servIP=$ServerIP
servPort=$ServerPort
remoteSeverity=$RemoteSeverity
if [ "$logMode" = "Local" ] ; then
/sbin/syslogd -n -s 126 -b 3 -L &
/sbin/klogd -n &
else
if [ $remoteSeverity != "" ] ; then
/sbin/syslogd -n -s 126 -b 3 -L -R $ServerIP -P $ServerPort -r $RemoteSeverity &
else
/sbin/syslogd -n -s 126 -b 3 -L -R $ServerIP -P $ServerPort &
fi
/sbin/klogd -n &
fi