Encerrado

Cloud machine bash script

Any body can give me suggestion, how to make the virtual system explicitly down/unreachable for 10 second in everyone minute so that I can fetch the appropriate logs (I am using a bash script)

Deliverables

#!/bin/bash

set -x

URL=[login to view URL]

while true; do

now=$(TZ=utc date -Iseconds)

#wget $URL -q -O /dev/null

nc -z -n -v [login to view URL] 9022 2>&1 > /dev/null

if [[ "$?" -eq "0" ]]

then

echo $now SUCCESS >> [login to view URL]

else

echo $now FAIL >> [login to view URL]

fi

echo "$(tail -60 [login to view URL])" > [login to view URL]

wc -l [login to view URL]

sleep 5

done

Habilidades: Linux, Shell Script, Bash Scripting

Veja mais: best bash script, unix ftp bash script, mutt bash script, common bash script admin task, bash script set proxy, sendmail bash script, unit testing bash script, bash script website clicks, bash script query mysql database, bash script login webiste, file parsing bash script, parse using bash script find average, bash script check web page, script outlook text body, bash script find ftp folder existing, bash script date, bash script update date, formatting date bash script, bash script current date time

Acerca do Empregador:
( 1 comentário ) Băilești, Romania

ID do Projeto: #29457878

5 freelancers estão ofertando em média $34 nesse trabalho

JVMHost

Hi, If you can manage the VM and have access to host node and the VM filesystem is on LVM then you can use LVM snapshot and copy the logs without any downtime to the VM. I can script grabiing logs from snapshot.

$40 USD em 1 dia
(27 Comentários)
4.4
(0 Comentários)
0.0
freaghill94

Hello there! I saw your post and I am more then certain that I would be a great fit for this job. I would need a copy of your Virtual Machine, or a documentation about what exactly you are trying to stop start and fe Mais

$30 USD in 7 dias
(0 Comentários)
0.0
chriscar2

Hi there, It is possible to perform repetitive tasks with cron, see if it solves your problem: [login to view URL]

$30 USD em 1 dia
(0 Comentários)
0.0
osmancnr

bro you can use ping/nc command and while you can ping every 2-3 seconds and You can easily catch it when there is no response 2-3 times. if you can't I can help you for 3-4 dollars send me a message or reach me on my Mais

$30 USD em 1 dia
(0 Comentários)
0.0