----
Migration away from download.cloud.com to download.cloudstack.org may cause problems in exisiting cloudstack installations and versions
// CloudStack Consultancy & CloudStack...
Background
Cloudstack relies on a fixed download site when it requires system templates for the default guest VMs
That download site has historically been download.cloud.com and is being replaced by download.cloudstack.org.
Download.cloudstack.org is now fully functional. The retirement date of download.cloud.com is unknown but expected to be imminent
The issue & behaviour
After the retirement of download.cloud.com, the following issues may be experienced:
- when installing CloudStack for the first time, failures will occur when downloading the required templates
- for existing installations of CloudStack, if administrators or users attempt to re-download a template (for example when creating a new zone), failures will occur.
Versions affected
This issue affects Apache CloudStack version 4.9.2 and ALL PRIOR VERSIONS
CloudStack 4.10, due for release imminently, is NOT affected by this issue. Future versions should not be affected by this issue.
Resolution
The following steps will update an existing CloudStack version to use the new download site. This process should also be followed, in advance of installation, when attempting to install a new instance of CloudStack for affected versions.
1. list the URLs to update
Locate the 'cloud' database and run this SQL command against it, replacing <user-id> and <your password>
$ echo "SELECT id,url FROM vm_template WHERE url LIKE '%download.cloud.com%' AND NOT removed IS NULL\g" | mysql -u <user-id> -p<your password> cloud
This will return all URLs that CloudStack uses for downloads that are pointing to download.cloud.com
A number of rows should be returned. The following is a sample output
id url
11 http://download.cloud.com/templates/builtin/centos-7-x86_64.tar.gz
13 http://download.cloud.com/templates/4.2/systemvmtemplate-4.2-vh7.ova
If no rows are returned you are not affected by this issue; you need to do nothing further. If rows are returned, proceed to step 2
2. Check that ALL templates are present on the new download site.
All templates that were previously located at download.cloud.com should be in an identical location at download.cloudstack.org. However, we advise that you confirm this by to attempting to manually download all of the templates from the same directory at downloads.cloudstack.org
To do this, take every result returned at step 1 and attempt to manually download them from the same location at downloads.cloudstack.org
Taking the above examples check that you are able to download:
http://download.cloudstack.org/templates/builtin/centos-7-x86_64.tar.gz
http://download.cloudstack.org/templates/4.2/systemvmtemplate-4.2-vh7.ova
(the files don't actually need to be downloaded at this stage, you are just checking for their existence)
If all templates are present, then continue to step 3. If any are missing (you will receive a 404 error), then contact users@cloudstack.org or your support provider
3. Update the URLs in the vm_template table
Update any URL's that point to download.cloud.com. This can be performed in a SQL editing tool or by running a statement such as:
UPDATE vm_template SET url = REPLACE(url, 'download.cloud.com', 'download.cloudstack.org') WHERE INSTR(url, "download.cloud.com") > 0 AND removed IS NULL;
----
Read in my feedly
Sent from my iPhone
No comments:
Post a Comment