refs #1161 adds attemps of pings in getNetworking loop

lgromero-tests
Luis Gerardo Romero Garcia 2024-11-19 10:33:37 +01:00
parent d720a057fc
commit 83a015e571
1 changed files with 4 additions and 0 deletions

View File

@ -82,10 +82,14 @@ mountroot ()
[ $? == 0 ] && sh || echo " "
if [ -n "$oglive" ]
then
attempts=0
while !(ping -c 1 $oglive &> /dev/null)
do
attempts=$((attempts+1))
echo "Attempt $attempts: Waiting for network connection... attempting to ping $oglive"
ogConfigureNetworking
done
echo "Connection established after $attempts attempts."
fi
log_success_msg "config networking"
ogConfigureLoopback