From: gwendel@gregw.biz
Date: Mon Jan 15 2007 - 01:51:03 ART
When using dynamips I have trouble running the script to gather ip
addresses so I went to the file system itself to grab the data.
I am able to ping using tclsh on dynamips without issue so all I need is a
way to get all of the IP addresses.
Here is a partial script I run to gather IP addresses in dynamips running
on linux.
stop the dynamips processes (just in case)
cd to the working directory specified in my dynagen file
run following command to gather all ip addresses on all routers.
strings *nvram | egrep "^ ip address"
(note the space before ip address)
Here is an example of the output
[root@DYNAMIPS working]# strings *nvram | egrep "^ ip address"
ip address 112.0.0.1 255.0.0.0
ip address 113.0.0.1 255.0.0.0
ip address 114.0.0.1 255.0.0.0
ip address 115.0.0.1 255.0.0.0
ip address 116.0.0.1 255.0.0.0
ip address 117.0.0.1 255.0.0.0
All I need to do now is write a simple perl script to get this in a final
output with out any manual manipulation.
Thanks
Greg Wendel
This archive was generated by hypermail 2.1.4 : Thu Feb 08 2007 - 23:46:56 ART