Vishnu H Prasad : An Accidental Civil Servant

Recovering the Mac when Password is lost

I ran into some trouble today. My personal laptop being a mac, I never used the official laptop that I was given. Since I am an officer trainee, there is not much official work that needs to be done through the official laptop. The only routine job that we have to do is to check the official email, which is accessed through the web client and not an email client. Thus, after around 4 months of inactivity, I decided to fire up my official macbook. Lo! and behold!, I had forgotten the password.

Being the privacy freak, that I am, I must have set a very tough password on the official laptop. Besides, I had not logged in to icloud using my personal id because it is my official laptop. On top of all this, I had also encrypted the device using FileVault.

My first instinct was to run recovery on the mac, by booting into the recovery mode (press Command + R while booting) and then trying to reset the password using my icloud account. However, this was not going to work because I had not signed into icloud on the official laptop.

As the next step, I tried reinstalling MacOS Sierra into the laptop using the internet. However,, since my Mac partition was encrypted, this could not happen unless I unlocked the partition using my password ( which in this case I did not remember)

Since there was no sensitive data that could be lost I was ready to erase the partition and then reinstall it fresh into a new partition. The Disk Utility software was not allowing me to erase the primary partition. So after much research, this is what I did.

I opened the terminal from the Recovery window. It can be found in Utilities –> Terminal.

Once the terminal was open I ran the following command to list the disk partitions.

diskutil cs list

This gave me a the logical volume id. Once I got the logical volume ID as shown in the picture

Logical Volume

Logical Volume

I ran the following command.


The XXXs should be replaced with  your logical volume ID. This deleted the encrypted disk partition.

Internet Recovery and Date issue

Once I rebooted my mac, I was expecting an internet recovery. When the internet recovery ran and finally I reached the recovery space again, I tried to reinstall mac. However, it kept telling me that there was a untrusted certificate error which was not allowing me to proceed to the next step.

Again, after doing some research , I figured that my system date was not up-to-date because of the partition erase, so I again fired up the terminal and ran the date function, thereby updating the system date. Following this the internet recovery ran smoothly, and I was able to use my official mac again.


If any of you happen to forget your macbook password, then the following reference can be of immense help.


%d bloggers like this: