Igor Kromin |   Consultant. Coder. Blogger. Tinkerer. Gamer.

I recently bought a new Mac which came with macOS Catalina (15.15) installed. I started to set it up the way I wanted to and came across an issue with symbolic links at the file system root (/). I was trying to create a symlink like this...
 Command
sudo ln -s /Volumes/Data\ HD/Personal /Personal


...which promptly gave me an error...ln: /Personal: Read-only file system.

It appears that since 15.15, the root file system is read-only and if you want to have symbolic links or custom mount points at the file system root, you have to use the /etc/synthetic.conf file to create them. From the synthetic.conf man page...
synthetic.conf provides a mechanism for some limited, user-controlled file-creation at /. The synthetic entities described in this file are synthesized by the kernel during early system boot. They are not physically present on the disk, but when the system is booted, they behave as if they were within certain parameters.


Using Terminal.app, I checked if the /etc/synthetic.conf file existed, it didn't in my case. That was ok because I could create it as long as I used sudo to get root privileges...
 Command
sudo vi /etc/synthetic.conf


Then I added the following contents to the file...
 /etc/synthetic.conf
Personal /Volumes/Data HD/Personal


Note the entries have to be TAB separated and the order of entries is symlink name, TAB, target path. Also note that in my case the path had a space in it, there is no need to escape this and if a backslash is used, the symlink will not work correctly - you have to use a literal path here.

Once the file and it's contents were created, I restarted my Mac and the symlink was there as expected...
synthetic_3.png




-i

A quick disclaimer...

Although I put in a great effort into researching all the topics I cover, mistakes can happen. Use of any information from my blog posts should be at own risk and I do not hold any liability towards any information misuse or damages caused by following any of my posts.

All content and opinions expressed on this Blog are my own and do not represent the opinions of my employer (Oracle). Use of any information contained in this blog post/article is subject to this disclaimer.
Hi! You can search my blog here ⤵
NOTE: (2022) This Blog is no longer maintained and I will not be answering any emails or comments.

I am now focusing on Atari Gamer.