jridgewell / Unlock

Unlock multiple Core Storage encrypted volumes at boot.
MIT License
197 stars 34 forks source link

Tried to install on Mountain Lion #9

Closed HKMacs closed 11 years ago

HKMacs commented 11 years ago

The first time I tried it appeared to work but the second time if reported error. Here is my log:

Vinces-MacBook-Pro-II:~ vince$ Last login: Thu Oct 4 00:56:57 on console Vinces-MacBook-Pro:vince vince$ curl https://raw.github.com/jridgewell/Unlock/master/install.sh | bash % Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 100 2853 100 2853 0 0 233 0 0:00:12 0:00:12 --:--:-- 313 Attempting to re-run as root... % Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 100 2853 100 2853 0 0 266 0 0:00:10 0:00:10 --:--:-- 348

WARNING: Improper use of the sudo command could lead to data loss or the deletion of important system files. Please double-check your typing when using sudo. Type "man sudo" for more information.

To proceed, enter your password, or type Ctrl-C to abort.

Password:

Downloading... % Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 100 509 100 509 0 0 46 0 0:00:11 0:00:10 0:00:01 57 % Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 100 139 100 139 0 0 9 0 0:00:15 0:00:14 0:00:01 15

100 27900 100 27900 0 0 1023 0 0:00:27 0:00:27 --:--:-- 6339

Installing...

Installed! Vinces-MacBook-Pro:vince vince$ curl https://raw.github.com/jridgewell/Unlock/master/install.sh | bash % Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 100 2853 100 2853 0 0 837 0 0:00:03 0:00:03 --:--:-- 1362 Attempting to re-run as root... % Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 0 0 0 0 0 0 0 0 --:--:-- 0:01:19 --:--:-- 0curl: (7) couldn't connect to host chmod: install.sh: No such file or directory Password: bash: ./install.sh: No such file or directory rm: install.sh: No such file or directory Vinces-MacBook-Pro:vince vince$ curl https://raw.github.com/jridgewell/Unlock/master/install.sh | bash % Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 100 2853 100 2853 0 0 576 0 0:00:04 0:00:04 --:--:-- 950 Attempting to re-run as root... % Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed

100 2853 100 2853 0 0 1040 0 0:00:02 0:00:02 --:--:-- 1417

Downloading... % Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 0 0 0 0 0 0 0 0 --:--:-- 0:01:19 --:--:-- 0curl: (7) couldn't connect to host % Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed

0 0 0 0 0 0 0 0 --:--:-- 0:01:21 --:--:-- 0curl: (7) couldn't connect to host

Installing...

mv: rename ./* to /Library/LaunchDaemons/*: No such file or directory

Installed! Vinces-MacBook-Pro:vince vince$ curl https://raw.github.com/jridgewell/Unlock/master/install.sh | bash % Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 100 2853 100 2853 0 0 725 0 0:00:03 0:00:03 --:--:-- 1288 Attempting to re-run as root... % Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 100 2853 100 2853 0 0 917 0 0:00:03 0:00:03 --:--:-- 1153

Password:

Downloading... % Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 100 509 100 509 0 0 109 0 0:00:04 0:00:04 --:--:-- 138 % Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 100 139 100 139 0 0 1 0 0:02:19 0:01:29 0:00:50 15

100 27900 100 27900 0 0 289 0 0:01:36 0:01:36 --:--:-- 6573

Installing...

Installed! Vinces-MacBook-Pro:vince vince$ diskutil CoreStorage list CoreStorage logical volume groups (1 found) | +-- Logical Volume Group 35B00C2F-C182-42A7-8A59-E559A9260F28

Name:         Data HD
Size:         499113885696 B (499.1 GB)
Free Space:   -none-
|
+-< Physical Volume 16D4C683-4A13-4747-B8A0-AB4E3F85BF90
    ----------------------------------------------------
    Index:    0
    Disk:     disk0s2
    Status:   Checking
    Size:     499113885696 B (499.1 GB)

Vinces-MacBook-Pro:vince vince$

HKMacs commented 11 years ago

I'd love this to work.

jridgewell commented 11 years ago

I'm seeing a lot of failed downloads, but that's related to your internet connection and not the script.

The larger problem, though, is that you don't have any FireVault 2 encrypted drives (from your diskutil CoreStorage list). You have to encrypt your drives beforehand. All this program does is unlock them during startup.

HKMacs commented 11 years ago

Hi John,

I don't know whether you missed this but:

Vinces-MacBook-Pro:vince vince$ diskutil CoreStorage list CoreStorage logical volume groups (1 found) | +-- Logical Volume Group 35B00C2F-C182-42A7-8A59-E559A9260F28

Name:         Data HD
Size:         499113885696 B (499.1 GB)
Free Space:   -none-
|
+-< Physical Volume 16D4C683-4A13-4747-B8A0-AB4E3F85BF90
    ----------------------------------------------------
    Index:    0
    Disk:     disk0s2
    Status:   Checking
    Size:     499113885696 B (499.1 GB)

Which surely indicates that Data HD was encrypted??

Your script did install at /Library/LaunchDaemons as well because I checked - it was there.

But it didn't work the second time I rebooted.

Slightly unfair to close this issue before we've resolved it, don't you think?

Please can you help. I had to reformat the drive and clone back my Users folder and everything is fine except my Data HD is not encrypted this time round.

Do you suggest I try again or what?

Best regards,

Vince –––––––––––––––––––––– Vince Loden HKMacs

(852) 29824274 (852) 93486884 E-mail: vloden@mac.com info@hkmacs.com Website Blog

On 5 Oct, 2012, at 4:06 AM, Justin Ridgewell wrote:

I'm seeing a lot of failed downloads, but that's related to your internet connection and not the script.

The larger problem, though, is that you don't have any FireVault 2 encrypted drives (from your diskutil CoreStorage list). You have to encrypt your drives beforehand. All this program does is unlock them during startup.

— Reply to this email directly or view it on GitHub.

jridgewell commented 11 years ago

Is the Data HD drive encrypted now (encrypted, not unlocked).

A few things for you to check:

Create a new User Profile, and turn off the computer and log into the new user. What is the output of sudo /Library/LaunchDaemons/name.ridgewell.unlock?

HKMacs commented 11 years ago

Hi John,

Thanks for your speedy response. The Data drive had to be reformatted and the Users put back from a CCC backup. So there is no entry in the Keychain that was restored. I would need to re-install your script and I haven't yet encrypted the new Data HD pending your instructions.

Last login: Fri Oct 5 11:06:20 on console Vinces-MacBook-Pro:~ test$ sudo /Library/LaunchDaemons/name.ridgewell.unlock

WARNING: Improper use of the sudo command could lead to data loss or the deletion of important system files. Please double-check your typing when using sudo. Type "man sudo" for more information.

To proceed, enter your password, or type Ctrl-C to abort.

Password: 2012-10-05 11:08:02.086 name.ridgewell.unlock[325:707] Error: SecItemCopyMatching returned -25300! Vinces-MacBook-Pro:~ test$

Hope this helps. Best regards,

Vince –––––––––––––––––––––– Vince Loden HKMacs

(852) 29824274 (852) 93486884 E-mail: vloden@mac.com info@hkmacs.com Website Blog

On 5 Oct, 2012, at 10:45 AM, Justin Ridgewell wrote:

Is the Data HD drive encrypted now (encrypted, not unlocked).

A few things for you to check:

In Keychain Access, in the System keychain, is there a key for Unlock: Data HD? Is the stored passphrase for that key the passphrase for the drive? Create a new User Profile, and turn off the computer and log into the new user. What is the output of sudo /Library/LaunchDaemons/name.ridgewell.unlock?

— Reply to this email directly or view it on GitHub.

jridgewell commented 11 years ago

The error code is expected since there is no key in the keychain.

I'm sorry that you've had to reformat you're drive, but I won't be able to diagnose the problem until you've re-encrypted and re-installed Unlock.

I'd recommend you run the uninstall script (curl https://raw.github.com/jridgewell/Unlock/master/uninstall.sh | bash), and keep a secondary account that can unlock the drive on the machine until we can figure it out.

HKMacs commented 11 years ago

OK. So the new User Profile must be on the Boot SSD I presume.

I've been using Encrypt by right-clicking on the drive, but when it was encrypted the first time I didn't see a Decrypt in the menu. Should all this be done in Terminal?

I don't really want to go ahead until you please could give me clear instructions.

Best regards,

Vince –––––––––––––––––––––– Vince Loden HKMacs

(852) 29824274 (852) 93486884 E-mail: vloden@mac.com info@hkmacs.com Website Blog

On 5 Oct, 2012, at 10:45 AM, Justin Ridgewell wrote:

Is the Data HD drive encrypted now (encrypted, not unlocked).

A few things for you to check:

In Keychain Access, in the System keychain, is there a key for Unlock: Data HD? Is the stored passphrase for that key the passphrase for the drive? Create a new User Profile, and turn off the computer and log into the new user. What is the output of sudo /Library/LaunchDaemons/name.ridgewell.unlock?

— Reply to this email directly or view it on GitHub.

HKMacs commented 11 years ago

Dear Justin,

I think I finally got it to work.

I followed instructions here http://www.macworld.com/article/1168077/encrypt_any_disk_in_mountain_lion.html in order to do it all in Terminal. Then I installed your script and checked in Keychain System before rebooting.

I am puzzled that encryption in Terminal is so much faster than using the alternate menu in Finder but it appears the disk is indeed encrypted as I also tried to boot from an external USB system disk and was asked for the unlock code for the Data HD so I'm presuming all is OK.

Thank you very much for your incredibly useful program and I shall certainly blog about it.

Best regards,

Vince –––––––––––––––––––––– Vince Loden HKMacs

(852) 29824274 (852) 93486884 E-mail: vloden@mac.com info@hkmacs.com Website Blog

On 5 Oct, 2012, at 11:19 AM, Justin Ridgewell notifications@github.com wrote:

The error code is expected since there is no key in the keychain.

I'm sorry that you've had to reformat you're drive, but I won't be able to diagnose the problem until you've re-encrypted and re-installed Unlock.

I'd recommend you run the uninstall script (curl https://raw.github.com/jridgewell/Unlock/master/uninstall.sh | bash), and keep a secondary account that can unlock the drive on the machine until we can figure it out.

— Reply to this email directly or view it on GitHub.

jridgewell commented 11 years ago

Glad to hear it!

HKMacs commented 11 years ago

Hi Justin,

I've actually blogged the whole procedure at http://hkmacs.com/Blog/?p=515 as I reckon some people might find it handy and submitted it to Mac OS X Hints and MacSurfer.

Please let me know if I've made any errors - of course without your script it wouldn't be possible. Why the heck haven't Apple rectified this?

Best regards,

Vince –––––––––––––––––––––– Vince Loden HKMacs

(852) 29824274 (852) 93486884 E-mail: vloden@mac.com info@hkmacs.com Website Blog

On 8 Oct, 2012, at 11:06 AM, Justin Ridgewell wrote:

Glad to hear it!

— Reply to this email directly or view it on GitHub.