Sponsored Content
Homework and Emergencies Homework & Coursework Questions Track availability of computers Post 302425582 by pseudocoder on Friday 28th of May 2010 01:48:53 PM
Old 05-28-2010
Quote:
Originally Posted by petel1
i have a question, what does the: -c2 switch do
...
the 2 means two packets transmitted right, what if i type 3 ?
-c count
Stop after sending (and receiving) count ECHO_RESPONSE packets.
If this option is not specified, ping will operate until inter-
rupted. If this option is specified in conjunction with ping
sweeps, each sweep will consist of count packets.

If you type 3, then ping will obviously send 3 echo_response packets.
Simply try to manually run this command and you will immediately know what it does.

Quote:
Originally Posted by petel1
and: >/dev/null ?
It simply prevents all that ping output to be shown on the terminal.
Try to remove it, and you will see the difference.

Quote:
Originally Posted by petel1
how does this: done < "$1" work?
Thats the argument you submit with this script, namely the file with computer names/ip's.
When you run this script like ./script computerlist.txt the $1 will become computerlist.txt
This User Gave Thanks to pseudocoder For This Post:
 

7 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

two computers - one modem

I have two mashines with RedHat 8.0......they connected with cross over cabel...I want use both mashines for Internet, but modem has only first computer... Maybe..through gateway ?.... What must i do for it ?...... sorry for my terrible english.... (3 Replies)
Discussion started by: Pennywize
3 Replies

2. IP Networking

two computers one internet

i have a computer (sempron 2200+) with Suse 9.3 and another computer with windows 98 (PI 233 Mhz). I'm connect first computer (with Suse) on the Internet through ethernet but second computers in not connect. How can connect second computers on the internet (with 3 network card...two on the first... (8 Replies)
Discussion started by: dragos
8 Replies

3. UNIX for Dummies Questions & Answers

Possible to track FTP user last login? Last and Finger don't track them.

Like the topic says, does anyone know if it is possible to check to see when an FTP only user has logged in? Because the shell is /bin/false and they are only using FTP to access the system doing a "finger" or "last" it says they have never logged in. Is there a way to see when ftp users log in... (1 Reply)
Discussion started by: LordJezo
1 Replies

4. UNIX for Advanced & Expert Users

Using other computers for processing

Hello I've wrote a C++ program which does some mathematical calculations, but the problem is that it takes way too long on any computer to finish. Is there anyway to make more than 1 computer do the processing so it can process faster? (5 Replies)
Discussion started by: arya6000
5 Replies

5. UNIX for Dummies Questions & Answers

Communicating Via Terminals With Other Computers

Hello, I would like to know if it is possible to communicate between two terminals on seperate computers for free - e.g. not using proprietary software or using the built in UNIX terminals on operating systems of the UNIX flavor. Thanks, photray94 (2 Replies)
Discussion started by: photray94
2 Replies

6. What is on Your Mind?

How Many Computers Do You Have At Home?

Here is an easy one. Count the number of desktops and servers you have running at home, including your home office if you have one. Don't count those that are in storage or you rarely use, count the ones that are powered on most, if not all, of the day (and night). (86 Replies)
Discussion started by: Neo
86 Replies

7. Solaris

Rcp between 2 computers

Hi, I need to rcp heavy files between 2 solaris 10/sparc M3000 computers. Currently theses 2 computers are linked via a switch/firewall and the rcp commands take a very long time, I have been told that this is because of the firewall (old one). I asked my client to by a cross ethernet cable and... (2 Replies)
Discussion started by: zionassedo
2 Replies
ping(8) 						      System Manager's Manual							   ping(8)

Name
       ping - send ICMP ECHO_REQUEST packets to network hosts

Syntax
       /etc/ping [ options ] host [ datasize [ npackets ]]

Description
       The  DARPA  Internet  is  a large and complex network of hardware connected together by gateways.  The command utilizes the ICMP protocol's
       mandatory ECHO_REQUEST datagram to elicit an ICMP ECHO_RESPONSE from a host or gateway.	ECHO_REQUEST datagrams (pings) have an IP and ICMP
       header,	followed  by  a  struct timeval, and then an arbitrary number of pad bytes used to fill out the packet.  The length of the default
       datagram 64 bytes, but this may be changed using the command-line option.

       Typing ``ping host'' without any options will either report ``host is alive'' or ``no answer from host''.  To get more statistics  use  the
       -l option or one of the other options.

       When  using  for  fault	isolation,  it should first be run on the local host to verify that the local network interface is up and running.
       Then, hosts and gateways further and further away should be pinged.  The command with options sends one datagram per second and prints  one
       line  of  output  for every ECHO_RESPONSE returned.  No output is produced if there is no response.  If an optional npackets is given, only
       that number of requests is sent.  Round-trip times and packet loss statistics are computed.  When all responses have been received  or  the
       program times out with npackets specified, or if the program is terminated with a SIGINT, a brief summary is displayed.

Options
       -d   Turns on SO_DEBUG flag on the socket.

       -l   Gives more statistics than if is used without options.  Long output.

       -r   Bypasses  the  normal  routing  tables and sends directly to a host on an attached network.  If the host is not on a directly-attached
	    network, an error is returned.  This option can be used to ping a local host through an interface that has no route through  it.   For
	    example, after the interface was dropped by

       -v   Lists ICMP packets other than ECHO RESPONSE that are received. Verbose output.

Restrictions
       This  program is intended for use in network testing, measurement, and management.  It should be used primarily for manual fault isolation.
       Because of the load it could impose on the network, it is unwise to use during normal operations or from automated scripts.

See Also
       netstat(1), ifconfig(8c)

																	   ping(8)
All times are GMT -4. The time now is 11:57 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy