If you are like me and just need to know how to switch spanning-tree protocol on or off and struggle to google simple answer, I hope you found this article.
Connect to cli. You can find out if spanning-tree protocol is enabled or disabled by using this command:
show span
Enable STP
config spanning-tree write-memory
Disable STP
config no spanning-tree write-memory