![]() |
|
|
|
|
|||||||
| Forums | Portal | Register | Rules & FAQ | Contribute | Members List | Arcade | Search | Today's Posts | Mark Forums Read |
| Shell Programming and Scripting Post questions about KSH, CSH, SH, BASH, PERL, PHP, SED, AWK and OTHER shell scripts here. |
|
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| AIX - Cant ping | Netghost | AIX | 1 | 10-03-2006 03:38 PM |
| Ping | sam70 | UNIX for Dummies Questions & Answers | 1 | 08-02-2005 09:56 PM |
| ping | csaunders | AIX | 1 | 04-24-2005 02:54 PM |
| ping | nemex | UNIX for Dummies Questions & Answers | 2 | 12-12-2002 02:08 AM |
| About Ping | S.Vishwanath | IP Networking | 4 | 11-09-2002 06:06 PM |
|
|
LinkBack | Thread Tools | Display Modes |
|
|||
|
I need a script that recieves an IP adress and a number of seconds as arguments. and display a massage if the IP replies or not.
|
| Forum Sponsor | ||
|
|
|
|||
|
Quote:
first I am asking for a script. and I need it to be run in tcsh shell. I tried to do one, but I always stuck in endless loop. so please help me. |
|
|||
|
Quote:
please reply as soosn as possible. |
|
|||
|
well first, post the script that you have already written. then we can go from there. very rarely will you find someone who has the time to write out a script for you, especially if you are not willing to write one out on your own. not only that, but it can be insulting asking people to do work for you. were here to help, not to do work for you.
|
|
|||
|
basically, all you would have to do is see the man page for ping.
Code:
ping -c $count -t $time_to_live $host_name so in the script that you are writing, you could first either assign $count whatever value you want, or ask for user input. this argument should be in there otherwise ping will go on for a while. take userinput for the -t flag and store it in $time_to_live and finally define the $host_name of the machine to be pinged. to take command line arguments with bash, go to tldp.org and search for the advanced bash shell scripting guide. |
|||
| Google UNIX.COM |