#!/bin/sh if [ $# -lt 2 ]; then echo Usage snmproute router commstring exit 254 fi for r in `snmpwalk -O v -v 1 -c $2 $1 ip.ipRouteTable.ipRouteEntry.ipRouteDest|cut -d: -f2 ` do h=`snmpget -O v -v 1 -c $2 $1 ip.ipRouteTable.ipRouteEntry.ipRouteNextHop.$r|cut -d: -f2` echo $r $h done |
Essential Navigational Toolset | ||
---|---|---|
Back | Index | Forth |