Make snf-dispatcher work with gevent
Remove workers from snf-dispatcher in order to make it compatible with geventand specifically the green, monkey patched version of psycopg2(synnefo.lib.db.psyco_gevent). Also after daemonizing, gevent must bereinitialized because the deamon context forks.
Add some logging to backend allocator
Refactor IP pools
Treat IP pool the same way as bridge and mac-prefix pools. The pool isremoved from the Network table and moved to an IPPoolTable containing theIP pools for all networks. Also added support for external reservations.
Migration files for transfering the pool to the new tables are included....
Add tests for PoolManager(s)
Fix bugs in IPPool
- Do not always reserve gateway- Initial reservations must be in reserved map
Handle case of no pools in reconcile-pools
Catch error in removing nic
Management commands for pools
Create three new management commands for listing, showing and modifyinga pool.
Unique mac-prefix only for mac-filtered networks
Add logging to synefo.db.models
Refactor bridge and mac-prefix pool tables
Redesign the implementation of pools and map mac-prefix and bridge poolsto that design.
Each pool type is mapped to a table in the database, and each row ofthat table is a pool of that type. All pool tables must contain the...
Fix bug in server-inspect
Fix bug in snf-manage network-remove
Wrap network-create command in transaction
Enable hotplug during create_instance
This passes hotplug = True to ganeti and enables hotplug per instance.It checks GANETI_USE_HOTPLUG setting.
Signed-off-by: Dimitris Aragiorgis <dimara@grnet.gr>
Support multiple public networks in UI
Encapsulate in nic dict a public flag (network.public) andremove twisted oldstyle identification way (network_id == 'public')for retrieving public interfaces.All network references are done via their network_id....
Allow connecting a VM to a network only if active
New method for creating BackendNetwork entries
Create a new method to the Network model, in order to create theBackendNetwork entries tha correspond to this network. Also removethe custom save method, since when multiple public network will besupported, we want them to be correlated with specific backends.
Remove dead code
Implement multiple public networks
Implement multiple public networks in order to support:- different public networks per backend- non-consecutive IP ranges in each backend
To support this, public networks are treated different from privateones. Namely, they are correlated with one backend (and so have...
Do not allow creation of two big/small networks
- Networks smaller than /29 are not supported in Ganeti.- Big networks will result in degraded performance in Ganetiand DB due to the big reservation map.
Reserve gateway's IP when creating an IP pool
Propagate NIC change event to the associated vm
so that nic changed attributes get propagated to the vm views (e.g. nic ipchange).
Catch error caused by duplicate NIC removal in ui
NICs get removed once their associated vm or network trigger theircorresponding remove signal. Synchronous removal of vm/network willcause duplicate NIC removes to be called.
Revert plankton backend to its original state
trash development code was added by mistake in commit `c6dda6c`
Update GANETI_DISK_TEMPLATES setting description
Describe how to set ext disk template provider.
Support for ext disk providers
Extract provider from flavor disk template name and set the additional`provider` parameter in disk options. Flavor disk_template should beformated as `ext_<provider_name>`.
Networks list api response fix
include deleted networks in reponse if changes-since parameter is set. Thisenables ui application to identify deleted networks and remove them fromuser interface.
Remove spare div from html
Fix html typo
Firefox ui fix
add overflow to `hidden` to properly clear upper div in single vm view.
Fix servers api list response
filter out deleted vms !!!!!!!
Fix servers api response
do not filter out deleted vms if valid changes-since parameter is set onthe request. This allows ui application to be able to identify and removedeleted vms.
Add check for maximum secret encryption key
SECRET_ENCRYPTION_KEY can be up to 32 bytes long, since bigger keys arenot supported by AES encryption. Add comment to the setting and bettermessage to exception.
Fix bug in migration file
Do not allocate a bridge from the pool for deleted networks.
Rename setting
Rename ENCRYPTION_KEY to SECRET_ENCRYPTION_KEY to prevent from beingdisplayed at django debug traces.
Add setting indicating whether to use hotplug
Revert "Start pool indexing from 0"
This reverts commit 2f998a3756c6fc7ddce9e0f83dea738e473320b8.
Update Changelog
Fix bug in creating network
Exclude deleted networks.
New dependencies of snf-cyclades-app
Start pool indexing from 0
Limit allowed private networks per user
Management command for removing backend
Add command for checking pool consistency
Add new management command 'reconcile-pools' which checks the consistency of thepools and the uniqueness of the associated resources. Currently thiscommands detects the inconcistencies, without trying to resolve them.
Fix serious bug in reconciliation
Do not perform reconciliation for VMs that are hosted in Backendsthat are currently offline, since it is impossible to get thestate of these VMs from the backend. Before this patch, thereconciliation mechanism would report these VMs as stale (and with...
Fix migration files
Fix south migration files. In data migrations, access the Models fromthe orm, instead importing Models from synnefo.db. This is necessary asthe orm provides access to the version of the models that existed whenthe migration file was created.
Store action when creating a network
Implement MAC Prefix Management
In order to guarantee uniqueness of MAC address accross all backends,synnefo assignes a unique mac prefix to each network in each backend.
A mac-prefix of 20 bits, which is picked from the MacPrefixPool, isassigned to each Network. The mac-prefix of the network in each...
Warning about missing setting to migration file
Fix bug when adding a new backend
Fix wrong reporting messages when adding a new backend.
Get public network by public attribute
Do not find the public network by the primary key, as the initial_data.jsonis obsolete. Instead, ise the public attribute of the Network Model.Currently only one public Network is supported, and the used can notcreate or delete the public Network. But this can easily change in the...
Release resources of Network only on deletion
Assert that this is an 'real' deletion of a Network before releasingit's resources. Without this patch, a resource used by an other Networkcould be released, if someone called the Network.update_state function...
Fix creation of networks in new backend
Fix bugs in migration files
Add missing setting
Add PRIVATE_PHYSICAL_VLAN_TAGS setting
Fix bug in process_net_status
Check that nic has an ipv4 before trying to release it.
Setting for using IP Pool to public network
Introduce new setting 'PUBLIC_ROUTED_USE_POOL', to indicate whethersynnefo will be responsible for the IP management of the public network,or this responsibility will be delegated to Ganeti.
Fix dispatcher default file
Consider cpu ratio when allocating vm's
Fix case of empty address pool
Transaction on create_instance
Limit allowed network size
Limit the size of networks that users can create, since big IPpools can have negative impact on performance. Allowed networksize is controled by 'MAX_CIDR_BLOCK' setting.
Reconciliation for network IP pool management
Reconcile the contents of each networks IP pool by comparing itwith combination of IP pools of all ganeti backends.
Add extra option for detecting conflicting IPs.
Implement model manager using row-level db locking
Implement ForUpdateManager that uses SELECT .. FOR UPDATE statement inorder to acquire row-level exclusive locks to DB. Essentially thismanager backports the select_for_update() method that is implemented in...
Increase the size of backend password_hash
Fix IP pool exceptions
Add transaction control to API methods
Specially for create_instance and create_network methods, since aVirtualMachine, Network object is created before sending the requestto the backend.
Use ForUpdateManager to Pool objects
Display IP pool map in network-inspect command
Release IP addresses when nics are destroyed
Add support for IPv6
- Extend the Network model with fields for holding the IPv6 subnet and gateway.- Update network API methods.- Modify ganeti hooks to return IPv6 address for all network interfaces. IPv6 is now derived from the IPv6 subnet of the network in Ganeti,...
New management command for creating a network
Create a management command for creating networks. Also removethe initial_data.json, since it is currently not necessary.
Fix error state of BackendNetwork
Implement IP management
Delegate IP management to synnefo, in order to be able to allocate IPaddresses accross multiple Ganeti backends. This is achieved by creating aPool of IPs for each Network, in the form of a bitarray, which is storedin the DB as a base64 string....
Update network settings
Filter deleted entries when changes-since is used
Modify list_networks and list_servers to filter deleted entries whenif-modified-since HTTP header is used, because deleted entries can beupdated after deletion through the reconciliation mechanism.
Rename management commands
Encrypt Backend password
Use cipher to encrypt the passwords of the Ganeti backends in the DB.Encryption/decryption is based on a configurable key, defined by theENCRYPTION_KEY setting. After modifying this setting, synnefo will beunable to decrypt already stored passwords, and passwords must be...
Handle bridge/mac-prefix pool exhaustion
Raise Overlimit exception when either bridge or mac-prefix poolis exhausted. Also prohibit public network creation.
Add dirty bit to NetworkInterface
Extend NetworkInterface model with a dirty bit, indicating whetherthe index of the NIC is consistent with the one in Ganeti. This flag isset when deleting a NIC, and is switched off after processing thenotification from Ganeti. Removing a NIC with the dirty bit on is not...
Update servers/networks responses for new API
- Reponses for servers and netowrks details (list or solo) are nowconsistent to recent backend changes.- Methods get_nic_from_index and construct_nic_id have been created- Syntax for nic removal from network/vm has been adjusted
When creating network, the label subnet can now be cdir in the json request
Revert "Fix bug in dispatcher callback"
This reverts commit 5d40a128fb593ed641400c462f0e00a1b457f76e.
Remove machine if ganeti job fails
Set the VM deleted flag when receiving a failure notification for aGaneti OP_INSTANCE_REMOVE operation, even if the VM operstate is notERROR. The server may not exist in the backend not only because thecreation failed, but also because a remove notification was lost.
Fix modifynetwork management command
check available network status options based on Network.OPER_STATES
Cyclades UI integration with the new networks api
- Handles nic connections instead of vms. New NIC model and NICs collections created to handle the NIC api logic. NIC models get updated on each vms/networks api call.- New private network creation form....
Update cyclades ui jquery lib to 1.7.2
Update management commands for new-style networks
Common functions for instance/network backend name
Fix use of network name prefix
Release resources when deleting network
Set as available in the pool the bridge and mac prefix that wasused by the deleted network.
Fix bug about unknown network in instance's nics
Fix management commands
- Fix bug in backend_add- Display backend_name in network_inspect command
Fix bug in networks api
Bug fixes concerning networks
Fix bug in dispatcher callback
During handling of ganeti-op-status messages, state was set to erroronly if the the opcode was OP_INSTANCE_CREATE. This resulted tovm's never being deleted, if they did not exist in Ganeti.
Print warning about subnet value during migration
Set index of NetworkInterface model to not null
Add backend method for removing a vm's nic