Skip to content
Snippets Groups Projects
Commit 279841ac authored by Tommaso Chiarusi BO's avatar Tommaso Chiarusi BO
Browse files

Initial commit

parents
No related branches found
No related tags found
No related merge requests found
Showing
with 162 additions and 0 deletions
#!/bin/bash
tmp_file=clear_counters.txt
cat>${tmp_file}<<EOF
admin
trentatretrentini33
ena
configure terminal
mac address-table static 00:0F:53:20:66:CC vlan 1 interface tengigabitethernet 1/0/1
exit
write
y
exit
EOF
co="1"
while [ $co -le 9 ]
echo "-----> DFES"${co}
do
cat ${tmp_file} | nc sw-dfes${co} 23
co=$[$co+1]
#let co=co+1
echo " "
done
rm -f ${tmp_file}
#!/bin/bash
tmp_file=clear_counters.txt
cat>${tmp_file}<<EOF
admin
trentatretrentini33
ena
show spanning-tree summary
configure
no spanning-tree
exit
write
y
exit
EOF
co="1"
while [ $co -le 9 ]
echo "-----> DFES"${co}
do
cat ${tmp_file} | nc sw-dfes${co} 23
co=$[$co+1]
echo " "
done
rm -f ${tmp_file}
#!/bin/bash
tmp_file=clear_counters.txt
cat>${tmp_file}<<EOF
admin
trentatretrentini33
ena
clear counters
y
exit
exit
EOF
co="1"
while [ $co -le 9 ]
do
cat ${tmp_file} | nc sw-dfes${co} 23
co=$[$co+1]
echo " "
done
rm -f ${tmp_file}
#!/bin/bash
tmp_file=clear_counters.txt
cat>${tmp_file}<<EOF
admin
trentatretrentini33
ena
show spanning-tree summary
configure
no spanning-tree
exit
write
y
exit
EOF
co="1"
while [ $co -le 9 ]
echo "-----> DFES"${co}
do
cat ${tmp_file} | nc sw-dfes${co} 23
co=$[$co+1]
echo " "
done
rm -f ${tmp_file}
#!/bin/bash
tmp_file=sfp.txt
cat>${tmp_file}<<EOF
admin
trentatretrentini33
ena
show fiber-ports optical-transceiver
exit
exit
EOF
co="1"
while [ $co -le 9 ]
do
cat ${tmp_file} | nc sw-dfes${co} 23 | grep Gi -B6
co=$[$co+1]
echo " "
done
rm -f ${tmp_file}
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
exit
admin
trentatretrentini33
ena
show clock
exit
This diff is collapsed.
#!/bin/bash
tmp_file=deleteme
cat>${tmp_file}<<EOF
"{\"unit\": \"dBm\", \"value\": -28, \"kind\":\"parameter\", \"description\":\"\", \"type\":\"test\"}
EOF
cat ${tmp_file}| nc "pi1241.physik.uni-erlangen.de" 9999
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment