Dietmar Maurer [Mon, 29 May 2017 08:31:04 +0000 (10:31 +0200)]
pvesr prepare-local-job: new helper
Prepare for starting a replication job. This is called on the target
node before replication starts. This call is for internal use, and
return a JSON object on stdout. The method first test if VM <vmid>
reside on the local node. If so, stop immediately. After that the
method scans all volume IDs for snapshots, and removes all replications
snapshots with timestamps different than <last_sync>. It also removes
any unused volumes.
Returns a hash with boolean markers for all volumes with existing
replication snapshots.
We're already limiting CPUs to lxc/cpuset.effective_cpus,
so let's use the highest cpuid from that set as a maximum to
initialize the container count array.
Thomas Lamprecht [Wed, 22 Mar 2017 10:08:02 +0000 (11:08 +0100)]
ceph/pool: allow bigger size and min_size values
Some setups may want to use more replicas as three, while my proposed
maximal 7 replicas is also arbitrary it should cover all normal
usecases (i.e. 5 replicas) and a bit more, just to be sure.
Dominik Csapak [Fri, 24 Mar 2017 13:19:11 +0000 (14:19 +0100)]
fix #1317: check wizard form also on validitychange
with the commit 40342aa6c4278497b9ec8c9cce8739f9b29c2e8f
we introduced a validator on the guestidselector, but did not
notice that the wizard checks the validity on the field change event,
but the selector gets valid/invalid in an api callback(so a little later)
with this patch, we now validate the field correctly with validate()
and also listen on the validitychange event to catch it
Thomas Lamprecht [Wed, 15 Mar 2017 15:47:42 +0000 (16:47 +0100)]
remove backup locks when starting all VMs on boot
If on bootup one of our VMs is locked by an backup we safely can
assume that this backup job does not run anymore and that the lock
has no reason anymore and just hinders uptime of services.
As at this time we (the node) have quorum so we may safely assume
that we have a consistent view of the cluster and all our VMs really
belong to us. We just need to ensure that we do not run into an
automatic backup jobs, so execute our code with VZDumps lock or
timeout.
Log in the Task and Sys log that we removed the lock, so that an
admin easily sees that there may be need for cleaning leftovers from
an interrupted backup.
Addresses bug #1024
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
Thomas Lamprecht [Wed, 15 Mar 2017 15:47:41 +0000 (16:47 +0100)]
get_filtered_vmlist: save VM conf in own subhash
small refactoring in get_filtered_vmlist: save a VMs config in its
own subhash to avoid collisions with other data which we want to save
in the vmid list, for now this is only `type` but in the next patch
I want to save also the class
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
having our ceph.service pulled in by ceph.target does not
work anymore, because "systemctl start ceph.target" hangs
forever on ceph-common upgrades. multi-user.target seems to
work as well, and we are ordered after pve-cluster anyway.
only replace the old ceph.service if it is an exact match.
Dominik Csapak [Fri, 10 Mar 2017 09:12:25 +0000 (10:12 +0100)]
fix diffstore issue with clusterlog
extjs cannot "convert" and id from other fields, so the ids in the
diffstore and the realstore are different and we re-add every element on
every update
to mitigate this, we generate the id (which is "uid:hostname") in the
backend, and simply use it in the frontend
Dominik Csapak [Wed, 15 Feb 2017 13:55:50 +0000 (14:55 +0100)]
check earlier if the logview is destroyed
because extjs 6.2 handles destroying of components differently (namely
asynchronous), we have to check earlier if the view is destroyed, else
we get a 'cannot access ~ of undefined' error
Dominik Csapak [Wed, 15 Feb 2017 13:55:49 +0000 (14:55 +0100)]
make the ha node priority field explicitly not a form field
in extjs 6.2 form fields in widgetcolumns get parsed in a form
which is not what we want here, because we have a hidden field, which
gets generated on a change
Dominik Csapak [Tue, 28 Feb 2017 11:06:45 +0000 (12:06 +0100)]
use login instead of bash
since bash does not play well with utf8 encoded input,
eg. pressing ALTGR + M on an english intl keyboard layout int novnc
does not enter the mu symbol but makes bash think you pressed alt+5,
we should use login without authorization when logging in as root
Dominik Csapak [Fri, 3 Mar 2017 09:17:25 +0000 (10:17 +0100)]
add css fix for chrome >=56
with chrome/chromium version 56, they changed the way how they calculate
height of text in input fields (now it is correct according to the
standard) but extjs up to 6.2.1 has a fix for this in css
this patch reverses the fix in extjs and can be reverted when they
remove the fix upstream
the bug (EXTJS-23628) and the fix are described here:
https://www.sencha.com/forum/showthread.php?335045
Thomas Lamprecht [Fri, 24 Feb 2017 09:47:03 +0000 (10:47 +0100)]
migrateall: use get_filtered_vmlist
instead of using get_start_stop_list in a rather hacky way use the
new get_filtered_vmlist method and adapt the loop, as now only one
level is required.
most changes are just an indent shift left as we lost an unnecessary
loop level
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
Thomas Lamprecht [Fri, 24 Feb 2017 09:47:02 +0000 (10:47 +0100)]
refactor get_start_stop_list
we used get_start_stop_list for assembling a list of VMIDs for
stopall, startall and migrateall.
While get_start_stop_list did already some filtering we did some
more in the specific startall and stopall calls.
Add a new private helper which does all the filtering and just
assemble the startup order in the get_start_stop_list method.
Move the template and ha managed filtering in the new
get_filtered_vmlist method, this allows us to remove the filtering
from the API calls them self and we do not load the vms config twice
(it was cached, but nonetheless unnecessary)
get_filtered_vmlist is also intended to be used by migrateall in a
next patch
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>