cyclades: Add a function to check name legnth
cyclades: Fix a bug in subnet creation
cyclades: Fix typo in stats-cyclades cmd
cyclades: Update backend only when needed
Make dispatcher ask Ganeti about the enabled/ipolicy disk templates onlyafter an OP_CLUSTER_SET_PARAMS. Otherwise, dispatcher will beoverwhelmed by gnt-cluster verify jobs.
cyclades: Fix bug in network link validation
cyclades: Include port in floating-ip-list command
cyclades: Fix error msg when deleting floating IPs
cyclades: Disable conflict checks for IPv6 nets
Vocabulary fixes: Dettach -> Detach
cyclades: Add setting for Ganeti clone providers
Add new 'GANETI_CLONE_PROVIDERS' setting to containg the list ofExtStorage providers that support cloning. For these providers thehashmap of the image is passed as an ExtStorage parameter('origin').Also, since the disk is already filled with data, snf-image performs...
cyclades: Setting for max NICs per Ganeti instance
Add new 'GANETI_MAX_NICS_PER_INSTANCE' setting which represents themaximum number of NICs that is allowed for each Ganeti instance. Thevalue of this setting must be less than 'max:nic-count` option ofGaneti's ipolicy.
cyclades: Pass arbitrary params to ext providers
Add 'GANETI_DISK_PROVIDER_KWARGS' setting, which contains a dictionaryof arbitrary parameters for each of Ganeti's ExtStorage providers andwhich will be passed to the 'disks' option of CreateInstance Ganeti job.
cyclades: Ignore messages about deleted resources
Ignore messages from Ganeti about servers and networks that have alreadybeen marked as deleted in the Cyclades DB. Processing of these messagesmay asynchronize Cyclades with Astakos quotas.
cyclades: Order pools by id
cyclades: Remove testing try/exception statement
cyclades: Fix deadlock when releasing floating IPs
cyclades: Fix bug in getting a free floating IP
Fix wrong query which resulted in getting non-floating IPs.
cyclades: Fix division by zero bug
Ganeti reports zero available and total disk if no vg is set. Thiscaused a division by zero error in the default backend allocator.
cyclades: Fix DB locking issues causing deadlocks
Fix deadlock issues that is caused by Postgresql's locks on foreignkeys. For example, creation of a BackendNetwork row will result in ashared lock in the 'backend_id' rows. Because updating a VM's NICsacquired an exclusive lock on the backend that the VM lived, this...
cyclades: Fix typo in log msg
cyclades: Require subnet for IP_LESS_ROUTED nets
cyclades: Remove DEFAULT_ROUTING_TABLE setting
Do not have a default value from 'link' attribute of IP_LESS_ROUTEDnetworks. Instead if the admin does not specify a value innetwork-create command, uniquely name the networks by with theBACKEND_PREFIX_ID and network id, e.g. snf-link-42.
cyclades: Add --drained option to network-create
cyclades: Some verbla fixes to snf-manage commands
cyclades: Optimize server-list command
Optimize server-list command by prefetching related fields if needed.
Add support for snf-vncauthproxy >= 1.5
cyclades: Fix wrong state of deleted networks
Before deleting a network, the network is marked as drained to beexcluded from automatic IP allocation. The state of the network that isexposed in the API is always 'SNF:DRAINED' if the drained flag is set....
cyclades: Fix broken unittest
cyclades: Lock objects in modifying commands
cyclades: Move all management commands to logic
Move all management commands from 'api/management/commands' to'logic/management/commands'.
Add some missing Copyright notices
Also add 2013 in package COPYRIGHT files.
cyclades: Change logging level to error
cyclades: Fix bug by wrong indentation
cyclades: Improve messages for default networks
Improve log and exception messages when failing to connect new server todefault and forced server networks.
cyclades: Include 'vlmc' and 'archipelago'
Fix image ID for both 'vlmc' and 'archipelago' ext providers.
Merge branch 'master' into develop
Conflicts: ci/schemas/one_node_wheezy/wheezy.conf docs/admin-guide.rst snf-cyclades-app/synnefo/api/actions.py snf-cyclades-app/synnefo/api/servers.py snf-cyclades-app/synnefo/logic/backend.py snf-cyclades-app/synnefo/logic/callbacks.py...
cyclades: Fix a bug in logic/subnets.py
cyclades: Rename hotplug to hotplug_if_possible
Use 'hotplug_if_possible' option when adding/removing NICs frominstances. 'hotplug' option will fail if the instance is alreadystopped. Also, pass 'hotplug' option only if it is enabled.
cyclades: Update some snf-manage commands
cyclades: Better handling of deleted subnets
cyclades: Add shutdown_timeout to RAPI client
Add missing 'shutdown_timeout' option to reboot, shutdown and destroymethods of Ganeti RAPI client. The Ganeti RAPI daemon will ignore thisoptions until Ganeti 2.10.
cyclades: Map reboot type to shutdown timeout
Fix handling of reboot type option. If 'hard' reboot type is specifiedthis is mapped to zero shutdown timeout of OP_INSTANCE_REBOOT Ganetijob. This is only supported from Ganeti>=2.10 and snf-ganeti. In other...
cyclades: Remove duplicate constants
cyclades: Fix removal of stale NICs in BUILD state
Until now, NICs that did not exist in the Ganeti backend and were inBUILD state were removed after a timeout (BUILDING_NIC_TIMEOUT). Thiswas dangerous, because if an OP_INSTANCE_CONNECT job had been "stuck"...
cyclades: Add name to Ganeti NICs
Add 'name' attribute to newly created NICs. Currently, the name of theNICs will not be used to refer to NICs, as it will be in Synnefo 0.15.Names are added only to ease the migration to version 0.15. Also, thiscommit updates snf-dispatcher to preserve the name of the NIC, if any,...
cyclades: Command to export Cyclades statistics
Add new 'snf-manage stats-cyclades' management command to export basicstatistics about Cyclades, like number of servers, network and resourceutilization. The command can either export the statistics either in JSON...
cyclades: Export Cyclades detailed stats from API
Add '/admin/stats/detail' API endpoint to export basic statistics aboutCyclades. Access to this view is only allowed to the users that belongto specific Astakos groups, as specified in the new setting'ADMIN_STATS_PERMITTED_GROUPS.' Also, added the new 'user_in_groups' API...
cyclades: Fix bugs relative with quotas
cyclades: Do not retry all Ganeti failed creations
Make snf-dispatcher retry only the OP_INSTANCE_CREATE jobs that faileddue to opportunistic locking. Such jobs include the 'ECODE_TEMP_NORES'error code in the opcode result. This commit makes snf-ganeti-eventd...
gtools: Fix Ganeti allocation parameters
When retrying a failed job, remove 'pnode' and 'snode' fields if theywere implicitly set by Ganeti iallocator. Ganeti will fail if bothiallocator and node are specified in the job.
cyclades: Generalize issue_and_accept_commission
Use issue_and_accept_commission for any action where one needs toautomatically accept the commission after issuing and committing.
cyclades: Issue commission based on action
Make issue_commission() the single point where provisions are computedand the appropriate astakosclient call is issued.
cyclades: Resolve undecided serial in force mode
Reject a serial with pending=True only when we need to force a newcommission on a given resource.
Also improve handling of serial state: make sure pending is set to Falsewhen we decide whether to accept or reject a serial. Mark a serial to...
cyclades: Pass action params in server_command
Commission to be issued depends on extra parameters for some actions,e.g., on the flavor when resizing a vm.
cyclades: Allow deletion of ports from public nets
Move check about deleting a port from a public network. This check isonly enforced in the API, but is allowed in logic layer, e.g. snf-managecommands.
Merge branch 'hotfix-0.14.10' into develop
Conflicts: Changelog snf-cyclades-app/synnefo/api/servers.py snf-cyclades-app/synnefo/logic/backend.py snf-cyclades-app/synnefo/logic/callbacks.py snf-cyclades-app/synnefo/logic/management/commands/reconcile-networks.py...
cyclades: Update disk_templates if empty
Make backend_allocator to refresh the available disk templates of abackend if there are empty.
cyclades: Check drained only if not destroying
Check drained flag only if network actions is not destroy. When networkis being destroyed the network is automatically marked as drained toexclude it from IP allocations.
cyclades: Check for all finalized states
cyclades: Handle snf-ganeti bug
Create IPv6 only networks as /29 because snf-ganeti can not create /30networks.
Merge branch 'feature-cyclades-networks' into develop
Conflicts: snf-cyclades-app/synnefo/api/management/commands/server-inspect.py snf-cyclades-app/synnefo/app_settings/urls.py snf-cyclades-app/synnefo/logic/backend.py snf-cyclades-app/synnefo/logic/backend_allocator.py...
cyclades: Fix some broking tests
cyclades: Fix a bug in network and subnet create
cyclades: Add a new function in logic/subnets.py
cyclades: Retry failed instance creation
Handle special case where an OP_INSTANCE_CREATE job which uses theopportunistic locking feature fails. This failure is probably due to thefact that all nodes may be already locked. In this case, makesnf-dispatcher retry the failed job with opportunistic locking turned...
cyclades: Fix compatibility issues with networks
From version 2.7, Ganeti returns the network's UUID field in nics'networks' attribute. Instead use 'networks.names' attribute to getthe network name.
cyclades: fix typo in snf-dispatcher
cyclades: Fix case where 'dfree' is None
If Ganeti has not enabled 'plain' or 'drbd' disk template, then itreports 'dfree' as None. Fix this corner case by treating None as 0.
cyclades: Small fixes to network reconciliation
cyclades: New style format for modifying a NIC
Signed-off-by: Dimitris Aragiorgis <dimara@grnet.gr>
cyclades: Remove hotplug from InstanceCreate
cyclades: Pass network type info as network tag
cyclades: Remove deprecated network type in ganeti
cyclades: Use opportunistic locking
Use opportunistic locking, introduced in Ganeti 2.7, to allow parallel creationof VMs in the Ganeti backend. When this option is set, Ganeti iallocatorwill allocate the VM only to nodes that not locked (e.g. by other VM...
gtools: Fix compatibility issues with ganeti-2.7
cyclades: Fix bug in network reconciliation
Skip reconciliation for a network that does not exist in the DB, ifreconciliation is running without the '--fix' option.
Conflicts: Changelog astakosclient/astakosclient/keypath.py ci/utils.py docs/admin-guide.rst snf-astakos-app/astakos/im/cookie.py snf-astakos-app/astakos/im/functions.py snf-astakos-app/astakos/im/quotas.py snf-astakos-app/astakos/im/views/projects.py...
cyclades: Simplify code to 'logic.subnets' module
cyclades: Do not print IP pool for IPv6 only nets
Do not print IP pool of Ganeti network in case the network is an IPv6only network. The Ganeti network has a dummy IPv5 subnet, just becauseit is needed. Only change this dummy subnet to /30 to reduce space in...
cyclades: Handle 'drained' flag of networks
cyclades: Fix corner case in reconciliation
If at the end of reconciliation the state of the network is not ACTIVE,try to recompute the state of the network based on the state of thenetworks in each backend. This step is mostly needed in case that thenetwork does not exist in any backend.
cyclades: Fix reconciliation of floating IP pools
Remove special handling of floating IP pools in reconciliationmechanism since floating IP pools are treated the same way with othernetworks.
cyclades: Pass 'nfdhcp' tag to IPv6 networks
Pass 'nfdhcp' tag even if network is IPv6 only.
cyclades: Optimize *-list commands
Use prefetch_related and select-related to importive the DB queries thatare generated by *-list snf-manage commands.
cyclades: Code refactoring to backend module
cyclades: Fix init of networks in backend-add
Fix which networks are going to be initialized in the new backend andhow the are printed in the output!
cyclades: Fix network-create management command
Fix when network is created in the Ganeti backends. The network must becreated in the Ganeti backends only after IPv4 or/and IPv6 subnet hasbeen created. This commit moves the code that created the network in the...
cyclades: Fix bugs in subnets and ports
cyclades: Create IPv6 Addresses from dispatcher
When ports are created from the API they do not have an IPv6 address.The IPv6 address is only available after the MAC address of theNIC is known which is only available after the message from theGaneti backend has been received. However, dispatcher did not created...
cyclades: Merge subnet-create with network-create
Cyclades: Rename 'Can not' to 'Cannot' to all msgs
cyclades: Do not allow any action on 'ERROR' vms
Do not allow any action, other than 'DESTROY' in servers that are in'ERROR' state. If the server is in 'ERROR' state then the correspondingGaneti instance may not exist, so all actions will fail.
cyclades: Fix default/forced server networking
Fix the default behaviour for networking of servers that are beingcreated. There are two settings controlling this behaviour:
cyclades: Add missing 'ips' module
cyclades: Refactor code
Move code relative with allocating ips and floating IPs to 'logic.ips'module.
cyclades: Workaround for race condition in Ganeti
Workaround for race where OP_INSTANCE_REMOVE starts executing on Ganetibefore OP_INSTANCE_CREATE. If this is the case, OP_INSTANCE_REMOVE willnot wait for locks, instead it will fail because the instance has not...
cyclades: Forbid new ports no deleting network
Do not allow creation of new ports and reservation of floating IPs onnetwork that are being deleted. Currently the state of the networkchanges only when the network gets deleted from all backends. So wecheck if a network is being deleted by checking if the action of the...
cyclades: Create server in public net with FIP
Remove 'floating_ips' extension attribute to POST /servers API call.Instead use the 'fixed_ip' attribute of 'networks' attribute to specifythe IPv4 address of a floating IP. So in order to create a serverconnected to a private network and a public network, the 'networks'...