Resize LUKS Volume(s)Extend a LUKS encrypted partition to fill diskafter adding one more physical volume and enlarging logical volume, grub failsHow to identify LVM-over-LUKS or LUKS-over-LVMHow to install Arch Linux root file system on LVM thin LVs on LUKS on GUID partitioned device?recovering LUKS partitionIs Easy-to-use Multi-factor Full Disk Encryption Available?Chainloading in LUKS on LVM from ESPIs it possible to unlock multiple LUKS devices to form a LVM at boot?I want multiple prompts to decrypt multiple hard disks which contain root filesystemUbuntu 18.04 LUKS boot problemsRename LVM group and volumes

What is the purpose of a disclaimer like "this is not legal advice"?

Is it a Cyclops number? "Nobody" knows!

Has a sovereign Communist government ever run, and conceded loss, on a fair election?

Why restrict private health insurance?

What does it take to become a wilderness skills guide as a business?

How to write a chaotic neutral protagonist and prevent my readers from thinking they are evil?

How does learning spells work when leveling a multiclass character?

Insult for someone who "doesn't know anything"

Averaging over columns while ignoring zero entries

Limpar string com Regex

Precision notation for voltmeters

Short SF story. Females use stingers to implant eggs in yearfathers

Propulsion Systems

Ultrafilters as a double dual

An Undercover Army

How to install "rounded" brake pads

I've given my players a lot of magic items. Is it reasonable for me to give them harder encounters?

Did Amazon pay $0 in taxes last year?

What exactly is the meaning of "fine wine"?

What does *dead* mean in *What do you mean, dead?*?

Short story about cities being connected by a conveyor belt

Unidentified signals on FT8 frequencies

Does the US political system, in principle, allow for a no-party system?

How would an energy-based "projectile" blow up a spaceship?



Resize LUKS Volume(s)


Extend a LUKS encrypted partition to fill diskafter adding one more physical volume and enlarging logical volume, grub failsHow to identify LVM-over-LUKS or LUKS-over-LVMHow to install Arch Linux root file system on LVM thin LVs on LUKS on GUID partitioned device?recovering LUKS partitionIs Easy-to-use Multi-factor Full Disk Encryption Available?Chainloading in LUKS on LVM from ESPIs it possible to unlock multiple LUKS devices to form a LVM at boot?I want multiple prompts to decrypt multiple hard disks which contain root filesystemUbuntu 18.04 LUKS boot problemsRename LVM group and volumes













0















I have a laptop with Arch on it, and I sized the root partition too small. Now I want to expand the partition by taking some from the home partition. I will put the details of the specifics below. My question(s) to you is



1) Am I just expanding the root? Or shrinking the home? Or is it both? If both then does order matter? I see several online tuts that sort of do them different ways. So it's confusing to me.



2) Should I follow the arch documentation exactly? It's not like other tuts I've seen which may not be distro specific. Also asking because it mentions things like make a new partition under expand, but never says anything about what to do with the old one. It would be great if you could explain this if the answer is yes.



3) Do I need to update my fstab afterwards?



4) If all goes well, I should still have my data on these partitions right? Obviously I'm backing up just to be sure.



Here are my specific details:



> df -h
Filesystem Size Used Avail Use% Mounted on
dev 7.7G 0 7.7G 0% /dev
run 7.7G 1.2M 7.7G 1% /run
/dev/mapper/archvg-root 9.8G 9.3G 0 100% /
tmpfs 7.7G 723M 7.0G 10% /dev/shm
tmpfs 7.7G 0 7.7G 0% /sys/fs/cgroup
tmpfs 7.7G 16K 7.7G 1% /tmp
/dev/nvme0n1p1 749M 62M 688M 9% /boot
/dev/mapper/archvg-home 456G 3.0G 430G 1% /home
tmpfs 1.6G 16K 1.6G 1% /run/user/1000
/dev/fuse 250G 78M 250G 1% /run/user/1000/keybase/kbfs

> lsblk
NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINT
nvme0n1 259:0 0 477G 0 disk
├─nvme0n1p1 259:1 0 750M 0 part /boot
└─nvme0n1p2 259:2 0 476.2G 0 part
└─archlv 254:0 0 476.2G 0 crypt
├─archvg-swap 254:1 0 2G 0 lvm [SWAP]
├─archvg-root 254:2 0 10G 0 lvm /
└─archvg-home 254:3 0 464.2G 0 lvm /home

> sudo pvdisplay -m
--- Physical volume ---
PV Name /dev/mapper/archlv
VG Name archvg
PV Size 476.20 GiB / not usable <1.32 MiB
Allocatable yes (but full)
PE Size 4.00 MiB
Total PE 121908
Free PE 0
Allocated PE 121908
PV UUID m11dPA-mPYo-6dLS-mXPF-V1Ww-jXuO-QXfB8e

--- Physical Segments ---
Physical extent 0 to 511:
Logical volume /dev/archvg/swap
Logical extents 0 to 511
Physical extent 512 to 3071:
Logical volume /dev/archvg/root
Logical extents 0 to 2559
Physical extent 3072 to 121907:
Logical volume /dev/archvg/home
Logical extents 0 to 118835


Here is the steps I plan on taking



Boot from a live USB

# Step 1: Clone the current partition to a new partition
> dd if=/dev/mapper/archvg-root of=/dev/mapper/archvg2-root bs=4M

# Step 2: Extend the new partition
> cryptsetup open /dev/mapper/archvg2-root archlv

# Step 3: Enlarge the PV to use all the available remaining space of the partition
> pvresize /dev/mapper/archlv

## Review
> pvdisplay -m

# Step 4: Resize /home Logical Volume (trying to make it 100G)
> lvresize -L +90.2G /dev/CryptVolumeGroup/root

## Review
> pvdisplay -m

# Step 5: Resize encrypted volume (Trying to give it some space)
> resize2fs -p /dev/CryptVolumeGroup/root 101G

# Reboot


Here are other references of other's doing this differently which I'm still looking into if they have better methods or not.




  • https://serverfault.com/questions/394902/resizing-a-luks-encrypted-volume (He's unmounting, not mentioned in Arch docs. Not sure I need to)

  • Extend a LUKS encrypted partition to fill disk


  • https://blog.tinned-software.net/increase-the-size-of-a-luks-encrypted-partition/ (seems like less steps)

If more detailed information about the specifics is helpful, please let me know and I'll update this with them.










share|improve this question




























    0















    I have a laptop with Arch on it, and I sized the root partition too small. Now I want to expand the partition by taking some from the home partition. I will put the details of the specifics below. My question(s) to you is



    1) Am I just expanding the root? Or shrinking the home? Or is it both? If both then does order matter? I see several online tuts that sort of do them different ways. So it's confusing to me.



    2) Should I follow the arch documentation exactly? It's not like other tuts I've seen which may not be distro specific. Also asking because it mentions things like make a new partition under expand, but never says anything about what to do with the old one. It would be great if you could explain this if the answer is yes.



    3) Do I need to update my fstab afterwards?



    4) If all goes well, I should still have my data on these partitions right? Obviously I'm backing up just to be sure.



    Here are my specific details:



    > df -h
    Filesystem Size Used Avail Use% Mounted on
    dev 7.7G 0 7.7G 0% /dev
    run 7.7G 1.2M 7.7G 1% /run
    /dev/mapper/archvg-root 9.8G 9.3G 0 100% /
    tmpfs 7.7G 723M 7.0G 10% /dev/shm
    tmpfs 7.7G 0 7.7G 0% /sys/fs/cgroup
    tmpfs 7.7G 16K 7.7G 1% /tmp
    /dev/nvme0n1p1 749M 62M 688M 9% /boot
    /dev/mapper/archvg-home 456G 3.0G 430G 1% /home
    tmpfs 1.6G 16K 1.6G 1% /run/user/1000
    /dev/fuse 250G 78M 250G 1% /run/user/1000/keybase/kbfs

    > lsblk
    NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINT
    nvme0n1 259:0 0 477G 0 disk
    ├─nvme0n1p1 259:1 0 750M 0 part /boot
    └─nvme0n1p2 259:2 0 476.2G 0 part
    └─archlv 254:0 0 476.2G 0 crypt
    ├─archvg-swap 254:1 0 2G 0 lvm [SWAP]
    ├─archvg-root 254:2 0 10G 0 lvm /
    └─archvg-home 254:3 0 464.2G 0 lvm /home

    > sudo pvdisplay -m
    --- Physical volume ---
    PV Name /dev/mapper/archlv
    VG Name archvg
    PV Size 476.20 GiB / not usable <1.32 MiB
    Allocatable yes (but full)
    PE Size 4.00 MiB
    Total PE 121908
    Free PE 0
    Allocated PE 121908
    PV UUID m11dPA-mPYo-6dLS-mXPF-V1Ww-jXuO-QXfB8e

    --- Physical Segments ---
    Physical extent 0 to 511:
    Logical volume /dev/archvg/swap
    Logical extents 0 to 511
    Physical extent 512 to 3071:
    Logical volume /dev/archvg/root
    Logical extents 0 to 2559
    Physical extent 3072 to 121907:
    Logical volume /dev/archvg/home
    Logical extents 0 to 118835


    Here is the steps I plan on taking



    Boot from a live USB

    # Step 1: Clone the current partition to a new partition
    > dd if=/dev/mapper/archvg-root of=/dev/mapper/archvg2-root bs=4M

    # Step 2: Extend the new partition
    > cryptsetup open /dev/mapper/archvg2-root archlv

    # Step 3: Enlarge the PV to use all the available remaining space of the partition
    > pvresize /dev/mapper/archlv

    ## Review
    > pvdisplay -m

    # Step 4: Resize /home Logical Volume (trying to make it 100G)
    > lvresize -L +90.2G /dev/CryptVolumeGroup/root

    ## Review
    > pvdisplay -m

    # Step 5: Resize encrypted volume (Trying to give it some space)
    > resize2fs -p /dev/CryptVolumeGroup/root 101G

    # Reboot


    Here are other references of other's doing this differently which I'm still looking into if they have better methods or not.




    • https://serverfault.com/questions/394902/resizing-a-luks-encrypted-volume (He's unmounting, not mentioned in Arch docs. Not sure I need to)

    • Extend a LUKS encrypted partition to fill disk


    • https://blog.tinned-software.net/increase-the-size-of-a-luks-encrypted-partition/ (seems like less steps)

    If more detailed information about the specifics is helpful, please let me know and I'll update this with them.










    share|improve this question


























      0












      0








      0








      I have a laptop with Arch on it, and I sized the root partition too small. Now I want to expand the partition by taking some from the home partition. I will put the details of the specifics below. My question(s) to you is



      1) Am I just expanding the root? Or shrinking the home? Or is it both? If both then does order matter? I see several online tuts that sort of do them different ways. So it's confusing to me.



      2) Should I follow the arch documentation exactly? It's not like other tuts I've seen which may not be distro specific. Also asking because it mentions things like make a new partition under expand, but never says anything about what to do with the old one. It would be great if you could explain this if the answer is yes.



      3) Do I need to update my fstab afterwards?



      4) If all goes well, I should still have my data on these partitions right? Obviously I'm backing up just to be sure.



      Here are my specific details:



      > df -h
      Filesystem Size Used Avail Use% Mounted on
      dev 7.7G 0 7.7G 0% /dev
      run 7.7G 1.2M 7.7G 1% /run
      /dev/mapper/archvg-root 9.8G 9.3G 0 100% /
      tmpfs 7.7G 723M 7.0G 10% /dev/shm
      tmpfs 7.7G 0 7.7G 0% /sys/fs/cgroup
      tmpfs 7.7G 16K 7.7G 1% /tmp
      /dev/nvme0n1p1 749M 62M 688M 9% /boot
      /dev/mapper/archvg-home 456G 3.0G 430G 1% /home
      tmpfs 1.6G 16K 1.6G 1% /run/user/1000
      /dev/fuse 250G 78M 250G 1% /run/user/1000/keybase/kbfs

      > lsblk
      NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINT
      nvme0n1 259:0 0 477G 0 disk
      ├─nvme0n1p1 259:1 0 750M 0 part /boot
      └─nvme0n1p2 259:2 0 476.2G 0 part
      └─archlv 254:0 0 476.2G 0 crypt
      ├─archvg-swap 254:1 0 2G 0 lvm [SWAP]
      ├─archvg-root 254:2 0 10G 0 lvm /
      └─archvg-home 254:3 0 464.2G 0 lvm /home

      > sudo pvdisplay -m
      --- Physical volume ---
      PV Name /dev/mapper/archlv
      VG Name archvg
      PV Size 476.20 GiB / not usable <1.32 MiB
      Allocatable yes (but full)
      PE Size 4.00 MiB
      Total PE 121908
      Free PE 0
      Allocated PE 121908
      PV UUID m11dPA-mPYo-6dLS-mXPF-V1Ww-jXuO-QXfB8e

      --- Physical Segments ---
      Physical extent 0 to 511:
      Logical volume /dev/archvg/swap
      Logical extents 0 to 511
      Physical extent 512 to 3071:
      Logical volume /dev/archvg/root
      Logical extents 0 to 2559
      Physical extent 3072 to 121907:
      Logical volume /dev/archvg/home
      Logical extents 0 to 118835


      Here is the steps I plan on taking



      Boot from a live USB

      # Step 1: Clone the current partition to a new partition
      > dd if=/dev/mapper/archvg-root of=/dev/mapper/archvg2-root bs=4M

      # Step 2: Extend the new partition
      > cryptsetup open /dev/mapper/archvg2-root archlv

      # Step 3: Enlarge the PV to use all the available remaining space of the partition
      > pvresize /dev/mapper/archlv

      ## Review
      > pvdisplay -m

      # Step 4: Resize /home Logical Volume (trying to make it 100G)
      > lvresize -L +90.2G /dev/CryptVolumeGroup/root

      ## Review
      > pvdisplay -m

      # Step 5: Resize encrypted volume (Trying to give it some space)
      > resize2fs -p /dev/CryptVolumeGroup/root 101G

      # Reboot


      Here are other references of other's doing this differently which I'm still looking into if they have better methods or not.




      • https://serverfault.com/questions/394902/resizing-a-luks-encrypted-volume (He's unmounting, not mentioned in Arch docs. Not sure I need to)

      • Extend a LUKS encrypted partition to fill disk


      • https://blog.tinned-software.net/increase-the-size-of-a-luks-encrypted-partition/ (seems like less steps)

      If more detailed information about the specifics is helpful, please let me know and I'll update this with them.










      share|improve this question
















      I have a laptop with Arch on it, and I sized the root partition too small. Now I want to expand the partition by taking some from the home partition. I will put the details of the specifics below. My question(s) to you is



      1) Am I just expanding the root? Or shrinking the home? Or is it both? If both then does order matter? I see several online tuts that sort of do them different ways. So it's confusing to me.



      2) Should I follow the arch documentation exactly? It's not like other tuts I've seen which may not be distro specific. Also asking because it mentions things like make a new partition under expand, but never says anything about what to do with the old one. It would be great if you could explain this if the answer is yes.



      3) Do I need to update my fstab afterwards?



      4) If all goes well, I should still have my data on these partitions right? Obviously I'm backing up just to be sure.



      Here are my specific details:



      > df -h
      Filesystem Size Used Avail Use% Mounted on
      dev 7.7G 0 7.7G 0% /dev
      run 7.7G 1.2M 7.7G 1% /run
      /dev/mapper/archvg-root 9.8G 9.3G 0 100% /
      tmpfs 7.7G 723M 7.0G 10% /dev/shm
      tmpfs 7.7G 0 7.7G 0% /sys/fs/cgroup
      tmpfs 7.7G 16K 7.7G 1% /tmp
      /dev/nvme0n1p1 749M 62M 688M 9% /boot
      /dev/mapper/archvg-home 456G 3.0G 430G 1% /home
      tmpfs 1.6G 16K 1.6G 1% /run/user/1000
      /dev/fuse 250G 78M 250G 1% /run/user/1000/keybase/kbfs

      > lsblk
      NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINT
      nvme0n1 259:0 0 477G 0 disk
      ├─nvme0n1p1 259:1 0 750M 0 part /boot
      └─nvme0n1p2 259:2 0 476.2G 0 part
      └─archlv 254:0 0 476.2G 0 crypt
      ├─archvg-swap 254:1 0 2G 0 lvm [SWAP]
      ├─archvg-root 254:2 0 10G 0 lvm /
      └─archvg-home 254:3 0 464.2G 0 lvm /home

      > sudo pvdisplay -m
      --- Physical volume ---
      PV Name /dev/mapper/archlv
      VG Name archvg
      PV Size 476.20 GiB / not usable <1.32 MiB
      Allocatable yes (but full)
      PE Size 4.00 MiB
      Total PE 121908
      Free PE 0
      Allocated PE 121908
      PV UUID m11dPA-mPYo-6dLS-mXPF-V1Ww-jXuO-QXfB8e

      --- Physical Segments ---
      Physical extent 0 to 511:
      Logical volume /dev/archvg/swap
      Logical extents 0 to 511
      Physical extent 512 to 3071:
      Logical volume /dev/archvg/root
      Logical extents 0 to 2559
      Physical extent 3072 to 121907:
      Logical volume /dev/archvg/home
      Logical extents 0 to 118835


      Here is the steps I plan on taking



      Boot from a live USB

      # Step 1: Clone the current partition to a new partition
      > dd if=/dev/mapper/archvg-root of=/dev/mapper/archvg2-root bs=4M

      # Step 2: Extend the new partition
      > cryptsetup open /dev/mapper/archvg2-root archlv

      # Step 3: Enlarge the PV to use all the available remaining space of the partition
      > pvresize /dev/mapper/archlv

      ## Review
      > pvdisplay -m

      # Step 4: Resize /home Logical Volume (trying to make it 100G)
      > lvresize -L +90.2G /dev/CryptVolumeGroup/root

      ## Review
      > pvdisplay -m

      # Step 5: Resize encrypted volume (Trying to give it some space)
      > resize2fs -p /dev/CryptVolumeGroup/root 101G

      # Reboot


      Here are other references of other's doing this differently which I'm still looking into if they have better methods or not.




      • https://serverfault.com/questions/394902/resizing-a-luks-encrypted-volume (He's unmounting, not mentioned in Arch docs. Not sure I need to)

      • Extend a LUKS encrypted partition to fill disk


      • https://blog.tinned-software.net/increase-the-size-of-a-luks-encrypted-partition/ (seems like less steps)

      If more detailed information about the specifics is helpful, please let me know and I'll update this with them.







      arch-linux luks






      share|improve this question















      share|improve this question













      share|improve this question




      share|improve this question








      edited 4 hours ago







      Byron Mansfield

















      asked 4 hours ago









      Byron MansfieldByron Mansfield

      629




      629




















          0






          active

          oldest

          votes











          Your Answer








          StackExchange.ready(function()
          var channelOptions =
          tags: "".split(" "),
          id: "106"
          ;
          initTagRenderer("".split(" "), "".split(" "), channelOptions);

          StackExchange.using("externalEditor", function()
          // Have to fire editor after snippets, if snippets enabled
          if (StackExchange.settings.snippets.snippetsEnabled)
          StackExchange.using("snippets", function()
          createEditor();
          );

          else
          createEditor();

          );

          function createEditor()
          StackExchange.prepareEditor(
          heartbeatType: 'answer',
          autoActivateHeartbeat: false,
          convertImagesToLinks: false,
          noModals: true,
          showLowRepImageUploadWarning: true,
          reputationToPostImages: null,
          bindNavPrevention: true,
          postfix: "",
          imageUploader:
          brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
          contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
          allowUrls: true
          ,
          onDemand: true,
          discardSelector: ".discard-answer"
          ,immediatelyShowMarkdownHelp:true
          );



          );













          draft saved

          draft discarded


















          StackExchange.ready(
          function ()
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f505241%2fresize-luks-volumes%23new-answer', 'question_page');

          );

          Post as a guest















          Required, but never shown

























          0






          active

          oldest

          votes








          0






          active

          oldest

          votes









          active

          oldest

          votes






          active

          oldest

          votes















          draft saved

          draft discarded
















































          Thanks for contributing an answer to Unix & Linux Stack Exchange!


          • Please be sure to answer the question. Provide details and share your research!

          But avoid


          • Asking for help, clarification, or responding to other answers.

          • Making statements based on opinion; back them up with references or personal experience.

          To learn more, see our tips on writing great answers.




          draft saved


          draft discarded














          StackExchange.ready(
          function ()
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f505241%2fresize-luks-volumes%23new-answer', 'question_page');

          );

          Post as a guest















          Required, but never shown





















































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown

































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown







          Popular posts from this blog

          Mobil Contents History Mobil brands Former Mobil brands Lukoil transaction Mobil UK Mobil Australia Mobil New Zealand Mobil Greece Mobil in Japan Mobil in Canada Mobil Egypt See also References External links Navigation menuwww.mobil.com"Mobil Corporation"the original"Our Houston campus""Business & Finance: Socony-Vacuum Corp.""Popular Mechanics""Lubrite Technologies""Exxon Mobil campus 'clearly happening'""Toledo Blade - Google News Archive Search""The Lion and the Moose - How 2 Executives Pulled off the Biggest Merger Ever""ExxonMobil Press Release""Lubricants""Archived copy"the original"Mobil 1™ and Mobil Super™ motor oil and synthetic motor oil - Mobil™ Motor Oils""Mobil Delvac""Mobil Industrial website""The State of Competition in Gasoline Marketing: The Effects of Refiner Operations at Retail""Mobil Travel Guide to become Forbes Travel Guide""Hotel Rankings: Forbes Merges with Mobil"the original"Jamieson oil industry history""Mobil news""Caltex pumps for control""Watchdog blocks Caltex bid""Exxon Mobil sells service station network""Mobil Oil New Zealand Limited is New Zealand's oldest oil company, with predecessor companies having first established a presence in the country in 1896""ExxonMobil subsidiaries have a business history in New Zealand stretching back more than 120 years. We are involved in petroleum refining and distribution and the marketing of fuels, lubricants and chemical products""Archived copy"the original"Exxon Mobil to Sell Its Japanese Arm for $3.9 Billion""Gas station merger will end Esso and Mobil's long run in Japan""Esso moves to affiliate itself with PC Optimum, no longer Aeroplan, in loyalty point switch""Mobil brand of gas stations to launch in Canada after deal for 213 Loblaws-owned locations""Mobil Nears Completion of Rebranding 200 Loblaw Gas Stations""Learn about ExxonMobil's operations in Egypt""Petrol and Diesel Service Stations in Egypt - Mobil"Official websiteExxon Mobil corporate websiteMobil Industrial official websiteeeeeeeeDA04275022275790-40000 0001 0860 5061n82045453134887257134887257

          Frič See also Navigation menuinternal link

          Identify plant with long narrow paired leaves and reddish stems Planned maintenance scheduled April 17/18, 2019 at 00:00UTC (8:00pm US/Eastern) Announcing the arrival of Valued Associate #679: Cesar Manara Unicorn Meta Zoo #1: Why another podcast?What is this plant with long sharp leaves? Is it a weed?What is this 3ft high, stalky plant, with mid sized narrow leaves?What is this young shrub with opposite ovate, crenate leaves and reddish stems?What is this plant with large broad serrated leaves?Identify this upright branching weed with long leaves and reddish stemsPlease help me identify this bulbous plant with long, broad leaves and white flowersWhat is this small annual with narrow gray/green leaves and rust colored daisy-type flowers?What is this chilli plant?Does anyone know what type of chilli plant this is?Help identify this plant