Gentoo Archives: gentoo-user

From: Ramon Fischer <Ramon_Fischer@×××××××.de>
To: Dale <rdalek1967@×××××.com>
Cc: Gentoo User <gentoo-user@l.g.o>
Subject: Re: [gentoo-user] cryptsetup close and device in use when it is not
Date: Thu, 08 Jul 2021 08:20:11
Message-Id: AM6PR10MB24409728F845DAD43B53B0A0EF199@AM6PR10MB2440.EURPRD10.PROD.OUTLOOK.COM
In Reply to: Re: [gentoo-user] cryptsetup close and device in use when it is not by Dale
1 Interesting.
2
3 I have some other ideas, but this is really grasping at straws. Create a
4 backup of the backup drive before doing any tests, since you have to
5 move it a lot for this:
6
7 1. Connect the hard drive to a different eSATA port
8 2. Try another eSATA cable
9 3. Try to mount the hard drive on different devices
10 4. Try different hard drive cases with different connection types
11 (Maybe you have a better enclosure with USB or even FireWire, which
12 does not damage your drive?)
13 5. Connect it internally via SATA and try to mount it
14 6. Mirror the hard drive to a second hard drive and try to mount the
15 second one
16
17 I think, this would entirely cover Layer 1 of the OSI Layer Model[1]. :)
18
19 -Ramon
20
21 [1] https://en.wikipedia.org/wiki/OSI_model
22
23 On 07/07/2021 20:08, Dale wrote:
24 > Dr Rainer Woitok wrote:
25 >> Ramon, Dale,
26 >>
27 >> On Tuesday, 2021-07-06 20:40:32 +0200, Ramon Fischer wrote:
28 >>
29 >>> This is just a guess. Maybe you have two devices with the same UUID?
30 >>>
31 >>> If so, you can change it with:
32 >>>
33 >>> $ cryptsetup --uuid="<some_uuid>" luksUUID "/dev/sdx1"
34 >> Good idea. But to find out whether or not this is the cause of Dale's
35 >> problems I would suggest to first run "cryptsetup" without the "--uuid"
36 >> option (in order to get the UUID listed) and to then compare this with
37 >> the output from "ls /dev/disk/by-uuid".
38 >>
39 >> Sincerely,
40 >> Rainer
41 >>
42 >
43 > Well, it's midweek and I wanted to test this theory even tho it is
44 > early.  Plus, it's raining outside so I'm a bit bored.  I pulled the
45 > backup drive from the safe and did a backup.  While it was backing up
46 > new stuff, I ran this:
47 >
48 >
49 > root@fireball / # blkid | grep dde669
50 > /dev/mapper/8tb: LABEL="8tb-backup"
51 > UUID="0277ff1b-2d7c-451c-ae94-f20f42dde669" BLOCK_SIZE="4096" TYPE="ext4"
52 > root@fireball / # ls /dev/disk/by-uuid | grep dde669
53 > 0277ff1b-2d7c-451c-ae94-f20f42dde669
54 > root@fireball / #
55 >
56 >
57 > I just grepped the last little bit of the UUID to see if anything else
58 > matched.  It didn't.  I tried both methods just in case.  It was
59 > grasping at straws a bit but hey, sometimes that straw solves the
60 > problem.  I might add, I unmounted the drive and cryptsetup closed it
61 > first time with not a single error.  It didn't even burp.  Given I've
62 > done this several times with no problem after doing the UUID way with
63 > consistent errors, I think it is safe to assume that changing from UUID
64 > to labels solves this problem.  The question now is this, why?  It's not
65 > like one mounts something different or anything.  It's the same device,
66 > just using a different link basically.
67 >
68 > This is thoroughly confusing.  It just doesn't make sense at all.
69 > Either way should work exactly the same.
70 >
71 > I'm open to ideas on this.  Anybody have one?  I'll test it if I can
72 > even if it is a serious grasp at a small straw.  ;-)
73 >
74 > Dale
75 >
76 > :-)  :-)
77
78 --
79 GPG public key: 5983 98DA 5F4D A464 38FD CF87 155B E264 13E6 99BF

Attachments

File name MIME type
OpenPGP_signature.asc application/pgp-signature

Replies

Subject Author
Re: [gentoo-user] cryptsetup close and device in use when it is not Dale <rdalek1967@×××××.com>