| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
In libvirt repository, there are two related commits
2019-08-23 13:13 Daniel P. Berrangé ● rpm: don't enable socket activation in upgrade if --listen present
2019-08-22 14:52 Daniel P. Berrangé ● remote: forbid the --listen arg when systemd socket activation
In libvirt.spec.in
/bin/systemctl mask libvirtd.socket >/dev/null 2>&1 || :
/bin/systemctl mask libvirtd-ro.socket >/dev/null 2>&1 || :
/bin/systemctl mask libvirtd-admin.socket >/dev/null 2>&1 || :
/bin/systemctl mask libvirtd-tls.socket >/dev/null 2>&1 || :
/bin/systemctl mask libvirtd-tcp.socket >/dev/null 2>&1 || :
|
|
||
| # Create symbolic link for python | ||
| if [ ! -f "/usr/bin/python" ]; then | ||
| ln -s /usr/bin/python2 /usr/bin/python |
There was a problem hiding this comment.
Hi @weizhouapache - my colleagues @shwstppr @davidjumani are working to support python2 to python3 in #4068, so all scripts that run on management server and kvm host towards 4.15/milestone. So this change is not needed, and may break things (we probably don't want misleading symlinks that could mean python2 or python3). cc @wido @GabrielBrascher
Sorry, something went wrong.
There was a problem hiding this comment.
We should really kill Python 2 and not try to have these things in there. I agree.
Sorry, something went wrong.
There was a problem hiding this comment.
@rhtyd @wido
I do not know when cloudstack 4.15 will be released (with python3).
this can be regarded as a patch for cloudstack 4.14.
it works with same mysql version, same scripts (some written in python2, some written in python3), etc
if there is 4.14.1.0, hope this can be included.
Sorry, something went wrong.
|
|
||
| // Verify Format of backing file | ||
| for (DiskDef disk : disks) { | ||
| if (disk.getDeviceType() == DiskDef.DeviceType.DISK |
There was a problem hiding this comment.
Could this break on older CentOS/Ubuntu KVM hosts where the backfile is not supported?
Sorry, something went wrong.
| s.add("-f"); | ||
| if (backingFile != null) { | ||
| s.add(backingFile.getFormat().toString()); | ||
| s.add("-F"); |
There was a problem hiding this comment.
@weizhouapache I checked libvirtd release notes, libvirt doesn't fail VM for version 5.x or below; only libvirt starting version 6.x fails VM deployment if backing file format is not provided. Should we add a check, as the -F option is not available for qemu-img on older distros, say CentOS7, or Ubuntu 16.04 (I didn't check 18.04). Unless we want to discuss and deprecate Ubuntu 16.04 support? cc @wido @GabrielBrascher @shwstppr @davidjumani
Sorry, something went wrong.
There was a problem hiding this comment.
@rhtyd
I think it is supported by ubuntu 16.04
I have tested the migration from ubuntu 16.04 to ubuntu 20.04.
it works fine.
not sure if centos7 supports it.
Sorry, something went wrong.
There was a problem hiding this comment.
@weizhouapache I'm cherry-picking couple of your commits in centos8 support PR branch for testing. I hope it is fine with you.
Sorry, something went wrong.
There was a problem hiding this comment.
@shwstppr while you do the tests etc, can you check if qemu-img on CentOS7 supports the -F argument for specifying the backfile file format?
Sorry, something went wrong.
|
Related PR for same effort, different distro - likely some overlaping bits - #4068 |
Sorry, something went wrong.
|
|
||
| # Create symbolic link for python | ||
| if [ ! -f "/usr/bin/python" ]; then | ||
| ln -s /usr/bin/python2 /usr/bin/python |
There was a problem hiding this comment.
We should really kill Python 2 and not try to have these things in there. I agree.
Sorry, something went wrong.
| # Create symbolic link for python | ||
| if [ ! -f "/usr/bin/python" ]; then | ||
| ln -s /usr/bin/python2 /usr/bin/python | ||
| fi |
There was a problem hiding this comment.
Same as on the mgmt server
Sorry, something went wrong.
There was a problem hiding this comment.
@wido this is a patch for 4.14.0.0
if we change all python2 scripts to python3 in 4.15, we definitely do not need it.
Sorry, something went wrong.
There was a problem hiding this comment.
@weizhouapache As the PR is against master it's for 4.15, therefor I assumed that.
Py3 support is finished for the hypervisors already by @GabrielBrascher , that all works.
No more need for Py2 on hypervisors.
Sorry, something went wrong.
There was a problem hiding this comment.
@wido cool. do you have more changes than security_group.py ? could you create a PR ?
there are still some scripts in 4.14 which are written with python2 and used on kvm hosts, for example all scripts in agent/bindir/
Sorry, something went wrong.
There was a problem hiding this comment.
@weizhouapache PR #3730 updates VR's scripts from python2 to python3. So far it has been tested on Advanced network with Security Group. We should have all python2 code migrated to python3 in 4.15.0.0; as soon as 4.14 is released and the master branch is "unfreeze", we will get back on porting python2 to python3.
Additionally, PR #3730 will be coordinated with other PRs (e.g. #3797). Any help is welcome 🙂
Sorry, something went wrong.
| Package: cloudstack-management | ||
| Architecture: all | ||
| Depends: ${python:Depends}, openjdk-11-jre-headless | java11-runtime-headless | java11-runtime | openjdk-11-jre-headless | zulu-11, cloudstack-common (= ${source:Version}), sudo, python-mysql.connector, augeas-tools, mysql-client | mariadb-client, adduser, bzip2, ipmitool, file, gawk, iproute2, qemu-utils, python-dnspython, lsb-release, init-system-helpers (>= 1.14~) | ||
| Depends: ${python:Depends}, openjdk-11-jre-headless | java11-runtime-headless | java11-runtime | openjdk-11-jre-headless | zulu-11, cloudstack-common (= ${source:Version}), sudo, python-mysql.connector, augeas-tools, mysql-client | mariadb-client, adduser, bzip2, ipmitool, file, gawk, iproute2, qemu-utils, python-dnspython, lsb-release, init-system-helpers (>= 1.14~), python | python2 |
There was a problem hiding this comment.
We should depend on Python 3 only here
Sorry, something went wrong.
|
When using addHost API, it fails to add host with: 2020-05-17 02:11:42,913 INFO [c.c.r.ResourceManagerImpl] (qtp1916575798-22:ctx-998dc1cb ctx-3489fe88) (logid:59229745) Trying to add a new host at http://192.168.1.11 in data center 1 2020-05-17 02:11:42,951 WARN [c.c.h.k.d.LibvirtServerDiscoverer] (qtp1916575798-22:ctx-998dc1cb ctx-3489fe88) (logid:59229745) can't setup agent, due to java.io.IOException: There was a problem while connecting to 192.168.1.11:22 - There was a problem while connecting to 192.168.1.11:22 @weizhouapache have you seen such an error (I tried to use both the zone deployment wizard and addHost API where this fails)? Could this be due to default ssh algorithms issue or our ssh utility class needing any change? Thanks. |
Sorry, something went wrong.
|
@weizhouapache (cc @shwstppr @davidjumani - perhaps check on CentOS8 the version of openssh-server/sshd) I found that openssh-server v7+ per their release notes has deprecated some options that our SSH utility/class uses (needs investigation) which is why CloudStack fails to ssh into KVM host for newer distros, to fix it I had to add the following to the sshd config: PubkeyAcceptedKeyTypes=+ssh-dss HostKeyAlgorithms=+ssh-dss KexAlgorithms=+diffie-hellman-group1-sha1 For reference, my test env: # lsb_release -d && ssh -V Description: Ubuntu 20.04 LTS OpenSSH_8.2p1 Ubuntu-4, OpenSSL 1.1.1f 31 Mar 2020 |
Sorry, something went wrong.
|
@weizhouapache another issue, on deployment of systemvms with MySQL 8.0 cc @shwstppr @davidjumani deployment fails with: Caused by: java.sql.SQLIntegrityConstraintViolationException: Column 'update_time' cannot be null I applied a quick fix to modify the default time to be null: ALTER TABLE nics MODIFY COLUMN update_time timestamp NULL; |
Sorry, something went wrong.
|
@weizhouapache cc @shwstppr @davidjumani @wido @GabrielBrascher @PaulAngus @andrijapanicsb @DaanHoogland @kiwiflyer and others qemu-img version 2.5.0 (Debian 1:2.5+dfsg-5ubuntu10.43), Copyright (c) 2004-2008 Fabrice Bellard usage: qemu-img command [command options] QEMU disk image utility Command syntax: check [-q] [-f fmt] [--output=ofmt] [-r [leaks | all]] [-T src_cache] filename create [-q] [-f fmt] [-o options] filename [size] I checked CentOS7 and that was okay (qemu-img create supports -F ). Let's discuss:
|
Sorry, something went wrong.
|
@weizhouapache I am +1 for dropping 16.04 support in 4.15. As this will be an LTS which will be maintained beyond April 2021 and Ubuntu 16.04 is then no longer supported. 18.04 and 20.04 should be the supported Ubuntu distro's then. |
Sorry, something went wrong.
|
@rhtyd root@node42:~# qemu-img create -b /mnt/ee9ffb52-bd20-3328-8a7f-090723db12c4/bd84bcd9-d040-4e9f-a777-617c712b10dc -f qcow2 -F qcow2 bb
Formatting 'bb', fmt=qcow2 size=2097152000 backing_file=/mnt/ee9ffb52-bd20-3328-8a7f-090723db12c4/bd84bcd9-d040-4e9f-a777-617c712b10dc backing_fmt=qcow2 encryption=off cluster_size=65536 lazy_refcounts=off refcount_bits=16
root@node42:~# qemu-img info bb
image: bb
file format: qcow2
virtual size: 2.0G (2097152000 bytes)
disk size: 196K
cluster_size: 65536
backing file: /mnt/ee9ffb52-bd20-3328-8a7f-090723db12c4/bd84bcd9-d040-4e9f-a777-617c712b10dc
backing file format: qcow2
Format specific information:
compat: 1.1
lazy refcounts: false
refcount bits: 16
corrupt: false
anyway, I agee with @wido we can probably drop Ubuntu 16.04 support if we release 4.15 next year |
Sorry, something went wrong.
@rhtyd is the issue fixed with the new ssh config ? Two issues need to mention: |
Sorry, something went wrong.
|
Hi @weizhouapache - yes the addHost ssh issue is fixed with the changes to sshd_config
On further testing my colleagues (@shwstppr) found an issue with newer qemu when trying to take a volume snapshot: com.cloud.utils.exception.CloudRuntimeException: qemu-img: Could not open '/mnt/05c30f6d-5725-3369-a8d6-b5fb37c7ba8f/20dc7b29-934a-409a-babf-f4527f574377': Failed to get shared "write" lockIs another process using the image [/mnt/05c30f6d-5725-3369-a8d6-b5fb37c7ba8f/20dc7b29-934a-409a-babf-f4527f574377]?there is no 62f4eb05-168e-4161-a070-f8804df068d0 on disk /mnt/05c30f6d-5725-3369-a8d6-b5fb37c7ba8f/20dc7b29-934a-409a-babf-f4527f574377 at org.apache.cloudstack.storage.snapshot.SnapshotServiceImpl.backupSnapshot(SnapshotServiceImpl.java:301) at org.apache.cloudstack.storage.snapshot.DefaultSnapshotStrategy.backupSnapshot(DefaultSnapshotStrategy.java:171) at com.cloud.storage.snapshot.SnapshotManagerImpl.backupSnapshotToSecondary(SnapshotManagerImpl.java:1213) at com.cloud.storage.snapshot.SnapshotManagerImpl.takeSnapshot(SnapshotManagerImpl.java:1164) Have to seen this issue? |
Sorry, something went wrong.
|
@rhtyd The snapshot issue also exists under 18.04. Qemu now locks a QCOW2 file and thus can't be snapshotted while the VM is running in order to protect the QCOW2 file. |
Sorry, something went wrong.
|
@shwstppr ping - can you check and confirm Wido's comment? |
Sorry, something went wrong.
@wido @rhtyd I was able to snapshot a stopped VM. Probably some caching issue in my UI else it should have stopped the operation. Checking that. This should be a non-issue otherwise. |
Sorry, something went wrong.
|
@shwstppr a Jenkins job has been kicked to build packages. I'll keep you posted as I make progress. |
Sorry, something went wrong.
|
Packaging result: ✔centos7 ✔debian. JID-1260 |
Sorry, something went wrong.
|
Trillian test result (tid-1597)
|
Sorry, something went wrong.
|
@weizhouapache can you check and close, we used your commits as reference and included here for consolidated fixes and testing - #4068 |
Sorry, something went wrong.
|
LGTM, here is what I've tested: KVM operations:
|
Sorry, something went wrong.
@vladimirpetrov thanks for testing. |
Sorry, something went wrong.
|
Hi @weizhouapache, this was tested on the latest mainstream, the idea was to double-check the feature. |
Sorry, something went wrong.
| Back | FazBrowse Home | New Git URL |
Description
This aims to support Ubuntu 20.04 as a hypervisor in cloudstack 4.15
Types of changes
Screenshots (if appropriate):
How Has This Been Tested?