aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2014-12-23Don't catch all the exceptions for now - debugging...Steve McIntyre
Change-Id: Ic98e802fae172d1af202e0e09f67c548cb307d6a
2014-12-23More tweaks to auto_import_switch() after testing:Steve McIntyre
More debug on the daemon side Cope with different VLAN setups for trunk ports We can't use set_port_mode() - add trunk ports by hand here Change-Id: Id8e001f5cf5f8a40cb4e4f88a9f1241aaf77f323
2014-12-23Loosen up the parsing on paged outputSteve McIntyre
Change-Id: Ib8f65ada905a67738511ab7311cf1dcc8a8d0c42
2014-12-23Handle switch comms betterSteve McIntyre
Change-Id: Icf12cd4238402c84615a2e6d3b3b357d4fef5c54
2014-12-23The detault VLAN will already exist, and will have a different nameSteve McIntyre
from switch to switch... Change-Id: I7df9c821b48bd71e9211cf3065b179b481486909
2014-12-23Bugfix: use the right field name for lookupSteve McIntyre
Change-Id: I5a9bb9be8e377afb09fc3f612c1a91535e44faba
2014-12-23And return the probed dataSteve McIntyre
Change-Id: Id8930e6827dfd88a848e10c5c0507813f90e7660
2014-12-23Fix probe_switches()Steve McIntyre
Change-Id: I25953be83ede4e9edea7c5c97266420b965b10d9
2014-12-23Clean up probe_switches outputSteve McIntyre
Change-Id: I204b39e5bc47a4caaeb05ca59864535d943650cc
2014-12-23Update device recognition textSteve McIntyre
Newer versions of the SX300 family have changed the System Description text. Grrr. Change-Id: Ic2fbf75b14b46e4135c8967641d6db41d1b77815
2014-12-23self.logfile, not logfile. GahSteve McIntyre
Change-Id: I1b32ad8885b5782966390e6baccfd74af286a158
2014-12-23Improve debug for the switch driversSteve McIntyre
When running the built-in test code, turn on debug to stdout by default Change-Id: Iefcba473a0cbfc99ab9bd8b3a878a8f0713989ad
2014-12-23Change test hostnames to match the labSteve McIntyre
Change-Id: Ife0cebfa9480f0297b767796603cbc46bcdb01e6
2014-12-23Make the SX300 driver login more robustSteve McIntyre
Different switches are behaving differently with timing etc. Joy... Change-Id: Idb2bfbb43dedae172cea2bf2af19e7e1a9004e2d
2014-12-23Remove the calls to switch_restart() in debugSteve McIntyre
Change-Id: I337da89176826998318744dbcd7e94f04efb713a
2014-12-23Switch remaining debug messages to use logging instead of printSteve McIntyre
Change-Id: I1b6ec00e03a2a3e2d38296c2bdaacc32341a1eeb
2014-12-23Use the right variable name for switch_nameSteve McIntyre
Change-Id: I761f62cfc2b08ba348c76137a3f658121b115739
2014-12-23Make probe_switches() less verboseSteve McIntyre
Change-Id: I7c45429b08e26f8e1aaf55b5e2364be28b8f8b19
2014-12-23Add admin call for probe_switches()Steve McIntyre
Change-Id: Ia2d4012a56a1e9c0368b360e88e327160139336b
2014-12-23Call the new probe_switches() methodSteve McIntyre
Change-Id: I4af94a8cb7ffb056789f6c8fcdfb98a68576029d
2014-12-23Convert get_all_switches() into a new daemon query probe_switches()Steve McIntyre
Change-Id: I94dd2d0bebadc2e14ce86caca4b6241723b159ea
2014-12-23s/enablepassword/enable_password/gSteve McIntyre
Change-Id: I3022e3f9354d3c9f8e3a908e7e445825c3f64ea2
2014-12-23Log errors on bindSteve McIntyre
Change-Id: I7c491f5091ed94f543c6221c6f986a8d907242c6
2014-12-23Extend test suite coverageSteve McIntyre
Change-Id: I7655cd579a86b200b28e3ce4b2a300b40e3006b8
2014-12-23Fix bug in config - assign default_vlan_tag to default_vlan_tag, notSteve McIntyre
port! Change-Id: I9f65c9008aeccc23236fa518a3af136ec9510de0
2014-12-22Add test case fileSteve McIntyre
Change-Id: I573063f8f9af05568cc984355b8c9971498fa4a6
2014-12-22Add MANIFEST file to ensure cfg is added to dist tarball.Neil Williams
2014-12-22Setup for release 0.1Steve McIntyre
Change-Id: Id9bf8728d84ef2b436303096c9dc7282c650ec16
2014-12-22Fix up some pylint errors and warningsSteve McIntyre
Change-Id: I61a2df4d61c88c253388ab531739c5452b78f681
2014-12-22Fix up some pylint warnings about unneeded codeSteve McIntyre
Change-Id: I0a3b9d93460af77947aa7b5789601579ab59fd13
2014-12-22Bugfix - the connect() interface now needs enablepasswordSteve McIntyre
Change-Id: I6c795624493c7b62a1d3a0e08fa0f8c179c4764d
2014-12-22Bugfix - use the right variable for the switch nameSteve McIntyre
Change-Id: I7bdc1d33aabd3ce702cc4fc6113e5bbe29dad58b
2014-12-22Remove old example code that we adapted for ipcSteve McIntyre
Change-Id: I1cc9d5611e1b796d0a2f51f4655d74b3c98ac5f9
2014-12-22Big raft of changes for util code:Steve McIntyre
s/switch/switch_name/ throughout when referring to switch names, to disambiguate from swicth structure or switch_id Pass in enablepassword to all switch_connect() calls too Change argument passing for all the helpers for perform_vlan_update(): instead of passing (state, command, data) pass in just the right arguments. Much easier for some of these functions to call each other this way. For many of the perform_vlan_update() helpers, switch from using config.switches to db.all_switches() to get the list of switches to work on. It's more consistently going to be right, and is the only option for auto_import_switch() Implement set_port_mode() - complicated due to the need to potentially make lots of VLAN changes to trunk ports as we do this. Implement restore_base_vlan() - simpler, as we don't have to worry about trunk ports here. Implement auto_import_switch() - massive helper function which will make setting up a new installation less painful. :-) Change-Id: Iddb2b3c08e13718d896631001b26259b4413185d
2014-12-22Bugfix - default_vlan_id is part of state, not state.configSteve McIntyre
Change-Id: I6352fbfcf87c9e7e349dfcb1c3799c8910397895
2014-12-22Also take enablepassword, even if we may not use itSteve McIntyre
Change-Id: I70d467069f9c66df94d8df4254a3b30a6825c725
2014-12-22Add auto_import_switch() callSteve McIntyre
Change-Id: I2f03a663420ffdc6246c28bb0a90756377712b1c
2014-12-22Replace __init__.py with an empty fileSteve McIntyre
Change-Id: I3bf17d23db985b9f398fc954e0cc156e87a454d8
2014-12-22Fix warnings from pylintSteve McIntyre
Change-Id: I69087ffeef0a1a9618c633facffb1a9ac3251ba8
2014-12-22s/id/ID/ in messagesSteve McIntyre
Change-Id: I33eb975f9efe1eea8c29b60c625e67b166b49f49
2014-12-22Remove un-needed restore_base_vlan() methodSteve McIntyre
It doesn't actually gain anything over just calling set_current_vlan() Change-Id: If87678f2d9eebd9e73a392bd84a03f8e53621db4
2014-12-21Add get_vlan_tag_by_id()Steve McIntyre
Change-Id: I314f7fcdbf19b7f4fdcc5466236a3e8305291a2a
2014-12-19Implemented the backend for delete_vlan()Steve McIntyre
Change-Id: Ie70408c6ce52e8a520df86c77194a96ae196ef89
2014-12-19Fix syntax errorSteve McIntyre
Change-Id: Ia8819e00c7fc58f5bea87a24ed1d3485442c6219
2014-12-19Clarify commentsSteve McIntyre
Change-Id: I3f5ba2d3f0add1018733d656cccd769d0c212dd3
2014-12-19Add error-handling to create_vlanSteve McIntyre
Re-order slightly, and work out roll-back support If all changes worked ok on all switches, then *and only then* save config on all of them. Otherwise, we'll restart all the switches that *did* work after a failure, to reset their configurations back to that before we started. It's a nuclear and slow path, but it should work. Change-Id: Ic6008ae9cf65482671be2c40cc8d33b6b346c16c
2014-12-19Fix up self-test codeSteve McIntyre
switch_restart closes the connection itself Change-Id: I6eb045a211ea06be99064eafec497c891a0770cf
2014-12-19Added switch_restart method - use to force config rollbackSteve McIntyre
This will be horrendous to use, as it's a very slow operation. But AFAICS it's the only safe way to force a switch to revert config Used by error paths in complex API calls Change-Id: Ib042dacfcf026d754398dfb1f40d31f6e2a4f1cc
2014-12-19Add the backend for the create_vlan() APISteve McIntyre
Change-Id: I26995ed803e5dd42a56de07a8e5070dc10b41554
2014-12-19Add more synonmys for True and FalseSteve McIntyre
Change-Id: I0fe6d6fd11a4649f29be77895ed4f4de1fbc4277