Welcome to the Linux Foundation Forum!

How can I delete this loop0 device?

Hello,
I would greatly appreciate if you could help me to untangle this node. I have this external ssd device I used to copy a raw image, but now that it lies there as a loop device I need to delete it. I tried:
losetup -d /dev/loop0 dmsetup remove -f /dev/sda1 dmsetup remove -f /dev/loop0
but no one of them worked.

Some info

They belong to the same device. df -h:
/dev/sda 938G 32K 891G 1% /mnt/0 /dev/loop0 3.6G 24K 3.4G 1% /mnt/1
To get loop0 mounted I need to mount /dev/sda1. Therefore, /dev/sda1 is the backing file of the device /dev/loop0. sudo losetup -a:
/dev/loop0: [0005]:3193 (/dev/sda1)

sudo dmsetup table:
cryptswap: 0 33553407 crypt aes-xts-plain64 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000 0 259:1 1024

cat /proc/mounts | grep loop0:
/dev/loop0 /mnt/1 ext4 rw,relatime 0 0

fuser -mv /dev/loop0:
USER PID ACCESS COMMAND /dev/loop0: root kernel mount /mnt/1

Welcome!

It looks like you're new here. Sign in or register to get started.
Sign In

Welcome!

It looks like you're new here. Sign in or register to get started.
Sign In

Categories

Upcoming Training