]> git.proxmox.com Git - pve-guest-common.git/log
pve-guest-common.git
6 years agobump version to 2.0-7
Dietmar Maurer [Wed, 28 Jun 2017 10:47:05 +0000 (12:47 +0200)]
bump version to 2.0-7

6 years agofix previous commit
Dietmar Maurer [Wed, 28 Jun 2017 10:05:18 +0000 (12:05 +0200)]
fix previous commit

6 years agoreplication: improve schedule_job_now
Dietmar Maurer [Wed, 28 Jun 2017 10:00:25 +0000 (12:00 +0200)]
replication: improve schedule_job_now

do no not modify anything if there is no state

6 years agoreplication: add schedule_job_now helper
Wolfgang Bumiller [Wed, 28 Jun 2017 09:35:06 +0000 (11:35 +0200)]
replication: add schedule_job_now helper

6 years agoreplication: sort time stamps numerically
Wolfgang Bumiller [Wed, 28 Jun 2017 07:02:29 +0000 (09:02 +0200)]
replication: sort time stamps numerically

6 years agoreplication: pass $noerr to run_replication_nolock
Dietmar Maurer [Wed, 28 Jun 2017 05:54:11 +0000 (07:54 +0200)]
replication: pass $noerr to run_replication_nolock

6 years agoAdd new function delete_guest_states.
Wolfgang Link [Tue, 27 Jun 2017 10:20:23 +0000 (12:20 +0200)]
Add new function delete_guest_states.

6 years agoreplication: don't sync to offline targets on error states
Wolfgang Bumiller [Tue, 27 Jun 2017 08:53:13 +0000 (10:53 +0200)]
replication: don't sync to offline targets on error states

There's no point in trying to replicate to a target node
which is offline. Note that if we're not already in an
error state we do still give it a try in order for this to
get logged as an error at least once.

6 years agoreplication: keep retrying every 30 minutes in error state
Wolfgang Bumiller [Tue, 27 Jun 2017 08:53:12 +0000 (10:53 +0200)]
replication: keep retrying every 30 minutes in error state

Otherwise we never get out of it.

6 years agoPVE::ReplicationState - cleanup job state on job removal
Dietmar Maurer [Tue, 27 Jun 2017 09:41:44 +0000 (11:41 +0200)]
PVE::ReplicationState - cleanup job state on job removal

Signed-off-by: Dietmar Maurer <dietmar@proxmox.com>
6 years agoPVE::ReplicationState::purge_old_states - new helper
Dietmar Maurer [Tue, 27 Jun 2017 08:15:01 +0000 (10:15 +0200)]
PVE::ReplicationState::purge_old_states - new helper

6 years agoPVE::ReplicationState::write_job_state - allow to remove state completely
Dietmar Maurer [Tue, 27 Jun 2017 06:13:36 +0000 (08:13 +0200)]
PVE::ReplicationState::write_job_state - allow to remove state completely

6 years agoPVE/Replication.pm: also log when we thaw the filesystem
Dietmar Maurer [Fri, 23 Jun 2017 11:18:08 +0000 (13:18 +0200)]
PVE/Replication.pm: also log when we thaw the filesystem

6 years agobump version to 2.0-6
Dietmar Maurer [Thu, 22 Jun 2017 11:05:10 +0000 (13:05 +0200)]
bump version to 2.0-6

6 years agochange replica log timestamp to a human readable format
Dominik Csapak [Tue, 20 Jun 2017 12:27:23 +0000 (14:27 +0200)]
change replica log timestamp to a human readable format

modeled after the timestamps in vm migration

this does not impact the regression tests, because they
overwrite 'get_log_time' anyway

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
6 years agobump version to 2.0-5
Dietmar Maurer [Thu, 22 Jun 2017 06:44:18 +0000 (08:44 +0200)]
bump version to 2.0-5

6 years agoPVE::AbstractMigrate - new helpers to handle replication jobs
Dietmar Maurer [Wed, 21 Jun 2017 10:24:57 +0000 (12:24 +0200)]
PVE::AbstractMigrate - new helpers to handle replication jobs

6 years agoPVE::ReplicationState::extract_vmid_tranfer_state - new helper
Dietmar Maurer [Wed, 21 Jun 2017 10:24:06 +0000 (12:24 +0200)]
PVE::ReplicationState::extract_vmid_tranfer_state - new helper

moved from PVE::QemuMigrate

6 years agoPVE::ReplicationConfig::switch_replication_job_target - new helper
Dietmar Maurer [Wed, 21 Jun 2017 09:43:24 +0000 (11:43 +0200)]
PVE::ReplicationConfig::switch_replication_job_target - new helper

moved from PVE::QemuMigrate

6 years agoPVE/ReplicationConfig.pm: store job id inside job config
Dietmar Maurer [Tue, 20 Jun 2017 11:19:53 +0000 (13:19 +0200)]
PVE/ReplicationConfig.pm: store job id inside job config

To simplify code.

6 years agoPVE::Replication::run_replication - add verbose parameter
Dietmar Maurer [Tue, 20 Jun 2017 06:54:01 +0000 (08:54 +0200)]
PVE::Replication::run_replication - add verbose parameter

used for regression tests

6 years agoPVE::Replication::run_replication - return replicated $volumes
Dietmar Maurer [Tue, 20 Jun 2017 06:51:08 +0000 (08:51 +0200)]
PVE::Replication::run_replication - return replicated $volumes

6 years agoPVE::ReplicationState - new helpers record_job_start/record_job_end
Dietmar Maurer [Tue, 20 Jun 2017 04:53:36 +0000 (06:53 +0200)]
PVE::ReplicationState - new helpers record_job_start/record_job_end

6 years agoPVE::Replication::find_common_replication_snapshot - new helper
Dietmar Maurer [Tue, 20 Jun 2017 04:17:27 +0000 (06:17 +0200)]
PVE::Replication::find_common_replication_snapshot - new helper

This is just a cleanup (simply factor out code from replicate()).

6 years agoPVE::ReplicationConfig::find_local_replication_job - new helper
Dietmar Maurer [Mon, 19 Jun 2017 14:06:55 +0000 (16:06 +0200)]
PVE::ReplicationConfig::find_local_replication_job - new helper

6 years agoreplication: replicate_volume: rate can be undefined
Wolfgang Bumiller [Wed, 14 Jun 2017 08:23:51 +0000 (10:23 +0200)]
replication: replicate_volume: rate can be undefined

as it is optional in which case we want to pass undef to
stogae_migrate

6 years agoreplicate_volume: implement rate limit and insecure
Dietmar Maurer [Wed, 14 Jun 2017 06:44:13 +0000 (08:44 +0200)]
replicate_volume: implement rate limit and insecure

6 years agocall get_replicatable_volumes with $vmid parameter
Dietmar Maurer [Tue, 13 Jun 2017 07:17:50 +0000 (09:17 +0200)]
call get_replicatable_volumes with $vmid parameter

6 years agoget_replicatable_volumes: add $vmid parameter
Dietmar Maurer [Tue, 13 Jun 2017 07:00:24 +0000 (09:00 +0200)]
get_replicatable_volumes: add $vmid parameter

6 years agoPVE/AbstractConfig.pm - include missing classes
Dietmar Maurer [Tue, 13 Jun 2017 04:13:39 +0000 (06:13 +0200)]
PVE/AbstractConfig.pm - include missing classes

6 years agoPVE/ReplicationState.pm: implement write_vmid_job_states
Dietmar Maurer [Mon, 12 Jun 2017 09:33:05 +0000 (11:33 +0200)]
PVE/ReplicationState.pm: implement write_vmid_job_states

Update all job states related to a specific $vmid

6 years agoMake rollback compatible with storage replica.
Wolfgang Link [Mon, 12 Jun 2017 08:38:20 +0000 (10:38 +0200)]
Make rollback compatible with storage replica.

If we rollback we have to clean up all local replication snapshots.

6 years agoPVE::Replication - pass $cleanup parameter to get_replicatable_volumes
Dietmar Maurer [Mon, 12 Jun 2017 07:05:50 +0000 (09:05 +0200)]
PVE::Replication - pass $cleanup parameter to get_replicatable_volumes

6 years agoPVE::AbstractConfig - add prototype for get_replicatable_volumes
Dietmar Maurer [Mon, 12 Jun 2017 07:03:14 +0000 (09:03 +0200)]
PVE::AbstractConfig - add prototype for get_replicatable_volumes

6 years agoPVE::Replication::prepare - allow to pass undefined $jobid
Dietmar Maurer [Mon, 12 Jun 2017 05:53:47 +0000 (07:53 +0200)]
PVE::Replication::prepare - allow to pass undefined $jobid

And remove all replication snapshots in that case. This is useful
for snapshot rollback.

6 years agoadd PVE/Replication.pm - moved from pve-manager
Dietmar Maurer [Mon, 12 Jun 2017 05:03:22 +0000 (07:03 +0200)]
add PVE/Replication.pm - moved from pve-manager

6 years agoPVE::ReplicationConfig add delete_job helper
Dietmar Maurer [Mon, 12 Jun 2017 04:35:35 +0000 (06:35 +0200)]
PVE::ReplicationConfig add delete_job helper

Moved from PVE::Replication.

6 years agoPVE::ReplicationState - add job_status, get_next_job, job_logfile_name helpers
Dietmar Maurer [Mon, 12 Jun 2017 04:17:14 +0000 (06:17 +0200)]
PVE::ReplicationState - add job_status, get_next_job, job_logfile_name helpers

Moved code from PVE::Replication.

6 years agomigrate: set migration_type
Wolfgang Bumiller [Tue, 6 Jun 2017 08:04:00 +0000 (10:04 +0200)]
migrate: set migration_type

Moved from qemu-server: set $opts->{migration_type} to a
default or a value from datacenter.cfg.

6 years agoGuestHelpers: allow overriding $lockdir in test environments
Wolfgang Bumiller [Fri, 9 Jun 2017 07:55:58 +0000 (09:55 +0200)]
GuestHelpers: allow overriding $lockdir in test environments

6 years agoPVE::ReplicationConfig - set computed properties after schema verification
Dietmar Maurer [Wed, 7 Jun 2017 09:28:40 +0000 (11:28 +0200)]
PVE::ReplicationConfig -  set computed properties after schema verification

Else we get schema verification errors.

6 years agoPVE::ReplicationConfig - remove useless guest property
Dietmar Maurer [Wed, 7 Jun 2017 08:06:25 +0000 (10:06 +0200)]
PVE::ReplicationConfig - remove useless guest property

We extract it from the jobid instead.

6 years agoPVE::ReplicationState - new helper replication_snapshot_name()
Dietmar Maurer [Tue, 6 Jun 2017 09:47:38 +0000 (11:47 +0200)]
PVE::ReplicationState - new helper replication_snapshot_name()

Changed replication snapshot naming to __replicate_<jobid>_<lastsync>__
to avoid conflicts with normal snapshot names.

6 years agoPVE::ReplicationConfig - new helper parse_replication_job_id
Dietmar Maurer [Tue, 6 Jun 2017 08:37:49 +0000 (10:37 +0200)]
PVE::ReplicationConfig - new helper parse_replication_job_id

Allow job numbers 0..N

6 years agoPVE::ReplicationConfig - use new ID format "<vmid>-<num>"
Dietmar Maurer [Fri, 2 Jun 2017 10:18:41 +0000 (12:18 +0200)]
PVE::ReplicationConfig - use new ID format "<vmid>-<num>"

6 years agoPVE::ReplicationState - hold guest_migration_lock during state update
Dietmar Maurer [Fri, 2 Jun 2017 07:51:01 +0000 (09:51 +0200)]
PVE::ReplicationState - hold guest_migration_lock during state update

6 years agoPVE::ReplicationState - new helper class to read/write replication state
Dietmar Maurer [Fri, 2 Jun 2017 06:53:53 +0000 (08:53 +0200)]
PVE::ReplicationState - new helper class to read/write replication state

6 years agobump version to 2.0-4
Dietmar Maurer [Wed, 31 May 2017 07:15:52 +0000 (09:15 +0200)]
bump version to 2.0-4

6 years agoMakefile: cleanup *.buildinfo
Dietmar Maurer [Wed, 31 May 2017 05:49:56 +0000 (07:49 +0200)]
Makefile: cleanup *.buildinfo

6 years agoPVE/ReplicationConfig.pm: add remove_job property
Dietmar Maurer [Tue, 30 May 2017 10:31:47 +0000 (12:31 +0200)]
PVE/ReplicationConfig.pm: add remove_job property

6 years agoPVE::GuestHelpers::guest_migration_lock - new helper
Dietmar Maurer [Wed, 24 May 2017 05:24:34 +0000 (07:24 +0200)]
PVE::GuestHelpers::guest_migration_lock - new helper

I create a separate class for common guest helpers.
We can move more code into this class later.

6 years agoPVE::ReplicationConfig::check_for_existing_jobs - new helper
Dietmar Maurer [Tue, 23 May 2017 15:52:30 +0000 (17:52 +0200)]
PVE::ReplicationConfig::check_for_existing_jobs - new helper

We want to use that before removing a guest.

6 years agoAbstractConfig.pm: remove code for replicate configuration
Dietmar Maurer [Wed, 10 May 2017 04:16:57 +0000 (06:16 +0200)]
AbstractConfig.pm: remove code for replicate configuration

It is no longer used.

6 years agoPVE/ReplicationConfig.pm - new configuratin file for replication
Dietmar Maurer [Wed, 10 May 2017 04:14:24 +0000 (06:14 +0200)]
PVE/ReplicationConfig.pm - new configuratin file for replication

6 years agomigration: use Cluster's new get_ssh_info
Wolfgang Bumiller [Mon, 22 May 2017 10:37:05 +0000 (12:37 +0200)]
migration: use Cluster's new get_ssh_info

6 years agoAbstractConfig.pm: do not copy/store replicate parameter in snapshot config
Dietmar Maurer [Sat, 6 May 2017 08:58:24 +0000 (10:58 +0200)]
AbstractConfig.pm: do not copy/store replicate parameter in snapshot config

7 years agobump version to 2.0-3
Wolfgang Bumiller [Fri, 28 Apr 2017 11:57:08 +0000 (13:57 +0200)]
bump version to 2.0-3

7 years agoReplica parameters should be ignored by snapshot and restore.
Wolfgang Link [Mon, 24 Apr 2017 15:15:34 +0000 (17:15 +0200)]
Replica parameters should be ignored by snapshot and restore.

The replica are parameter that should not be changed by a rollback.

7 years agobump version to 2.0-2
Dietmar Maurer [Mon, 24 Apr 2017 05:41:31 +0000 (07:41 +0200)]
bump version to 2.0-2

7 years agoPVE/AbstractMigrate.pm: avoid locale specific time stamps
Dietmar Maurer [Mon, 24 Apr 2017 05:38:36 +0000 (07:38 +0200)]
PVE/AbstractMigrate.pm: avoid locale specific time stamps

7 years agobump version to 2.0-1
Fabian Grünbichler [Mon, 13 Mar 2017 10:29:29 +0000 (11:29 +0100)]
bump version to 2.0-1

7 years agobuildsys: update make upload target for stretch
Fabian Grünbichler [Mon, 13 Mar 2017 10:29:18 +0000 (11:29 +0100)]
buildsys: update make upload target for stretch

7 years agoAbstractMigrate: remove unused rsync and scp remainders
Thomas Lamprecht [Tue, 7 Mar 2017 16:57:01 +0000 (17:57 +0100)]
AbstractMigrate: remove unused rsync and scp remainders

We have no call using rsync_cmd or scp_cmd here or any child class.
The only part where rsync is used is in the
PVE::Storage::storage_migrate call, but here both the command and the
RSYNC_RSH environment variable gets assembled there locally, so clean
this up here.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
7 years agobuildsys: make job safety
Wolfgang Bumiller [Fri, 3 Feb 2017 13:44:51 +0000 (14:44 +0100)]
buildsys: make job safety

7 years agobump version to 1.0-2
Fabian Grünbichler [Wed, 25 Jan 2017 08:51:07 +0000 (09:51 +0100)]
bump version to 1.0-2

7 years agoadd packaging for VZDump base plugin
Fabian Grünbichler [Wed, 25 Jan 2017 08:50:15 +0000 (09:50 +0100)]
add packaging for VZDump base plugin

7 years agoadd VZDump base Plugin.pm
Fabian Grünbichler [Wed, 25 Jan 2017 08:49:21 +0000 (09:49 +0100)]
add VZDump base Plugin.pm

moved from pve-manager

7 years agoinitial packaging
Fabian Grünbichler [Wed, 25 Jan 2017 08:13:35 +0000 (09:13 +0100)]
initial packaging

7 years agoinitial commit
Fabian Grünbichler [Tue, 24 Jan 2017 12:59:08 +0000 (13:59 +0100)]
initial commit

AbstractConfig.pm and AbstractMigrate.pm copied from
pve-common

added use statements for PVE::Cluster and PVE::Storage to
AbstractConfig