archive mirror
 help / color / mirror / Atom feed
* [linux-lvm] Cannot manage FS of thin volume
@ 2022-02-27 15:17 Viktor Trojanovic
  2022-02-28 18:22 ` Nicholas Geovanis
  0 siblings, 1 reply; 2+ messages in thread
From: Viktor Trojanovic @ 2022-02-27 15:17 UTC (permalink / raw)
  To: linux-lvm

[-- Attachment #1.1: Type: text/plain, Size: 2902 bytes --]

Hi there,

I seem to have some problems involving my LVM setup and hope I can get some
advice on this list.

I have a rather simple setup. One PV (on a RAID1-MD-Device), one VG, 3 LVs
and one thin pool that holds my Linux Containers (LXD). These container
volumes are created directly by LXD.

Yesterday, I noticed that my backups are no longer working. In order to
backup the containers, I used to do the following:

1. Make a snapshot of the container using LXD. This creates a LV snapshot.
2. Mount the snapshot.
3. Use the mount for backing up all files
4. Unmount, delete snapshot.

I remember this used to work fine. So I tried doing this step by step and
already failed at the second step. I could not mount the snapshot because
it never got even created as a device in /dev/mapper.

I thought that maybe something changed in LXD and that I had to forcefully
activate the snapshot. I then tried something with the -Ky flag but nothing
really worked. And after I rebooted the server, all of a sudden all volumes
were inactive.

With the help of a couple of internet guides, in particular this one: LVM
Transaction ID mismatch and metadata resize error – Monotok
I managed to get everything working again. So the system is booting fine,
the containers too. I can even mount the containers fine.

But something is still very wrong. For example, I tried to resize one of
the thin LVs from 10G to 20G with automatic resizing of the FS. While the
LV resizing seems to have worked fine, the FSresize did not.

This is how it looks when I try to run resize2fs on one of the containers

# resize2fs /dev/vg0/containers_cont1
resize2fs 1.44.1 (24-Mar-2018)
resize2fs: Device or resource busy while trying to open
Couldn't find valid filesystem superblock.

Here's the output of running fdisk on the volume

# fdisk /dev/mapper/vg0-containers_cont

Welcome to fdisk (util-linux 2.31.1).
Changes will remain in memory only, until you decide to write them.
Be careful before using the write command.

The old ext4 signature will be removed by a write command.

Device does not contain a recognized partition table.
Created a new DOS disklabel with disk identifier 0x174c0f1c.

It clearly looks like something is wrong. One of the steps I had to take
when following the guide mentioned above is to backup the vg and change the
id of the thin pool to another value. Maybe this messed up something else.

Though I am confused that things overall seem to work. lsblk -f recognizes
the filesystem in the thin volumes, I can mount them, I can work with them.
But I cannot resize them and I cannot seem to create snapshots
successfully. If I do and mount them, they are empty.

Any pointers would be much appreciated.


[-- Attachment #1.2: Type: text/html, Size: 3425 bytes --]

[-- Attachment #2: Type: text/plain, Size: 201 bytes --]

linux-lvm mailing list
read the LVM HOW-TO at

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2022-03-01  7:18 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-02-27 15:17 [linux-lvm] Cannot manage FS of thin volume Viktor Trojanovic
2022-02-28 18:22 ` Nicholas Geovanis

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).