fstab

Hi,


In Terminal, I start with

sudo pico /etc/fstab


I get to the fstab screen in terminal and enter:

UUID=77571FF4-8469-3609-9CC0-1993BA7F90F8 none hfs rw,noauto


and 2 other partitions.


I then press control-o and then control-x which is supposed to write the file and exit the editor, but I can't get it to exit the editor. I guess it's writing, since when I come back to it the info is still there.


This is on a 2009 mac running high sierra...couldn't find '09 mac in selections


Appreciate any help, and obviously a novice here !!


iMac Line (2012 and Later)

Posted on Dec 29, 2020 5:16 PM

Reply

Similar questions

4 replies

Dec 31, 2020 8:39 AM in response to mrokloricred37

sudo because you need to elevate your privileges in order to modify a protected file owned by root.


macOS is based on Unix, and Unix started life as a multi-user, time-sharing system, frequently used in Universities, where protecting the system and other users from the students was essential.


These security protections have helped make Unix operating systems much more secure over the years, than many personal computers where the operating system assumed 1 user and that user was in total control (also the personal computer operating systems started life before networking and the concept of malware.


So sudo (Super User Do) is a way to elevate your privileges so that you act as the root user which has very few restrictions placed on what root can do. In this case edit and modify a file owned by root stored in a directory also owned by root.


I assume you already know what /etc/fstab is doing. And if not, then the VikingOSX "man fstab" pointer would have provided context for that.


WARNING - the sudo command is both very powerful and very dangerous unless you know what you are doing or are very lucky. If you are just following instructions from the web, you should be extremely careful as A) the person writing the instructions may have a different environment from yours, and the commands that worked for them, may not work for you, and B) if you mistype a command, it could have devastating results.


So when playing with commands like sudo, you should make sure you have backups, very recent backups. I've been using Unix since '85 and my current system has Time Machine backups, Carbon Copy Cloner backups, and an rsync backup to different attached external disks, and a Synology NAS server. I take protecting my data very seriously.


And even as an experienced Unix user, I've made mistakes in scripts that have done things like delete the /etc directory and made my system unbootable. So even experienced users can screw up.

This thread has been closed by the system or the community team. You may vote for any posts you find helpful, or search the Community for additional answers.

fstab

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.