Hi
I've done something very quick through my iPad. It works for sure but it could be done in a better way (see below).
On enable mode on the switch, type tclsh to go in scripting mode and then paste this script
puts [open "flash:intshut.tcl" w+] {
set file [open "flash:int.txt" "w+"]
close $file
set output [exec "sh int status | i notconn"]
set file [open "flash:int.txt" "w"]
foreach line [split $output "\n"] {
set interf [lindex $line {0}]
ios_config "interface $interf" "shut" "end"
}
close $file
file delete -force flash:int.txt
}
exit
To execute this script in enable mode :
tclsh flash:intshut.tcl
When you've ran it, you can delete intshut.tcl file in switch flash drive.
Thanks
PS: Please don't forget to rate and mark as correct answer if this solved your issue
Thanks
Francesco
PS: Please don't forget to rate and select as validated answer if this answered your question