On May 23, 2019. I accidentally drop my MacBook, which looses the connection between the motherboard and hard drive. After I reconnect the SATA cable and restart my computer, I found that my laptop stuck after I enter the login password.
In recovery mode, reset the password.
See instruction at:
However, I failed.
I first try to set up a new user by using single user mode.
See instruction here: https://zhidao.baidu.com/question/528962469.html
However, after I set up the new user, I still got stuck when I try to login into the system.
Since I have a Time Machine backup in January, I can recover my computer using Time Machine. However, I still need to backup some important information that is not in the Time machine. After doing some research, I successfully copy the important file from MacBook using single user mode.
###Copy file without login:
If your mac running a macos higher than El Capitan, you should first remove “System Integrity Protection” before entering the single user mode.
Reboot your mac and press command + R, go to the recovery mode.
Click on the "Utilities" menu, and then click on "Terminal" to open terminal.
In the terminal type
csrutil disableand enter.
If your mac running a macos lower than El Capitain, ignore the step above.
reboot again, but this time press command + S to enter single user mode.
Follow the instruction, type
/sbin/fsck -fyand press enter (if this command does not show “The volume xxx appears to be OK”, you should run this command multiple time until it shows this message)
mount -uw /and press enter
mkdir /Volumes/usbto create a directory for external storage device (using later).
ls /dev/disk*to show current disks.
plug in an external storage device (USB or other things), type
ls /dev/disk*to find which is the external storage device (often the last one in the list).
fstyp /dev/disk1s3(depends on which disk you are using) to find the system of the disk, (Interest things is that although my drive is exfat, the fstyp shows msdos).
according to 7, type
/sbin/mount_exfat /dev/disk1s3 /Volumes/usbto load storage device. Depending on your file system, you may choose a different command. For example, if your device is using msdos file system, you should type
/sbin/mount_exfat. You can see all the supported file system by entering
if the external storage is loaded success, you can now access your external drive. Type
ls /Volumes/usbto find out.
Copy file to your device by using command cp. Eg:
cp /User/xxx/Desktop/1.jpg /Volumes/usb