From: Davide Marchi <danjde@msw.it>
To: dm-crypt@saout.de
Subject: Re: [dm-crypt] Encrypting DVD or CDROM from iso
Date: Thu, 19 Nov 2020 14:05:41 +0100 [thread overview]
Message-ID: <cb8d477a5346799df178c3ce8ce0b38c@msw.it> (raw)
In-Reply-To: <mailman.1.1605783602.13300.dm-crypt@saout.de>
Milan Broz ha scritto:
> [..]
> The whole problem was that the size of device was wrongly calculated
> from the debug:
> > # Device size 16777216, offset 16777216.
>
> This is apparently device size covering only LUKS2 header (default
> LUKS2 takes 16MB),
> no data at all - then the error is expected.
Ok ..but, not shure to have understand correctly :-\
>> [..]
>>
>> All you need to do here is just to allocate requested size for data +
>> 16M for header.
>> (I have no idea why the original post tries to do is such complicated
>> way.)
>>
>> Also you do not need to physically write the file, sparse file
>> creation is much
>> faster here (try sizes in GB), just run (dd can do this using seek=...
>> option too)
>> truncate disk.img -s 100M
>>
Right!
>> [..]
> [..]
>
> just run "cryptsetup luksFormat disk.img" and "cryptsetup open disk.img
> mybackupdisk"
>
>> [..]
>> genisoimage -R -J -joliet-long -graft-points -V $VOL_NAME -o
>> /dev/mapper/mybackupdisk $DIR_TO_COPY
> This losetup is automatic on luksClose (so not needed) if you remove
> explicit loop allocation above.
>> # close the device
>> cryptsetup luksClose /dev/mapper/mybackupdisk && \
>> losetup -d /dev/loop1
>
> This losetup is automatic on luksClose (so not needed) if you remove
> explicit loop allocation above.
>
> Milan
>
Fine, nevertheless, the problem is still there!
Indeed building a DVD (or CDROM) with this procedure, obtain the same
block error:
> Nov 19 13:56:36 localhost colord-sane: io/hpmud/pp.c 627: unable to
> read device-id ret=-1
> Nov 19 13:57:05 localhost kernel: [ 2470.017097] device-mapper: table:
> 253:2: len=2093055 not aligned to h/w logical block size 2048 of sr2
> Nov 19 13:57:05 localhost kernel: [ 2470.017099] device-mapper: core:
> Cannot calculate initial queue limits
> Nov 19 13:57:05 localhost kernel: [ 2470.017102] device-mapper: ioctl:
> unable to set up device queue for new table.
> Nov 19 13:57:05 localhost gnome-shell[2243]: Unable to mount volume
> Volume cifrato da 1,7 GB: Gio.IOErrorEnum: Error unlocking /dev/sr2:
> Failed to activate device: Invalid argument
What I should do for create an iso aligned to h/w logical block size?
:-\
I've try using Gnome Shell automount and manually, same!
I'm going out crazy!! :-D
Thanks again!
Davide
next parent reply other threads:[~2020-11-19 13:06 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <mailman.1.1605783602.13300.dm-crypt@saout.de>
2020-11-19 13:05 ` Davide Marchi [this message]
2020-11-18 17:25 [dm-crypt] Encrypting DVD or CDROM from iso Davide Marchi
2020-11-18 18:03 ` Milan Broz
-- strict thread matches above, loose matches on Subject: below --
2020-11-18 14:59 Davide Marchi
2020-11-10 16:22 Davide Marchi
2020-11-10 16:59 ` Ondrej Kozina
2020-11-11 19:16 ` Carlos E. R.
2020-11-12 9:36 ` Milan Broz
2020-11-12 10:08 ` Carlos E. R.
2020-11-12 9:32 ` Milan Broz
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=cb8d477a5346799df178c3ce8ce0b38c@msw.it \
--to=danjde@msw.it \
--cc=dm-crypt@saout.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).