How to Setup a FileVault Recovery Key On Your Mac

For some reason when I encrypted the hard drive on my Mac I wasn't given the option to create a recover key. Here are some tips for working with FileVault at the command line to create or change the recovery key.

Check if file vault is running [1].

fdesetup status

There are actually two different types of recovery keys [2]. I was working on my personal Mac so the first one was relevant for me.

fdesetup haspersonalrecoverykey
fdesetup hasinstitutionalrecoverykey

Generate a recovery key [2].

fdesetup changerecovery -personal