Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SystemVM template installation script does not check if file command exists #3117

Closed
Overv opened this issue Jan 2, 2019 · 3 comments · Fixed by #3436
Closed

SystemVM template installation script does not check if file command exists #3117

Overv opened this issue Jan 2, 2019 · 3 comments · Fixed by #3436

Comments

@Overv
Copy link

Overv commented Jan 2, 2019

ISSUE TYPE
  • Bug Report
COMPONENT NAME
Management script
CLOUDSTACK VERSION
4.11.2
CONFIGURATION

N/A

OS / ENVIRONMENT

Ubuntu 18.04 LTS minimal

SUMMARY

If the file utility is not installed then the cloud-install-sys-tmplt script does print an error, but does not fail with a non-zero exit code and instead installs a bz2 file as if it were a qcow2 file.

STEPS TO REPRODUCE
$ /usr/share/cloudstack-common/scripts/storage/secondary/cloud-install-sys-tmplt -m /export/secondary -u http://download.cloudstack.org/systemvm/4.11/systemvmtemplate-4.11.2-kvm.qcow2.bz2 -h kvm -F
EXPECTED RESULTS

The script to fail outright.

ACTUAL RESULTS
...
/usr/share/cloudstack-common/scripts/storage/secondary/createtmplt.sh: line 57: file: command not found
File /usr/share/cloudstack-common/scripts/storage/secondary/28966bfc-6205-4689-b6f7-dfac05e48ce8.qcow2 does not appear to be compressed
...
@DaanHoogland
Copy link
Contributor

really ? a unix system without file!?!.

@Overv
Copy link
Author

Overv commented Jan 7, 2019

@DaanHoogland I was as surprised as you are, but I guess it's considered a non-essential utility for minimal images.

@rohityadavcloud
Copy link
Member

That's surprising so I guess the cloudstack-common package should install file on debian/ubuntu systems?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants