blkid not showing encrypted 2nd hard drive on reboot
Linux - ServerThis forum is for the discussion of Linux Software used in a server related context.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
blkid not showing encrypted 2nd hard drive on reboot
I have a 2 drive system. 1 SSD drive with normal CentOS stuff; encrypted.
The second hardrive is for SAMBA and has the home directories.
After set up of second drive I reboot and run blkid
I have NO Luks-.... showing up for the sdb drive.
Thanks to all in advance.
======================
I have used the following steps to do dozens of such boxes.
fdisk -l | grep '^Disk' # L not #1
cryptsetup -y -v luksFormat /dev/sdb
cryptsetup luksOpen /dev/sdb BIGDRIVE
ls -l /dev/mapper/BIGDRIVE
cryptsetup -v status BIGDRIVE
cryptsetup luksDump /dev/sdb
dd if=/dev/zero of=/dev/mapper/BIGDRIVE
mkfs.ext4 /dev/mapper/BIGDRIVE
mkdir /home/BIGDRIVE
mount /dev/mapper/BIGDRIVE /home/BIGDRIVE
df -H
cd /home/BIGDRIVE
ls -l
#### ALL TO HEAR WORKS I CAN SEE THE 1TB 2ND DRIVE
reboot
blkid
But I only get (which should be there) which on my other boxes is the first line, here on this one it is the last line on the screen:
/dev/sdb: UUID="31e49c7a-7071-4a36-a58d-9a35638e5235" TYPE="crypto_LUKS"
I should have something like this also:
/dev/mapper/luks-f28862ef-6be7-487f-80c0-aa21ce26319e: UUID="c4ccc1dc-6738-48a0-8922-afa3b7ee11fd" TYPE="ext4"
For automatic opening of encrypted partitions, you need to add the correct uuid to /etc/crypttab. Then you get a device in /dev/mapper which you can mount.
Not sure if this is systemd specific, but seeing you run CentOs, is should be what you need.
I basically understand the commands I have in the list from my notes.
The problem is a command is either missing or some upgrade to one of the programs has stop this all from working and I can NOT find out what is the Lux.. goo that need to be put in the fstab & cryptab
Sorry, I thought you were referring to blkid not reporting the ' /dev/sdb: UUID="31e49c7a-7071-4a36-a58d-9a35638e5235" TYPE="crypto_LUKS"' that the OP was expecting to see. That is data from the LUKS header, not from within the container.
I type in on every box I have out there that was setup prior to this box blkid
it give me 2 lines of code associated with SDB and 7 lines associated with SDA the OS/Boot/Swap partition which is fine.
I type in on every box I have out there that was setup prior to this box blkid
it give me 2 lines of code associated with SDB and 7 lines associated with SDA the OS/Boot/Swap partition which is fine.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.