Mac system is broken, and can not be re-installed, just need to do the following to copy the important files.
1. Prepare the external storage device.
Prepare an empty, large enough removable hard disk or USB flash drive
Enter recovery mode
1), long press option to start
Or
2), press Command+r
The effect is the same, all loading the file into memory
Start Disk Utility and select Erase disc. This step is to replace the external storage media with an apple-supported format, generally using the default format of the system, without changes.
2. Enter the catalogue
Cd/volumes/macintosh hd/users/Your account name/
which
Your account name
Just replace it with your actual username.
3. View all folders
Ls
View all files and find important storage folders
Desktop
Pictures
Documents
These three are more commonly used to store file paths
If you just need to clean up enough space, you can find containers, cache and other folders under the Library folder.
Remove the content from the contents so that you can completely erase the software you installed before.
Delete command
Rm–rf
-RF is obligatory meaning.
4. Copy
Cp-rf/volumes/macintosh hd/users/your account name/folder name space /volumes/External Storage name / folder name, Refers to the folder name you want to keep
The above command also has other writing formats,
It would be nice to change to your own level to the way you like it.
If you feel good enough,
Then use it directly.
Mac system crashes, use command line to copy hard disk contents