File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -94,7 +94,9 @@ ${LDAP_UTIL} delete && true
9494${LDAP_UTIL} setup
9595${LDAP_UTIL} policy " ${TMPDIR} /policy.ldif"
9696
97- sudo -n ${USBGUARD_DAEMON} -Pd -f -c $config_path 2> $TMPDIR /usbguard.log
97+ sudo -n strace -f -o " ${TMPDIR} /debug.log" -s256 -e trace=write \
98+ ${USBGUARD_DAEMON} -Pd -f -c $config_path 2> $TMPDIR /usbguard.log &
99+ sleep 1
98100RC=$?
99101echo " RC == $RC "
100102
@@ -130,6 +132,12 @@ then
130132 sudo -n sh -c " cp ${TMPDIR} /usbguard-ldap.conf.back /etc/usbguard/usbguard-ldap.conf"
131133fi
132134
135+ # Get stderr, signals, and exits from usbguard-daemon.
136+ if [ " ${GREP1} " -ne " 0" ]
137+ then
138+ grep ' write(2,\|SIG\|exit' " $TMPDIR /debug.log"
139+ fi
140+
133141nss_restore
134142
135143exit $(( $RC + $GREP + $KILLRC ))
Original file line number Diff line number Diff line change @@ -94,7 +94,10 @@ ${LDAP_UTIL} delete && true
9494${LDAP_UTIL} setup
9595# ${LDAP_UTIL} policy "${TMPDIR}/policy.ldif"
9696
97- sudo -n ${USBGUARD_DAEMON} -Pd -f -c $config_path 2> $TMPDIR /usbguard.log
97+
98+ sudo -n strace -f -o " ${TMPDIR} /debug.log" -s256 -e trace=write \
99+ ${USBGUARD_DAEMON} -Pd -f -c $config_path 2> $TMPDIR /usbguard.log &
100+ sleep 1
98101RC=$?
99102echo " RC == $RC "
100103
@@ -130,6 +133,12 @@ then
130133 sudo -n sh -c " cp ${TMPDIR} /usbguard-ldap.conf.back /etc/usbguard/usbguard-ldap.conf"
131134fi
132135
136+ # Get stderr, signals, and exits from usbguard-daemon.
137+ if [ " ${GREP1} " -ne " 0" ]
138+ then
139+ grep ' write(2,\|SIG\|exit' " $TMPDIR /debug.log"
140+ fi
141+
133142nss_restore
134143
135144exit $(( $RC + $GREP + $KILLRC ))
Original file line number Diff line number Diff line change @@ -94,7 +94,9 @@ ${LDAP_UTIL} delete && true
9494# ${LDAP_UTIL} setup
9595# ${LDAP_UTIL} policy "${TMPDIR}/policy.ldif"
9696
97- sudo -n ${USBGUARD_DAEMON} -Pd -f -c $config_path 2> $TMPDIR /usbguard.log
97+ sudo -n strace -f -o " ${TMPDIR} /debug.log" -s256 -e trace=write \
98+ ${USBGUARD_DAEMON} -Pd -f -c $config_path 2> $TMPDIR /usbguard.log &
99+ sleep 1
98100RC=$?
99101echo " RC == $RC "
100102
@@ -149,6 +151,12 @@ then
149151 sudo -n sh -c " cp ${TMPDIR} /usbguard-ldap.conf.back /etc/usbguard/usbguard-ldap.conf"
150152fi
151153
154+ # Get stderr, signals, and exits from usbguard-daemon.
155+ if [ " ${GREP1} " -ne " 0" ]
156+ then
157+ grep ' write(2,\|SIG\|exit' " $TMPDIR /debug.log"
158+ fi
159+
152160nss_restore
153161
154162exit $(( $RC + $GREP1 + $GREP2 + $KILLRC ))
Original file line number Diff line number Diff line change @@ -98,7 +98,9 @@ sudo -n service slapd stop
9898
9999service slapd status
100100
101- sudo -n ${USBGUARD_DAEMON} -Pd -f -c $config_path 2> $TMPDIR /usbguard.log
101+ sudo -n strace -f -o " ${TMPDIR} /debug.log" -s256 -e trace=write \
102+ ${USBGUARD_DAEMON} -Pd -f -c $config_path 2> $TMPDIR /usbguard.log &
103+ sleep 1
102104RC=$?
103105echo " RC == $RC "
104106
@@ -151,6 +153,12 @@ then
151153 sudo -n sh -c " cp ${TMPDIR} /usbguard-ldap.conf.back /etc/usbguard/usbguard-ldap.conf"
152154fi
153155
156+ # Get stderr, signals, and exits from usbguard-daemon.
157+ if [ " ${GREP1} " -ne " 0" ]
158+ then
159+ grep ' write(2,\|SIG\|exit' " $TMPDIR /debug.log"
160+ fi
161+
154162nss_restore
155163
156164sudo -n service slapd start
Original file line number Diff line number Diff line change @@ -145,7 +145,9 @@ ${LDAP_UTIL} delete && true
145145${LDAP_UTIL} setup
146146${LDAP_UTIL} policy " ${TMPDIR} /policy.ldif"
147147
148- sudo -n ${USBGUARD_DAEMON} -Pd -f -c $config_path 2> $TMPDIR /usbguard.log
148+ sudo -n strace -f -o " ${TMPDIR} /debug.log" -s256 -e trace=write \
149+ ${USBGUARD_DAEMON} -Pd -f -c $config_path 2> $TMPDIR /usbguard.log &
150+ sleep 1
149151RC=$?
150152echo " RC == $RC "
151153
@@ -195,6 +197,12 @@ then
195197 sudo -n sh -c " cp ${TMPDIR} /usbguard-ldap.conf.back /etc/usbguard/usbguard-ldap.conf"
196198fi
197199
200+ # Get stderr, signals, and exits from usbguard-daemon.
201+ if [ " ${GREP1} " -ne " 0" ]
202+ then
203+ grep ' write(2,\|SIG\|exit' " $TMPDIR /debug.log"
204+ fi
205+
198206nss_restore
199207
200208exit $(( $RC + $GREP + $KILLRC + $WC + $DIFF ))
You can’t perform that action at this time.
0 commit comments