5 dir=/dev/shm/snmp-topology/
6 test ! -d $dir && mkdir $dir
11 if [ ! -z "$2" ] ; then
13 test ! -d "$dir/$ext" && mkdir "$dir/$ext"
16 ( test ! -z "$1" && echo $1 || ./sw-names ) | xargs -i echo \
17 "test ! -e $dir/{} && " \
18 "snmpbulkwalk -OX -v2c -Cc -c $COMMUNITY {} IF-MIB::ifPhysAddress | tee -a $dir/{} && "\
19 "snmpbulkwalk -OX -v2c -Cc -c $COMMUNITY {} Q-BRIDGE-MIB::dot1qTpFdbPort | tee -a $dir/$ext{} || "\
20 "snmpbulkwalk -OX -v2c -Cc -c $COMMUNITY {} BRIDGE-MIB::dot1dTpFdbPort | tee -a $dir/{} " | sh -x