Skip to content

Commit

Permalink
debian: Avoid logrotate error if /var/run/openvswitch does not exist.
Browse files Browse the repository at this point in the history
Signed-off-by: Alfredo Finelli <[email protected]>
Signed-off-by: Ben Pfaff <[email protected]>
  • Loading branch information
Alfredo Finelli authored and blp committed Nov 12, 2013
1 parent 3a5ded9 commit 11bd0a5
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 3 deletions.
1 change: 1 addition & 0 deletions AUTHORS
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ Alexandru Copot [email protected]
Alexei Starovoitov [email protected]
Alexey I. Froloff [email protected]
Alex Wang [email protected]
Alfredo Finelli [email protected]
Andrew Evans [email protected]
Andrew Lambeth [email protected]
Andy Hill [email protected]
Expand Down
8 changes: 5 additions & 3 deletions debian/openvswitch-switch.logrotate
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,10 @@
rotate 30
postrotate
# Tell Open vSwitch daemons to reopen their log files
for pidfile in `cd /var/run/openvswitch && echo *.pid`; do
ovs-appctl -t "${pidfile%%.pid}" vlog/reopen
done
if [ -d /var/run/openvswitch ]; then
for pidfile in `cd /var/run/openvswitch && echo *.pid`; do
ovs-appctl -t "${pidfile%%.pid}" vlog/reopen
done
fi
endscript
}

0 comments on commit 11bd0a5

Please sign in to comment.