netgviz project page

What it is?

netgviz is a set of scripts that allows you to easily make graphs illustrating layouts of computer networks at ISO/OSI layer 3. It parses a text file with a list of network nodes with their addresses and generates the data in dot format, which is suitable for a Graphviz set of tools. You can then use Graphviz to draw a graph illustrating the network topology.

Currently it only supports graphing of IPv4 networks - it doesn't understand IPv6 and other network protocols.

netgviz consists of theese Perl scripts:

net2dot
parses data in net format and generates graph data in dot format
cisco2net
converts Cisco router configs to net format

Example

Create a file network.net containing a list of your network nodes, like this:

# routers

host r1 ip 10.0.0.1/24
host r1 label core router
host r1 ip 192.168.0.1/24
host r1 ip 172.21.100.1/30
host r2 ip 172.21.100.2/30
host r2 label Internet gateway

# DMZ nodes

host zeus ip 10.0.0.2/24
host zeus label NFS content server
host mx ip 10.0.0.3/24
host mx label mail and news server
host web1 ip 10.0.0.4/24
host web2 ip 10.0.0.5/24
host backend ip 10.0.0.6/24
host backend label SQL server
net 10.0.0.0/24 DMZ

# LAN nodes

host fshare ip 192.168.0.4/24
host fshare label fileserver
host ws1 ip 192.168.0.21/24
host ws2 ip 192.168.0.22/24
host ws3 ip 192.168.0.23/24
host ws4 ip 192.168.0.24/24
net 192.168.0.0/24 LAN

Then parse it through net2dot and fdp from Graphviz suite:
./net2dot network.net | neato -Elen=1.4 -Tpng -o network.png

The result:
network graph

Requirements

netgviz needs some software to be installed on your system:

Download

netgviz-0.2.tar.gz - current version, released 2007-05-26
netgviz-0.1.tar.gz - released 2007-05-02

Author

Michał Miszewski <m.miszewskigmail.com>

Feedback

If you found this software useful, please let me know. Bug reports and feature requests are welcome. When reporting bugs, please describe them well and provide the simplest netfile that reproduces the problem.

License

All scripts are free software; you can redistribute and/or modify them under the terms of the GNU General Public License version 2 as published by the Free Software Foundation.