macOS with File Vault doesn’t automatically connect to the Internet on restart

If you have setup a macOS machine that doesn’t seem to connect to the Internet automatically upon restart, I bet it has FileVault turned on.

FileVault is Apple’s encryption utility that encrypts data on a macOS machine. Read more about it here. One of the down sides of turning on FileVault is that it requires the user to login _before_ it can decrypt the disk’s contents. This is done via a special boot partition that is not encrypted with the user’s secret.

Long story short, upon rebooting the macOS machine, it’ll bring up a screen which runs off of an entirely different partition that only presents the user login screen. Upon logging in, the contents of the actual partition are decrypted and the boot process continues. This is precisely why network devices such as ethernet and WiFi don’t start until you login. In a “headless” scenario, one would find themselves locked out remotely. Therefore, be careful about turning on FileVault on a “headless” macOS machine such as a Mac mini.

So far I have not found of a good way to have FileVault turned on and login remotely upon a restart except the following.

Enter the following command on a macOS terminal where FileVault is turned on.

sudo fdesetup authrestart

Upon entering it, you’ll be first prompted for the administrator’s password (assuming you’ve not recently run sudo in the shell) then you’ll be prompted for a username and password for an account that exists on the machine. Once successfully authenticated, the machine will reboot and you’ll not be stuck at the boot screen locked out remotely.

If you find a better way to do this, please leave a comment below.

Online Communities and suppression of diverse viewpoints

Message boards are all over the web. They have been around ever since the Internet was invented – right from BBS’ and dial-up modems to now. Having worked extensively with one of the most visible message boards on one of the highest profile websites on the web for better part of a decade, I know the complexities that come with managing them. It is important to maintain good discussion standards. Its especially hard when a bunch of anonymous strangers are involved on the Internet.

One of the hardest aspects of running a message board is to protect diverse viewpoints. Typically people with similar opinions try suppressing opposing or even slightly differing view points. They use different techniques to achieve this goal based on the features that the message board offers. A lot of message boards offer the ability to rate comments by up voting or down voting. A comment that attracts a lot of down votes is usually considered poor content and usually hidden. Most message boards use a karma like feature to decide who gets to downvote. A lot of online communities employ this feature viz. StackOverflow, Hacker News, etc. Usually users with high karma are trusted users. They’re expected to maintain good quality discussions and flag poor content.

In theory this is expected to work well. However, in practice it doesn’t. The main issue is that people with high karma are also human beings. They have their own biases and may not value a diverse (opposing) viewpoint. When you have a high concentration of such individuals, I guarantee that diverse viewpoints cannot surface. I have observed this not only on HackerNews but also StackOverflow. Unsurprisingly, most people on these message boards do not consider this to be a serious issue. They think the system is perfect >_< Do you see the irony in this?

The prime reason this is an issue is that the people who have attained the privilege do so by being similar to those who already have that privilege. Unless the group recognizes this as an issue and makes attempts an injecting more diverse viewpoints it becomes a difficult issue to resolve. Addition of more members with same viewpoints only reinforces the group’s flawed belief systems. This lack of diversity makes the group extremely closed to new ideas and opinions ultimately leading to failure as they cannot adapt to changing times or cultural norms. This similar to what happens when a gene pool lacks genetic diversity usually leading to weaker offsprings and ultimate collapse of the population.

This is not to say that StackOverlow or HackerNews are bound to fail. They are good places to find information but as online communities they fail to respect diverse viewpoints and are unwilling to see it.


It has been about a year since I last posted on my blog. I originally wanted to be very regular at writing. However, life throws you a curve ball once in a while. Over the past 1 year that I have been very busy with the Conference circuit, Open Source, work and personal life. It has been a very interesting year indeed. I have given over 10 tech talks across 3 continents. I have been an active contributor to Apache Cassandra at work and in my spare time. I’m co-chairing the IEEE Infrastructure conference in the Bay Area and putting together the Cassandra track at ApacheCon NA 2019. It has been a great ride, indeed! Now that things are not that crazy, I am back to tinkering in my spare time, reading books and looking for the next challenge.

Installing specific version of Python on macOS using home brew

Recently, I was working on some code that required Python 3.6. Although, it would probably run on newer versions of Python, I did not want to take any chances. I wanted to run it on Python 3.6. Normally, I would use a Docker container to ensure a reproducible environment. However, Docker imposes its own complexities when it comes to integrating with IDEs such as Pycharm. A common issue is debugging code when its runtime environment is inside a Docker container. IDEs usually don’t make it easy to create a breakpoint in the IDE and have the code run inside a Docker container. However, if the interpreter and the dependencies are on your host OS, it is easy to set breakpoints and debug code in Pycharm.

Getting back to my issue, I typically use Homebrew on macOS to install packages such as Python. It is a fantastic package manager and I have used it for a very long time now. However, it lacks the feature to install a specific version of a package. In this case, I wanted to install the latest Python 3.6 on my macOS. The only problem was that Homebrew had updated Python to 3.7 and so there wasn’t an easy way to have it install 3.6.

After a bit of digging around, I remembered that Homebrew uses a git repository to store all of its formulae. So, it was a matter of finding the correct Git SHA where the Homebrew maintainers had last updated Python 3.6 and using it to install Python.

Here are the steps I took to install Python 3.6 on macOS using Homebrew and a bit of Git.

First, unlink existing Python

brew unlink python

Next, install Python using the following command

brew install --ignore-dependencies

Here, f2a764ef944b1080be64bd88dca9a1d80130c558 is the Git SHA where I saw the last Python 3.6 update take place in the commit history.

If you’re interested, check out /usr/local/Homebrew/Library/Taps/homebrew/homebrew-core/Formula. This is where all the Homebrew formulae live.