archlinux / archinstall

Arch Linux installer - guided, templates etc.
GNU General Public License v3.0
6.36k stars 545 forks source link

LVM + btrfs error #2794

Closed aurorarissime closed 2 weeks ago

aurorarissime commented 2 weeks ago

It's better to make a separate issue for this error. Here is again the crash log! https://0x0.st/XDM7.log

Torxed commented 2 weeks ago

Thank you for submitting the issue. I'm wondering if this is related but not duplicate of #2793

aurorarissime commented 2 weeks ago

I see some lines (like btrfs-prog-6.11) that are common to this issue, but the error isn't the same. And it looks like yours is at least able to do some things like creating and mounting partitions before throwing the error..? Mine throws it instantly, I think before being able to do anything with the disk. But honestly I can't tell if they are that much related

Torxed commented 2 weeks ago

I agree, but was thinking they might be related in terms of disk operations not working properly. But most likely they are different in terms of where the issue is and how to solve it.

But will find the issue and fix it :)

svartkanin commented 2 weeks ago

@Antonio-HOS this is not the same problem, please refer to the right issue types

svartkanin commented 2 weeks ago

@Alixxx-please I've run an installation with your setup and well it went fine

Unmounting all existing partitions: /dev/loop0
Unmounting: /dev/loop0p1
Partition /dev/loop0p1 is currently mounted at: ['/mnt/archinstall/boot']
Unmounting mountpoint: /mnt/archinstall/boot
Unmounting: /dev/loop0p2
Partition /dev/loop0p2 is currently mounted at: ['/mnt/archinstall']
Unmounting mountpoint: /mnt/archinstall
Unmounting: /dev/loop0p3
Wiping partitions and metadata: /dev/loop0
Creating partitions: /dev/loop0
    Type: primary
    Filesystem: fat32
    Geometry: 2048 start sector, 2097152 length
    Type: primary
    Filesystem: btrfs
    Geometry: 2099200 start sector, 123727872 length
Formatting boot partition: /dev/loop0p1
Formatting filesystem: mkfs.fat -F 32 /dev/loop0p1
partition information found: {'name': 'loop0p1', 'path': '/dev/loop0p1', 'pkname': 'loop0', 'size': '1024 MiB', 'log_sec': 512, 'pttype': 'gpt', 'ptuuid': '9d186786-61fa-4650-877a-f885bfb42c5f', 'rota': False, 'tran': None, 'partn': 1, 'partuuid': '73c2ba32-1478-4fb0-995e-a6fa0371f0c9', 'parttype': 'c12a7328-f81f-11d2-ba4b-00a0c93ec93b', 'uuid': 'CA85-CCF2', 'fstype': 'vfat', 'fsver': 'FAT32', 'fsavail': None, 'fsuse_percentage': None, 'type': 'part', 'mountpoint': None, 'mountpoints': [], 'fsroots': [], 'children': []}
Setting up LVM config...
Creating LVM PVS: pvcreate /dev/loop0p2
Creating LVM group: vgcreate --yes ArchinstallVg /dev/loop0p2
LVM info:   {
      "report": [
          {
              "vg": [
                  {"vg_name":"ArchinstallVg", "vg_uuid":"bgtuEl-x33o-ODJ9-xXIS-XBQA-EUFS-4fdHMZ", "vg_size":"63346573312B"}
              ]
          }
      ]
      ,
      "log": [
      ]
  }
vg: ArchinstallVg, vol: root, offset: Size(value=41871736832, unit=<Unit.B: 1>, sector_size=SectorSize(value=512, unit=<Unit.B: 1>))
Creating volume: lvcreate --yes -L 20396900352B ArchinstallVg -n root
Fetching LVM volume info
LVM info:   {
      "report": [
          {
              "lv": [
                  {"lv_name":"root", "vg_name":"ArchinstallVg", "lv_attr":"-wi-a-----", "lv_size":"20396900352B", "pool_lv":"", "origin":"", "data_percent":"", "metadata_percent":"", "move_pv":"", "mirror_log":"", "copy_percent":"", "convert_lv":""}
              ]
          }
      ]
      ,
      "log": [
      ]
  }
Formatting filesystem: mkfs.btrfs -f /dev/ArchinstallVg/root
Creating subvolumes: /dev/ArchinstallVg/root
Mounting /dev/ArchinstallVg/root: mount /dev/ArchinstallVg/root /mnt/arch_btrfs
Creating subvolume: @
Creating subvolume: @home
Creating subvolume: @log
Creating subvolume: @pkg
Creating subvolume: @.snapshots
Partition /dev/ArchinstallVg/root is currently mounted at: ['/mnt/arch_btrfs']
Unmounting mountpoint: /mnt/arch_btrfs

After you receive the error, could you run lvdisplay /dev/ArchinstallVg/root which should display something like

lvdisplay /dev/ArchinstallVg/root 
  --- Logical volume ---
  LV Path                /dev/ArchinstallVg/root
  LV Name                root
  VG Name                ArchinstallVg
  LV UUID                pWo3pQ-2BcO-WqK9-ZEPD-vFAk-NEEF-IH00ix
  LV Write Access        read/write
  LV Creation host, time nazgul, 2024-11-10 09:05:28 +1100
  LV Status              available
  # open                 0
  LV Size                <19.00 GiB
  Current LE             4863
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto
  - currently set to     256
  Block device           254:1

could you then try to run the failed command manually

  /usr/bin/mkfs.btrfs -f /dev/ArchinstallVg/root

to see if that works

aurorarissime commented 2 weeks ago

Sure thing! You will get your answer very soon. Thanks a lot πŸ™‚

aurorarissime commented 2 weeks ago

Okay so it didn't work. I don't know how it works on your machine which replicates mine, but we'll get there eventually haha. Btw how would I share every output using 0x0.st ? The command to extract the logs doesn't include the commands I typed after the initial error. Meanwhile here is the screenshot. From what I see, the main difference is that my LV Status is NOT available. VideoCapture_20241109-232657.jpg Edit : nvme0n1, with 424GiB, is my Windows drive. I'm trying to install it on my 1TB drive, nvme1n1. Something's weird πŸ€”

svartkanin commented 2 weeks ago

Okay so the

LV Status   NOT available

seems to be the problem.

Can you try running

lvchange -ay /dev/ArchinstallVg/root

then

lvdisplay /dev/ArchinstallVg/root

should display it as

LV Status              available

and then try

/usr/bin/mkfs.btrfs -f /dev/ArchinstallVg/root

again

For output extraction:

lvdisplay /dev/ArchinstallVg/root > some_file.txt
curl -F'file=@some_file.txt' https://0x0.st
aurorarissime commented 2 weeks ago

Sorry for screenshoting again, bus as you can see it won't let me extract logs because "451 Unavailable For Legal Reasons" lol. So after the first command it complains about my device being resized, but again it is for nvme0n1, which isn't the drive I selected to install Arch. I selected nvme1n1. Maybe since the beginning it's trying to do things on the wrong drive, hence the errors? Anyway because the first command fails it obviously didn't changed the LV Status. I'm really starting to think it somehow focuses on the wrong drive, but how come..? VideoCapture_20241109-235043.jpg

svartkanin commented 2 weeks ago

interesting, could you run a

lsblk -J -O

the output will be quite long so you'll need to export that somehow with the curl. I'm not sure why the 451 though, maybe try a different filename?

aurorarissime commented 2 weeks ago

You won't believe.. It got stuck on Setting up LVM config..., it didn't throw an error right away and I hit to CTRL+C to exit this infinite loop. It looks like your previous fix isn't really working, I'm sorry πŸ˜… Anyway here is the log for the install.log (just in case it shows something different) : https://0x0.st/XD0d.log And here is the lsblk -J -O log : https://0x0.st/XD0n.log I don't remember if it was like this last time but interestingly it tried to do some things on the good drive, nvme1n1 this time! Edit : just noticed the second url was wrong. It's fixed, my bad!

aurorarissime commented 2 weeks ago

I randomly tried to install it but now, again, it throws the usual errors instantly. My computer is a wizard haha, randomly deciding to work a tiny bit better sometimes

svartkanin commented 2 weeks ago

I need to do some more testing on my end as I cannot reproduce it.

aurorarissime commented 2 weeks ago

Hey, looks like the ArchinstallVg VG is on my Windows nvme0n1 instead of the nvme1n1 I want. It says that this is a new physical volume and that it's non allocatable. Could this be the problem? https://0x0.st/Xksc.log

svartkanin commented 2 weeks ago

That looks somewhat odd yes, I went through your log but I cannot find any references how this would have happend as all commands were pointing to nvme1n1

Could you try removing the Windows device (detaching) it when you run the installation?

I've also tried a USB device I have with around 500GB and that one installs LVM just fine as well...

aurorarissime commented 2 weeks ago

Physically detaching my Windows drive? It is too deep screwed into my motherboard πŸ˜… Unless there is a command to disable it for example..?

svartkanin commented 2 weeks ago

Lets try something else first, let's cleanup that PV that isn't right and delete all VGs and LVs

aurorarissime commented 2 weeks ago

You won't believe.. So I cleaned everything up, removed and added the vg, removed partitions, LVs, pretty much everything to have a clean drive. Then I installed it and it didn't crash instantly. So I went away for a few minutes to come back to a new error, apparently pipewire failed to connect to bus..? I will try to install it again right after this error to see if it happened because of the prior commands or if it now happens everytime. And the logs, as usual : https://0x0.st/XkoX.log

Edit: Do you remember a few comments ago when I told you that I was stuck in an infinite loop on "Setting up LVM config..."? Well, guess what, I'm stuck at this step again, almost at the beginning of the installation πŸ˜… VideoCapture_20241111-140856.jpg

svartkanin commented 2 weeks ago

Great, the error for pipewire is related to https://github.com/archlinux/archinstall/issues/2764 if you don't select the audio server it should work

aurorarissime commented 2 weeks ago

Okay so I don't know if my previous commands still did something after multiple reboots but this time instead of using the latest Build Arch ISO from Github Actions, I cloned the repo with git from my live ISO, didn't select any audio server and.. IT WORKED LIKE A CHARM!! It even installed Pipewire on its own (on KDE Plasma). I've been waiting to use Arch as a daily driver for more than 2 months from now, thank you (and the others who helped!) so much, sincerely. 🫢🏻

svartkanin commented 2 weeks ago

Great! In that case I'll close this issue as the merged patch seems to have fixed the original problem