From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 5064 invoked from network); 4 Mar 1997 12:27:41 -0000 Received: from euclid.skiles.gatech.edu (list@130.207.146.50) by coral.primenet.com.au with SMTP; 4 Mar 1997 12:27:41 -0000 Received: (from list@localhost) by euclid.skiles.gatech.edu (8.7.3/8.7.3) id HAA21187; Tue, 4 Mar 1997 07:17:28 -0500 (EST) Resent-Date: Tue, 4 Mar 1997 07:16:33 -0500 (EST) From: gwing@primenet.com.au Message-ID: <19970304121857.5002.qmail@primenet.com.au> Subject: Re: Is this possible/easy? In-Reply-To: <199703031606.LAA05312@gypsy.cad.gatech.edu> from Jason Price at "Mar 3, 97 11:06:50 am" To: gt5076c@cad.gatech.edu (Jason Price) Date: Tue, 4 Mar 1997 23:18:56 +1100 (EST) Cc: zsh-users@math.gatech.edu X-Mailer: ELM [version 2.4ME+ PL31 (25)] MIME-Version: 1.0 Content-Type: application/pgp; format=text; x-action=sign Content-Transfer-Encoding: 7bit Resent-Message-ID: <"3ZtgR.0.485.WA17p"@euclid> Resent-From: zsh-users@math.gatech.edu X-Mailing-List: archive/latest/746 X-Loop: zsh-users@math.gatech.edu X-Loop: zsh-workers@math.gatech.edu Precedence: list Resent-Sender: zsh-workers-request@math.gatech.edu -----BEGIN PGP SIGNED MESSAGE----- Jason Price wrote: :I need to generate a script to ping all the IP addresses in a couple :of class C's. (So we can double check our records, and see which are :in use) Is there a way to generate this easilly? Even something to :list them all out, and redirect the output would be enough. : :Something like : :150.150.150.0 :150.150.150.1 :150.150.150.2 :... :150.150.150.255 Of course, there are stacks of ways to do it. In addition to those previously mentioned you could do % I=1; while ( [[ $I -le 255 ]] ) ; do ping -c 2 150.150.150.$I; let I++; done or a for() loop would be easy. - -- Geoff Wing [mason@primenet.com.au] Technical Manager Phone : +61-3-9818 2977 PrimeNet - Internet Consultancy Facsimile: +61-3-9819 3788 Web : Mobile : 0412 162 441 -----BEGIN PGP SIGNATURE----- Version: 2.6.3ia Charset: noconv iQCVAwUBMxwTL+kZdFsUTaLFAQHcxQP/aqmMH/lfYCSOZaPNVEEhDMJoB8whBN09 NZRa/3VFqwmVDJtgakx26BmzPVIkVn3hb854+G3nRo261YcEQgwHeHe9aeD7ttUV EBy8aqJA0uSWATydgCmyrH+4yG87d3B8hdJ2H5JMJzuTlizwnO6r/rA7/rNbLY77 985EwXbFats= =mjGw -----END PGP SIGNATURE-----