Thanks for all the replies.
How about making it not ask for the password at bootup?
Basically I want an encrypted filesystem, but if the machine looses power and it comes back up I want the system to boot and then when I get home I will boot the encrypted partition manually.
If the /root is encrypted, you cannot bypass password in order to boot the system. But I believe you a talking about an extra hard drive.
So to not be prompted for password during boot, follow the suggestions given in the previous posts–by removing the device from your fstab–also, check your grub to make sure it is not listed there as well.
It is a second hard drive which I mount as /data2.
I already removed from fstab, but at bootup it still gets prompted for the password.
Originally when it was in fstab its entry was:
/dev/mapper/cr_sdb5 /data2 reiserfs noatime,noacl,noauto 0 0 (see NOTE)
Perhaps there is an entry related to /dev/mapper that needs to be commented?
NOTE: I don’t have the original entry anymore since I am goin to try EXT3 and the new line in fstab now reads EXT3, but it was pretty much what I have above. I am doing a backup to Amazon S3, but once that finishes later I will try to see if using EXT3 makes a difference. However I think it may be something else outside of fstab.
The filesystem in question is /dev/sdb5.
I don’t see it listed there.
Digging in google I found this directory:
/dev/mapper
There I see
brw------- 1 root 253, 1 2008-06-13 20:11 cr_sda5
brw------- 1 root 253, 0 2008-06-13 20:11 cr_sda7
brw------- 1 root 253, 2 2008-06-14 08:43 cr_sdb5
I wonder if those can be moved. I think if cr_sdb5 is not there, that it will not ask for password. Then at boot time I would move it back and mount it.
I remember *thestig *loosing a disk with a password on it. This password was asked for by the firmware (through the BIOS) at boottime. When that is the case no OS can do anything about it. You then have to go to your BIOS to remove the password from the disk.
What you can do is to tell your system not to do all the encrypted stuff at startup and just start it manually later. For that to work just run “chkconfig boot.crypto off”. This turns off the crypto-services(ie the encrypted disks and stuff). Then, when you get home, all you have to do is run “/etc/init.d/boot.crypto start” as root and give the password and you should be good.
/etc/fstab is not avery dynamic file. Nothing happens at the moment in time that you change it. It is read:
a. When you do a mount/umount of one of the items found in it when you doo not provide all of the parameters in that mount/umount statement. It add the not mentioned parameters to your (u)mount. So you can simpl;y say mount /data if tthere is a line in /etyc/fstab about the mount point /data.
b. At boottime to do the mounts that should be done at boot time.
I am not aware of any connection to mkinitrd, but I leave it to more knowledgeble people to inform you about that.
When I placed a ‘#’ in front of it, I was no longer asked for a password at boot time (and the device was not mounted - for automatic mounting replace the first “none” with the path to a file containing your password, obviously making this a hidden file accessible only to root).