mirror of
https://gitlab.com/netravnen/NetworkLabNotes.git
synced 2024-11-26 19:27:57 +00:00
27 lines
510 B
Plaintext
27 lines
510 B
Plaintext
tclsh
|
|
puts [ open "flash:reset.tcl" w+ ] {
|
|
|
|
puts "Erasing Configuration"
|
|
typeahead "r"
|
|
|
|
puts [ exec "write erase" ]
|
|
puts "Erasing VLAN Database"
|
|
typeahead "r"
|
|
|
|
puts [ exec "del flash:vlan.dat" ]
|
|
puts "Copying Base Configuration To Startup"
|
|
typeahead "r"
|
|
|
|
puts [ ios_config "sdm prefer lanbase-routing" ]
|
|
puts "Changing prefered sdm to lanbase-routing"
|
|
typeahead "r"
|
|
|
|
puts [ exec "copy flash:base.cfg nvram:startup-config" ]
|
|
puts "Reloading the layer 2 switch"
|
|
typeahead "r"
|
|
|
|
puts [ exec "reload" ]
|
|
}
|
|
}
|
|
tclquit
|