View Single Post
  #1   (View Single Post)  
Old 26th March 2013
libertas libertas is offline
New User
 
Join Date: Jan 2012
Posts: 7
Default geli attach during boot problems

Hi all!

I'm building one of my home server (very small) with FreeBSD 9.1, and have a problem trying to open an encrypted partition for data at boot.

I followed http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/disks-encrypting.html"]http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/disks-encrypting.html

Used gpt for disk partitioning.
There's no problem when I issue the command:
geli attach -k /root/da2.key /dev/da2 (from the handbook example).

It is said that that I should include the following two lines in rc.conf
geli_devices="da2"
geli_da2_flags="-p -k /root/da2.key"

I really don't understand the following paragraph, as it's referring to '-P' option, but it's '-p' that is shown in the `geli_da2_flags`.

The problem is that when the server is booting, it asks for a key. I enter the key, via keyboard, but the system always says that it's wrong.

I tried also the following line instead:
geli_da2_flags=" -k /root/da2.key"
without the '-p' but always get the same result.

What should I do?

Another thing: Should I place a 'noauto' line for mounting this encrypted partition in /etc/fstab or does it need to be mounted afterwards from some script?
Reply With Quote