Skip to content

Commit 9fa7cf3

Browse files
committed
Added bbb-record --clean to clean out process and publish log files for recordings
1 parent bcafbc6 commit 9fa7cf3

File tree

1 file changed

+19
-1
lines changed

1 file changed

+19
-1
lines changed

bigbluebutton-config/bin/bbb-record

Lines changed: 19 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -123,8 +123,10 @@ usage() {
123123
echo
124124
echo "Monitoring:"
125125
echo " --watch Watch processing of recordings"
126+
echo
127+
echo "Administration:"
126128
echo " --rebuild [meetingID] rebuild the output for meetingID"
127-
echo " --republish [meetingID] republish the recording for meetingID"
129+
echo " --republish [meetingID] republish the recording for meetingID"
128130
echo " --delete [meetingID] delete one meeting and recording"
129131
echo " --deletall delete all meetings and recordings"
130132
echo " --debug check for recording errors"
@@ -208,6 +210,13 @@ while [ $# -gt 0 ]; do
208210
continue
209211
fi
210212

213+
if [ "$1" = "-clean" -o "$1" = "--clean" ]; then
214+
need_root
215+
CLEAN=1
216+
shift
217+
continue
218+
fi
219+
211220
usage
212221
exit 1
213222
done
@@ -242,6 +251,15 @@ if [ $REPUBLISH ]; then
242251
fi
243252
fi
244253

254+
if [ $CLEAN ]; then
255+
sudo /etc/init.d/bbb-record-core stop
256+
for type in $TYPES; do
257+
echo " clearning logs in /var/log/bigbluebutton/$type"
258+
find /var/log/bigbluebutton/$type -name "*.log" -exec sudo rm '{}' \;
259+
done
260+
sudo /etc/init.d/bbb-record-core start
261+
fi
262+
245263
if [ $DELETE ]; then
246264
if [ ! -z "$MEETING_ID" ]; then
247265
for type in $TYPES; do

0 commit comments

Comments
 (0)