* [pve-devel] [PATCH cluster/guest-common 0/3] add datacenter replication option @ 2025-06-12 13:29 Maximiliano Sandoval 2025-06-12 13:29 ` [pve-devel] [PATCH cluster 1/1] datacenter config: add replication settings Maximiliano Sandoval ` (2 more replies) 0 siblings, 3 replies; 7+ messages in thread From: Maximiliano Sandoval @ 2025-06-12 13:29 UTC (permalink / raw) To: pve-devel Similar to the migration settings. Replication jobs will fallback to the migration settings if the replication settings are not set. test-repo-1: Maximiliano Sandoval (1): datacenter config: add replication settings src/PVE/DataCenterConfig.pm | 32 +++++++++++++++++++++++++++++++- 1 file changed, 31 insertions(+), 1 deletion(-) test-repo-2: Maximiliano Sandoval (2): replication: follow datacenter replication options replication: Add used network to log output src/PVE/Replication.pm | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) Summary over all repositories: 2 files changed, 36 insertions(+), 3 deletions(-) -- Generated by git-murpp 0.8.1 _______________________________________________ pve-devel mailing list pve-devel@lists.proxmox.com https://lists.proxmox.com/cgi-bin/mailman/listinfo/pve-devel ^ permalink raw reply [flat|nested] 7+ messages in thread
* [pve-devel] [PATCH cluster 1/1] datacenter config: add replication settings 2025-06-12 13:29 [pve-devel] [PATCH cluster/guest-common 0/3] add datacenter replication option Maximiliano Sandoval @ 2025-06-12 13:29 ` Maximiliano Sandoval 2025-07-16 14:02 ` [pve-devel] applied: " Thomas Lamprecht 2025-06-12 13:29 ` [pve-devel] [PATCH guest-common 1/2] replication: follow datacenter replication options Maximiliano Sandoval 2025-06-12 13:29 ` [pve-devel] [PATCH guest-common 2/2] replication: Add used network to log output Maximiliano Sandoval 2 siblings, 1 reply; 7+ messages in thread From: Maximiliano Sandoval @ 2025-06-12 13:29 UTC (permalink / raw) To: pve-devel Adds replication settings similar to the migration settings. This allows specifying different networks and it is ultimately more straightforward than using the migration settings for replication jobs. Signed-off-by: Maximiliano Sandoval <m.sandoval@proxmox.com> --- src/PVE/DataCenterConfig.pm | 32 +++++++++++++++++++++++++++++++- 1 file changed, 31 insertions(+), 1 deletion(-) diff --git a/src/PVE/DataCenterConfig.pm b/src/PVE/DataCenterConfig.pm index 53095a1..3d15643 100644 --- a/src/PVE/DataCenterConfig.pm +++ b/src/PVE/DataCenterConfig.pm @@ -46,7 +46,27 @@ my $migration_format = { type => 'string', format => 'CIDR', format_description => 'CIDR', - description => "CIDR of the (sub) network that is used for migration and replication.", + description => "CIDR of the (sub) network that is used for migration. " + . "Used as a fallback for replications jobs if the replication network setting is not set", + }, +}; + +my $replication_format = { + type => { + default_key => 1, + type => 'string', + enum => ['secure', 'insecure'], + description => "Replication traffic is encrypted using an SSH tunnel by " + . "default. On secure, completely private networks this can be " + . "disabled to increase performance.", + default => 'secure', + }, + network => { + optional => 1, + type => 'string', + format => 'CIDR', + format_description => 'CIDR', + description => "CIDR of the (sub) network that is used for replication jobs.", }, }; @@ -352,6 +372,12 @@ my $datacenter_schema = { format => $migration_format, description => "For cluster wide migration settings.", }, + replication => { + optional => 1, + type => 'string', + format => $replication_format, + description => "For cluster wide replication settings.", + }, console => { optional => 1, type => 'string', @@ -506,6 +532,10 @@ sub parse_datacenter_config { $res->{migration} = parse_property_string($migration_format, $migration); } + if (my $replication = $res->{replication}) { + $res->{replication} = parse_property_string($replication_format, $replication); + } + if (my $next_id = $res->{'next-id'}) { $res->{'next-id'} = parse_property_string($next_id_format, $next_id); } -- 2.39.5 _______________________________________________ pve-devel mailing list pve-devel@lists.proxmox.com https://lists.proxmox.com/cgi-bin/mailman/listinfo/pve-devel ^ permalink raw reply [flat|nested] 7+ messages in thread
* [pve-devel] applied: [PATCH cluster 1/1] datacenter config: add replication settings 2025-06-12 13:29 ` [pve-devel] [PATCH cluster 1/1] datacenter config: add replication settings Maximiliano Sandoval @ 2025-07-16 14:02 ` Thomas Lamprecht 0 siblings, 0 replies; 7+ messages in thread From: Thomas Lamprecht @ 2025-07-16 14:02 UTC (permalink / raw) To: pve-devel, Maximiliano Sandoval On Thu, 12 Jun 2025 15:29:49 +0200, Maximiliano Sandoval wrote: > Adds replication settings similar to the migration settings. This allows > specifying different networks and it is ultimately more straightforward > than using the migration settings for replication jobs. > > Applied, thanks! [1/1] datacenter config: add replication settings commit: 313f034e39ae0b0bf6467242e60b5e88871f2396 _______________________________________________ pve-devel mailing list pve-devel@lists.proxmox.com https://lists.proxmox.com/cgi-bin/mailman/listinfo/pve-devel ^ permalink raw reply [flat|nested] 7+ messages in thread
* [pve-devel] [PATCH guest-common 1/2] replication: follow datacenter replication options 2025-06-12 13:29 [pve-devel] [PATCH cluster/guest-common 0/3] add datacenter replication option Maximiliano Sandoval 2025-06-12 13:29 ` [pve-devel] [PATCH cluster 1/1] datacenter config: add replication settings Maximiliano Sandoval @ 2025-06-12 13:29 ` Maximiliano Sandoval 2025-07-17 19:47 ` [pve-devel] applied: " Thomas Lamprecht 2025-06-12 13:29 ` [pve-devel] [PATCH guest-common 2/2] replication: Add used network to log output Maximiliano Sandoval 2 siblings, 1 reply; 7+ messages in thread From: Maximiliano Sandoval @ 2025-06-12 13:29 UTC (permalink / raw) To: pve-devel If set, otherwise we fall back to migration settings which was the previous behavior. Signed-off-by: Maximiliano Sandoval <m.sandoval@proxmox.com> --- src/PVE/Replication.pm | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/PVE/Replication.pm b/src/PVE/Replication.pm index 20c3485..1c2eac5 100644 --- a/src/PVE/Replication.pm +++ b/src/PVE/Replication.pm @@ -255,7 +255,10 @@ sub replicate { my $migration_network; my $migration_type = 'secure'; - if (my $mc = $dc_conf->{migration}) { + if (my $rc = $dc_conf->{replication}) { + $migration_network = $rc->{network}; + $migration_type = $rc->{type} if defined($rc->{type}); + } elsif (my $mc = $dc_conf->{migration}) { $migration_network = $mc->{network}; $migration_type = $mc->{type} if defined($mc->{type}); } -- 2.39.5 _______________________________________________ pve-devel mailing list pve-devel@lists.proxmox.com https://lists.proxmox.com/cgi-bin/mailman/listinfo/pve-devel ^ permalink raw reply [flat|nested] 7+ messages in thread
* [pve-devel] applied: [PATCH guest-common 1/2] replication: follow datacenter replication options 2025-06-12 13:29 ` [pve-devel] [PATCH guest-common 1/2] replication: follow datacenter replication options Maximiliano Sandoval @ 2025-07-17 19:47 ` Thomas Lamprecht 0 siblings, 0 replies; 7+ messages in thread From: Thomas Lamprecht @ 2025-07-17 19:47 UTC (permalink / raw) To: pve-devel, Maximiliano Sandoval On Thu, 12 Jun 2025 15:29:50 +0200, Maximiliano Sandoval wrote: > If set, otherwise we fall back to migration settings which was the > previous behavior. > > Applied, thanks! [1/2] replication: follow datacenter replication options commit: 97e6057d5749dd9f02b99bc6eed7b7ad615cc858 _______________________________________________ pve-devel mailing list pve-devel@lists.proxmox.com https://lists.proxmox.com/cgi-bin/mailman/listinfo/pve-devel ^ permalink raw reply [flat|nested] 7+ messages in thread
* [pve-devel] [PATCH guest-common 2/2] replication: Add used network to log output 2025-06-12 13:29 [pve-devel] [PATCH cluster/guest-common 0/3] add datacenter replication option Maximiliano Sandoval 2025-06-12 13:29 ` [pve-devel] [PATCH cluster 1/1] datacenter config: add replication settings Maximiliano Sandoval 2025-06-12 13:29 ` [pve-devel] [PATCH guest-common 1/2] replication: follow datacenter replication options Maximiliano Sandoval @ 2025-06-12 13:29 ` Maximiliano Sandoval 2025-07-17 19:47 ` [pve-devel] applied: " Thomas Lamprecht 2 siblings, 1 reply; 7+ messages in thread From: Maximiliano Sandoval @ 2025-06-12 13:29 UTC (permalink / raw) To: pve-devel Signed-off-by: Maximiliano Sandoval <m.sandoval@proxmox.com> --- src/PVE/Replication.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/PVE/Replication.pm b/src/PVE/Replication.pm index 1c2eac5..fb79e4b 100644 --- a/src/PVE/Replication.pm +++ b/src/PVE/Replication.pm @@ -370,7 +370,7 @@ sub replicate { my $rate = $jobcfg->{rate}; my $insecure = $migration_type eq 'insecure'; - $logfunc->("using $migration_type transmission, rate limit: " + $logfunc->("using $migration_type transmission over $migration_network, rate limit: " . ($rate ? "$rate MByte/s" : "none")); foreach my $volid (@$sorted_volids) { -- 2.39.5 _______________________________________________ pve-devel mailing list pve-devel@lists.proxmox.com https://lists.proxmox.com/cgi-bin/mailman/listinfo/pve-devel ^ permalink raw reply [flat|nested] 7+ messages in thread
* [pve-devel] applied: [PATCH guest-common 2/2] replication: Add used network to log output 2025-06-12 13:29 ` [pve-devel] [PATCH guest-common 2/2] replication: Add used network to log output Maximiliano Sandoval @ 2025-07-17 19:47 ` Thomas Lamprecht 0 siblings, 0 replies; 7+ messages in thread From: Thomas Lamprecht @ 2025-07-17 19:47 UTC (permalink / raw) To: pve-devel, Maximiliano Sandoval On Thu, 12 Jun 2025 15:29:51 +0200, Maximiliano Sandoval wrote: > Applied, thanks! [2/2] replication: Add used network to log output commit: e29569ae6ffd5a6d39752839479937f8cb7e5034 _______________________________________________ pve-devel mailing list pve-devel@lists.proxmox.com https://lists.proxmox.com/cgi-bin/mailman/listinfo/pve-devel ^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2025-07-17 19:46 UTC | newest] Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- 2025-06-12 13:29 [pve-devel] [PATCH cluster/guest-common 0/3] add datacenter replication option Maximiliano Sandoval 2025-06-12 13:29 ` [pve-devel] [PATCH cluster 1/1] datacenter config: add replication settings Maximiliano Sandoval 2025-07-16 14:02 ` [pve-devel] applied: " Thomas Lamprecht 2025-06-12 13:29 ` [pve-devel] [PATCH guest-common 1/2] replication: follow datacenter replication options Maximiliano Sandoval 2025-07-17 19:47 ` [pve-devel] applied: " Thomas Lamprecht 2025-06-12 13:29 ` [pve-devel] [PATCH guest-common 2/2] replication: Add used network to log output Maximiliano Sandoval 2025-07-17 19:47 ` [pve-devel] applied: " Thomas Lamprecht
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox