View Single Post

  #1 (permalink)  
Old 06-12-2008, 12:34 AM
sanjus sanjus is offline
Junior Member
User
 
Join Date: Jun 2008
My distro: Debian
Posts: 2
Rep Power: 0
sanjus is on a distinguished road
Default Check file exists on Remote Server

Hello There,

Kind of a newbie to shell scripting - need some help.

I need some help with shell script to check if the remote server is up & running (i guess i need to use ping) and to check if a particular file (say /home/<user-name>/somefile.txt) exists.

If any of the above 2 conditions are not met then i need to terminate/abort the script.

TIA for all your help,

regards,
sanju
Reply With Quote