Skip to content

Instantly share code, notes, and snippets.

@eatnumber1
Created March 22, 2012 20:43
Show Gist options
  • Save eatnumber1/2164066 to your computer and use it in GitHub Desktop.
Save eatnumber1/2164066 to your computer and use it in GitHub Desktop.
#!/bin/zsh
set -e
set -x
## Begin group of moves that could be done in parallel
# Largest temp size 234901, desire 3422
# Moving swapA-1 (3422) (Final goal)
pvmove --alloc anywhere /dev/md2:0-3421 /dev/md1:0-3421
# Largest temp size 89514, desire 103031
# Not enough contiguous temporary room for a multipart pvmove
# Moving spaceA-5 (14163) (Final goal)
# Moving spaceA-7 (38486) (Final goal)
pvmove --alloc anywhere /dev/md3:90577-104739:104740-143225 /dev/md2:63270-77432:166947-205432
# Largest temp size 89514, desire 50382
# Moving spaceA-4 (50382) (Final goal)
pvmove --alloc anywhere /dev/md3:0-50381 /dev/md2:12888-63269
# Largest temp size 69163, desire 89514
# Not enough contiguous temporary room for a multipart pvmove
# Not enough room for any of the pvmoves. Splitting a task.
# LV split spaceA-6 (69163 + 20351 = 89514)
# Largest temp size 69163, desire 89514
# Not enough contiguous temporary room for a multipart pvmove
# Moving spaceA-6 p1 (69163) (Final goal)
pvmove --alloc anywhere /dev/md4:0-69162 /dev/md2:77433-146595
# Largest temp size 69163, desire 20351
# Moving spaceA-6 p2 (20351) (Final goal)
pvmove --alloc anywhere /dev/md4:69163-89513 /dev/md2:146596-166946
## End group
# Largest temp size 119184, desire 12888
# Moving spaceA-3 (12888) (Final goal)
pvmove --alloc anywhere /dev/md3:61175-74062 /dev/md2:0-12887
# LV split spaceA-1 (143226 + 326158 = 469384)
# LV split spaceA-1 p2 (182932 + 143226 = 326158)
# Largest temp size 119184, desire 143226
# Not enough contiguous temporary room for a multipart pvmove
# Not enough room for any of the pvmoves. Splitting a task.
# LV split spaceA-1 p2 p2 (119184 + 24042 = 143226)
# Largest temp size 119184, desire 143226
# Not enough contiguous temporary room for a multipart pvmove
# Moving spaceA-1 p2 p2 p1 (119184) (Moving away)
pvmove --alloc anywhere /dev/md1:333420-452603 /dev/md3:0-119183
# Largest temp size 119184, desire 24042
# Moving spaceA-1 p2 p2 p2 (24042) (Moving away)
pvmove --alloc anywhere /dev/md1:452604-476645 /dev/md3:119184-143225
## Begin group of moves that could be done in parallel
# Largest temp size 119184, desire 27882
# Moving spaceA-2 (3840) (Final goal)
# Moving spaceA-1 p2 p2 p2 (24042) (Final goal)
pvmove --alloc anywhere /dev/md3:143226-147065:119184-143225 /dev/md1:472806-476645:448764-472805
## End group
# LV split spaceA-1 p1 (119184 + 24042 = 143226)
# LV split spaceA-1 p2 p1 (119184 + 63748 = 182932)
# Largest temp size 115344, desire 63748
# Moving spaceA-1 p2 p1 p2 (63748) (Moving away)
pvmove --alloc anywhere /dev/md1:269672-333419 /dev/md4:55436-119183
# Largest temp size 59908, desire 119184
# Not enough contiguous temporary room for a multipart pvmove
# Not enough room for any of the pvmoves. Splitting a task.
# LV split spaceA-1 p2 p2 p1 (59908 + 59276 = 119184)
# Largest temp size 59908, desire 119184
# Not enough contiguous temporary room for a multipart pvmove
# Moving spaceA-1 p2 p2 p1 p1 (59908) (Final goal)
pvmove --alloc anywhere /dev/md3:0-59907 /dev/md1:329580-389487
# Largest temp size 59908, desire 59276
# Moving spaceA-1 p2 p2 p1 p2 (59276) (Final goal)
pvmove --alloc anywhere /dev/md3:59908-119183 /dev/md1:389488-448763
# Largest temp size 59908, desire 119184
# Not enough contiguous temporary room for a multipart pvmove
# Not enough room for any of the pvmoves. Splitting a task.
# LV split spaceA-1 p1 p1 (59908 + 59276 = 119184)
# Largest temp size 59908, desire 119184
# Not enough contiguous temporary room for a multipart pvmove
# Moving spaceA-1 p1 p1 p1 (59908) (Moving away)
pvmove --alloc anywhere /dev/md1:7262-67169 /dev/md3:59628-119535
# Largest temp size 63748, desire 59276
# Moving spaceA-1 p1 p1 p2 (59276) (Moving away)
pvmove --alloc anywhere /dev/md1:67170-126445 /dev/md3:119536-178811
## Begin group of moves that could be done in parallel
# Largest temp size 59908, desire 119184
# Not enough contiguous temporary room for a multipart pvmove
# Moving spaceA-1 p1 p1 p2 (59276) (Final goal)
pvmove --alloc anywhere /dev/md3:119536-178811 /dev/md1:63330-122605
# Largest temp size 59908, desire 59908
# Moving spaceA-1 p1 p1 p1 (59908) (Final goal)
pvmove --alloc anywhere /dev/md3:59628-119535 /dev/md1:3422-63329
## End group
# Largest temp size 178812, desire 24042
# Moving spaceA-1 p1 p2 (24042) (Moving away)
pvmove --alloc anywhere /dev/md1:126446-150487 /dev/md2:214281-238322
# Largest temp size 178812, desire 24042
# Moving spaceA-1 p1 p2 (24042) (Final goal)
pvmove --alloc anywhere /dev/md2:214281-238322 /dev/md1:122606-146647
# Largest temp size 59908, desire 119184
# Not enough contiguous temporary room for a multipart pvmove
# Not enough room for any of the pvmoves. Splitting a task.
# LV split spaceA-1 p2 p1 p1 (59908 + 59276 = 119184)
# Largest temp size 59908, desire 119184
# Not enough contiguous temporary room for a multipart pvmove
# Moving spaceA-1 p2 p1 p1 p1 (59908) (Moving away)
pvmove --alloc anywhere /dev/md1:150488-210395 /dev/md3:59628-119535
# Largest temp size 63748, desire 59276
# Moving spaceA-1 p2 p1 p1 p2 (59276) (Moving away)
pvmove --alloc anywhere /dev/md1:210396-269671 /dev/md3:119536-178811
## Begin group of moves that could be done in parallel
# Largest temp size 63748, desire 119184
# Not enough contiguous temporary room for a multipart pvmove
# Moving spaceA-1 p2 p1 p1 p2 (59276) (Final goal)
pvmove --alloc anywhere /dev/md3:119536-178811 /dev/md1:206556-265831
# Largest temp size 63748, desire 59908
# Moving spaceA-1 p2 p1 p1 p1 (59908) (Final goal)
pvmove --alloc anywhere /dev/md3:59628-119535 /dev/md1:146648-206555
# Largest temp size 178812, desire 63748
# Moving spaceA-1 p2 p1 p2 (63748) (Final goal)
pvmove --alloc anywhere /dev/md4:55436-119183 /dev/md1:265832-329579
## End group
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment