Ask your questions here.
Sat Jan 18, 2014 8:21 am
I got a new external hardisk.
It's size is 1000 GB.
That is too big for me.
I will go for 4*250
I want to encrypt the partitions
(perhaps one will be windows compatible, not sure yet)
I would want to give the partitions names, like
1) backup-main-os
2) backup-server
3) backup-laptop
4) music
What is the general workflow?
I think of using gparted, using tune2fs (?), and using the general way to encrypt partitions (cryptsetup), but i don't get it sorted what to do when.
My problems may be two: I am not that sure what to do with the hardisk yet and i am a bit confused by other problems.
Partition and encrypt doesn't seem to be a problem (right now, for me, it is, but one i would be able to get sorted on my own). When and how to name them is beyond me.
thanks.
Sat Jan 18, 2014 12:26 pm
Create the partitions with gparted or cfdisk. Don't worry about formatting a filesystem yet.
Run
- Code:
crytpsetup luksFormat <device>
cryptsetup luksOpen <device> <label>
mke2fs <options> /dev/mapper/label
You can give the filesystem a label when you run mke2fs or run e2label afterward. This is the label that might show up on your desktop when that volume is mounted.
When I plug in a usb drive, it shows up on the desktop as something like, "6.5GB_Encrypted," and then when I mount it by clicking the icon, it changes to the filesystem label. When I right-click and unmount (eject), the desktop icons go away (all the partitions on that drive). Unplug and replug is needed to get them back.
If I use pmount instead, then /dev/mapper/_dev_sdxY gets mounted at /media/sdxY. After pumount, you can pmount again without unplug/replug.
Sun Jan 19, 2014 7:13 am
One follow-up post of mine is gone (it basically said that i used gparted to create four partitions, gave them a Label, used cryptsetup - Label is gone, duh - and gparted now wouldn't support cryptsetup, so no way to give a Label that way again).
So: e2label. Thanks, let me try it.
Damn, btw, i was hoping i had a way to get a hint what is on a partition _before i decrypt and mount it (seems a bit cumbersome to go through all until i find the right one).
Sun Jan 19, 2014 7:25 am
Oh, i had to fiddle a bit, i think:
- one will have to use
"e2label /dev/mapper/disk [new-name]"
(dev/mapper/disk) for "device", neither /dev/sdb1 nor /media/disk (assuming one called /dev/sdb1 disk when decrypting it and mounting it at /media/disk)
Right?
-
I then mounted, encrypted and decrypted a bit, and it really looks as if i first have to decrypt it before getting the label.
PS: In case anyone is wondering: As of now i never used labels at all, hence the questions.
Sun Jan 19, 2014 1:44 pm
Right. The label is on the filesystem that's inside the encrypted volume, so you can't read the label until you decrypt. And I've got four or five drive icons on my desktop that say "nnGB_Encrypted" with no indication of what's inside. I don't have a solution for that, short of writing it all down on a sticky note. In fact, I can't even tell what the device name is for each of these - nothing on right-click gives information, and the sizes don't match what gparted shows.
Mon Jan 20, 2014 8:23 am
I think i got it sorted.
Using the way described by you is more help than i assumed at first (it would be more comfortable to first check which partition i have to decrypt, but it sure helps to check e2label after i decrypted to not overwrite the wrong data with rsync).
Thanks for your help and feedback.
Powered by phpBB © phpBB Group.
phpBB Mobile / SEO by Artodia.