cancel
Showing results for 
Search instead for 
Did you mean: 

Ping sweep / range of IPs in the same subnet

Ping sweep / range of IPs in the same subnet

Russ
Contributor

Hi, how can I ping a subnet or run a file (script) that has all the ip’s I need to ping. On some Cisco devices there is the extended ping where you can ping an entire subnet, or even run a script which would run each command sequentially but I can’t see a like option on a VDX6740T.

5 REPLIES 5

Russ
Contributor

Thanks again Michael - I’ve inherited these switches where documenting accounts is an after thought. What’s the default root user password. do you know?

Michael_Morey
Extreme Employee

 As for logging is as root, I’ve not done that before (new to this platform), it’s as simple as ssh’g to the device and using root credentials?

 

Yes, simply login remotely and provide the root credentials to login.

 

I need to include a vrf in the command, so it would look something like this? 

for i in $(seq 1 254); do ping 192.168.1.$i -c1 vrf vrf_name; done

 

This is a little more complicated.  By default when you login as root, you are in the VRF “mgmt-vrf”.  In the PING utility there is no option for “vrf vrf_name”, however you can use the -F flag and use the VRFid Number to send a ping across a different VRF.  To check the VRF Name <> Number mapping do the following:

VDX1:FID128:root> noscli

Static-Lab-SM08_VDX1# show vrf
Total number of VRFs configured: 3
VrfName VrfId V4-Ucast V6-Ucast
default-vrf 1 Enabled Enabled
mgmt-vrf 0 Enabled Enabled
orange 2 Enabled -

VDX1# exit

VDX1:FID128:root> ping 3.0.0.2 -F 1
PING 3.0.0.2 (3.0.0.2): 56 data bytes
64 bytes from 3.0.0.2: icmp_seq=0 ttl=64 time=1.460 ms
64 bytes from 3.0.0.2: icmp_seq=1 ttl=64 time=1.420 ms
64 bytes from 3.0.0.2: icmp_seq=2 ttl=64 time=1.395 ms
64 bytes from 3.0.0.2: icmp_seq=3 ttl=64 time=1.397 ms
64 bytes from 3.0.0.2: icmp_seq=4 ttl=64 time=1.566 ms
^C--- 3.0.0.2 ping statistics ---
5 packets transmitted, 5 packets received, 0% packet loss
round-trip min/avg/max/stddev = 1.395/1.448/1.566/0.064 ms

Without specifying the VRF number, ping fails:

VDX1:FID128:root> ping 3.0.0.2
PING 3.0.0.2 (3.0.0.2): 56 data bytes
^C--- 3.0.0.2 ping statistics ---
5 packets transmitted, 0 packets received, 100% packet loss

So all together the command would look like:

for i in $(seq 1 254); do ping 192.168.1.$i -c1 -F VRF_ID_NUMBER; done

 

Michael Morey
Principal Technical Support Engineer
Extreme Networks

Hi, How can I get into the noscli? I know how to enter the foscmd, but doesn't appear to give the same interface/option. 

What about python? I've taken a brief look at the python CLI, tried to built a script, but bc there's no documentation (at least I can find) on how to drive python on these switches I come up empty! 

Russ
Contributor

Thanks Michael this looks like a very good workaround and would solve my problem.

I need to include a vrf in the command, so it would look something like this? As for logging is as root, I’ve not done that before (new to this platform), it’s as simple as ssh’g to the device and using root credentials?

for i in $(seq 1 254); do ping 192.168.1.$i -c1 vrf vrf_name; done 

 

GTM-P2G8KFN