View previous topic :: View next topic |
Author |
Message |
byns n00b
Joined: 01 May 2003 Posts: 29
|
Posted: Thu Aug 12, 2004 4:34 pm Post subject: Firewire cryptoloop udev dm-crypt |
|
|
I'd like to do a migration to udev and dm-crypt:
My setup:
DELL Inspiron 8100 Notebook
External 250GB Firewire Harddrive (multiple partitions)
Kernel 2.6.7 (gentoo flavored)
Where I once was:
kernel 2.4.something no devfs
a symlink in my home directory points to a autofs controlled mount
autofs tries to mount /dev/loop0
to use the loop you click a desktop icon which runs the suid wrapper in a terminal
the suid wrapper starts the rescan-scsi-bus.sh script, asks for the cryptoloop password and tries to mount sda0 as cryptoloop under /dev/loop0
when I turn of the harddrive and turn it back on everything kept working
for devfs I had to change the rescan-scsi-bus script slightly and for the kernel 2.6 I reencrypted the partition (twofish by the way)
from now on turning the external disc on and of created sdb instead of sda and if you turned it off and on again it created sdc etc. so the loop didn't work anymore
I heard udev could resolve that problem,so I migrated, but the drive's letter was still not constant on restart of the device. At least the hotplugging finally works so I don't need the rescan-scsi-bus script anymore
now I heard cryptoloop support is to stop soon (and the later 2.6 kernels' cryptoloop support was screwed up anyways even producing oopses) so I wan't to migrate to dm-crypt, hoping that I don't have to reencrypt my partitions.
So my questions are:
- How do I write an adecuate udev rule for my drive to get it mounted as sda every time and other fire wire devices as something else?
ls /sys/bus/ieee1394/devices shows 5 long hex numbers (directories) which I suspect to be the partitions of the drive and "fw-host0"
- How do I use my partitions with dm-crypt?
If anyone can help me, with one of the two problems, would like some of the scripts (wich were all stolen from other places on the web) or has a suggestion how to do all of that more elegantly with the gentoo crypto init stuff. Pls feel free to reply. _________________ -----------------------------------------
It's easier to get forgiveness for being wrong than forgiveness for being
right. |
|
Back to top |
|
|
Nate_S Guru
Joined: 18 Mar 2004 Posts: 414
|
Posted: Thu Aug 12, 2004 10:19 pm Post subject: |
|
|
for writing udev rules, search the forum as there have been a lot of threads on that
for starters
man udevinfo
also try searching for
decibal's udev primer
http://www.google.com/search?&q=writing%20udev%20rules
this should also help you
and I believe that dm-crypt can migrate cryptoloop things, but I don't remember how.
-Nate |
|
Back to top |
|
|
oumpah-pah Guru
Joined: 18 Jul 2004 Posts: 575 Location: Lausanne, Switzerland
|
Posted: Fri Aug 13, 2004 12:32 am Post subject: |
|
|
The best udev-rules-writing reference is writing udev rules by Daniel Drake. You'll sure find what you're looking for. |
|
Back to top |
|
|
byns n00b
Joined: 01 May 2003 Posts: 29
|
Posted: Fri Aug 13, 2004 3:02 pm Post subject: |
|
|
I already had a quick glimpse at both sides, but it doesn't really make clear to me what to do. Damn! I guess I'm back to "trial and error"-ing _________________ -----------------------------------------
It's easier to get forgiveness for being wrong than forgiveness for being
right. |
|
Back to top |
|
|
|