Actions
Bug #8172
closedPatch to make ping_hosts.sh faster and avoid carp deadlock
Start date:
12/07/2017
Due date:
% Done:
100%
Estimated time:
Plus Target Version:
Release Notes:
Affected Version:
All
Affected Architecture:
All
Description
In /usr/local/bin/ping_hosts.sh we have
..
..
- Read in ipsec ping hosts and check the CARP status
if [ -f /var/db/ipsecpinghosts ]; then
IPSECHOSTS="/var/db/ipsecpinghosts"
CURRENTIPSECHOSTS="/var/db/currentipsecpinghosts"
IFVPNSTATE=`ifconfig $IFVPN | grep "carp: BACKUP vhid" | wc -l`
Please change that to
- Read in ipsec ping hosts and check the CARP status
if [ -f /var/db/ipsecpinghosts && -s /var/db/ipsecpinghosts ]; then
...
Because /var/db/ipsecpinghosts seems to get written by the gui at 0 bytes whether we use ipsec or not.
Which causes the pinger to run ifconfig, which waits on a lock, which I think participates in a deadlock situation.
And, even if it doesn't, there's no point in running a bunch of ifconfig commands when the file exists and is size 0.
Actions