[pve-devel] [PATCH Storage] Boost LVM Migration Speed

2016-12-23 Thread jlavoy
See commit message.

jlavoy (1):
  Boost LVM Migration Speed. This speeds up host to host LVM migration
to be more in line with what you see using qcows or raw files.

 PVE/Storage.pm | 8 
 1 file changed, 4 insertions(+), 4 deletions(-)

-- 
2.10.2

___
pve-devel mailing list
pve-devel@pve.proxmox.com
http://pve.proxmox.com/cgi-bin/mailman/listinfo/pve-devel


[pve-devel] [PATCH Storage] Boot LVM Migration Speed

2016-12-23 Thread jlavoy
Boost LVM Migration Speed. This speeds up host to
 host LVM migration to be more in line with what you see using qcows or raw
 files.

Signed-off-by: jlavoy 
---
 PVE/Storage.pm | 8 
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/PVE/Storage.pm b/PVE/Storage.pm
index a904f4e..71b699c 100755
--- a/PVE/Storage.pm
+++ b/PVE/Storage.pm
@@ -613,11 +613,11 @@ sub storage_migrate {
 
eval {
if ($tcfg->{type} eq 'lvmthin') {
-   run_command([["dd", "if=$src"],["/usr/bin/ssh", 
"root\@${target_host}",
- "dd", 'conv=sparse', "of=$dst"]]);
+   run_command([["dd", "if=$src", "bs=4k"],["/usr/bin/ssh", 
"root\@${target_host}",
+ "dd", 'conv=sparse', "of=$dst", "bs=4k"]]);
} else {
-   run_command([["dd", "if=$src"],["/usr/bin/ssh", 
"root\@${target_host}",
- "dd", "of=$dst"]]);
+   run_command([["dd", "if=$src", "bs=4k"],["/usr/bin/ssh", 
"root\@${target_host}",
+ "dd", "of=$dst", "bs=4k"]]);
}
};
if (my $err = $@) {
-- 
2.10.2

___
pve-devel mailing list
pve-devel@pve.proxmox.com
http://pve.proxmox.com/cgi-bin/mailman/listinfo/pve-devel


[pve-devel] [PATCH] Increases the dd read/write speed when migrating LVM disks. This should bring LVM migration speed up to match that of rsyncing qcows.

2016-08-23 Thread jlavoy
For example:
```
abrams Code # time dd if=1GB.file |ssh mary "dd of=/root/1GB.file"
2097152+0 records in
2097152+0 records out
1073741824 bytes (1.1 GB) copied, 34.0764 s, 31.5 MB/s
2097152+0 records in
2097152+0 records out
1073741824 bytes (1.1 GB) copied, 33.9548 s, 31.6 MB/s

real0m34.079s
user0m16.284s
sys 0m45.384s
abrams Code # time dd if=1GB.file bs=64M |ssh mary "dd of=/root/1GB.file
bs=64M"
16+0 records in
16+0 records out
1073741824 bytes (1.1 GB) copied, 10.6471 s, 101 MB/s
0+65517 records in
0+65517 records out
1073741824 bytes (1.1 GB) copied, 10.5291 s, 102 MB/s

real0m10.652s
user0m7.477s
sys 0m3.016s
```

Signed-off-by: jlavoy 
---
 PVE/Storage.pm | 8 
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/PVE/Storage.pm b/PVE/Storage.pm
index 25ff545..42b6423 100755
--- a/PVE/Storage.pm
+++ b/PVE/Storage.pm
@@ -559,11 +559,11 @@ sub storage_migrate {
 
eval {
if ($tcfg->{type} eq 'lvmthin') {
-   run_command([["dd", "if=$src"],["/usr/bin/ssh", 
"root\@${target_host}",
- "dd", 'conv=sparse', "of=$dst"]]);
+   run_command([["dd", "if=$src", "bs=64M"],["/usr/bin/ssh", 
"root\@${target_host}",
+ "dd", 'conv=sparse', "of=$dst", "bs=64M"]]);
} else {
-   run_command([["dd", "if=$src"],["/usr/bin/ssh", 
"root\@${target_host}",
- "dd", "of=$dst"]]);
+   run_command([["dd", "if=$src", "bs=64M"],["/usr/bin/ssh", 
"root\@${target_host}",
+ "dd", "of=$dst", "bs=64M"]]);
}
};
if (my $err = $@) {
-- 
2.7.3

___
pve-devel mailing list
pve-devel@pve.proxmox.com
http://pve.proxmox.com/cgi-bin/mailman/listinfo/pve-devel