How JustAnswer Works:

  • Ask an Expert
    Experts are full of valuable knowledge and are ready to help with any question. Credentials confirmed by a Fortune 500 verification firm.
  • Get a Professional Answer
    Via email, text message, or notification as you wait on our site.
    Ask follow up questions if you need to.
  • 100% Satisfaction Guarantee
    Rate the answer you receive.

Ask Ashik Your Own Question

Ashik
Ashik, Mac Technician
Category: Mac
Satisfied Customers: 9945
Experience:  Bachelor of Computer Application (BCA), 9+ Years of Experience in troubleshooting Macs, iPhone, iPad, iPod etc
16433418
Type Your Mac Question Here...
Ashik is online now
A new question is answered every 9 seconds

Accidently deleted some files but didnt empty the trash..

Customer Question

accidently deleted some files but didnt empty the trash.. when I went to retrieve them they were not there and now my imac will not work... get the spinning wheel at start up.
Submitted: 1 year ago.
Category: Mac
Expert:  Ashik replied 1 year ago.

Hi and Welcome. My Name is ***** ***** I look forward to assisting you today with your question.

We can try some basic troubleshooting steps and see if it works or not.

First reset the PRAM and NVRAM of your Mac. Follow the steps below to reset the PRAM and NVRAM

Shut down your Mac

Restart and immediately hold down Command-Option-P-R keys at the same time

Hold the keys down until the computer restarts and you hear the startup sound for two or three times.

Release the keys and let the Mac boot up. This will reset the PRAM.

If that didn't work, then restart your Mac and immediately hold down Shift key on your keyboard for 15 seconds and this will boot into Safe Mode. Did that work ?

Please let me know if that didn't work, so we can continue troubleshooting.

Customer: replied 1 year ago.
neither of those worked I just got a blank screen... I just tried to start it again and now nothing.. no logo no wheel
Expert:  Ashik replied 1 year ago.

Did you delete any core system files ?

We may need to reinstall the OS X. What version of Mac OS X are you using >

Customer: replied 1 year ago.
not to my knowlege.. it was a file that was named private... I knew i hadnt created so I deleted it. it was ablut 1.8 gig in size. I would reinstall but my cd drive isnt working. I had taken it to a computer repair place to have it fixed about 2 years ago and they installed it on ther for me.
Expert:  Ashik replied 1 year ago.

Private is a part of OS X (if you deleted it from Macintosh HD or main HD).

Run Disk Utility from Single User Mode. Single User Mode is the name of a special screen that you boot into to run some fixes.

Turn it off by holding down the Power button for 10 seconds. Then turn on and immediately hold down the Command (Apple) key and the S keys at the same time. Then type the following command when it boot into black screen with white letters (Single User Mode)

/sbin/fsck -fy (note the space between fsck and -fy)

If you can't run /sbin/fsck -fy then type only fsk -fy

Hit return and the disk utility should run and let it finish. When it finishes type reboot and hit return.

If this doesn't boot your system, then we can reinstall the OS X which should fix the issue. You don't need the discs if you are using 10.7 or later version of OS X. Do you remember the version of OS X you were using on it ?

Expert:  Ashik replied 1 year ago.

The Private is a core system folder. All you have to do is, reinstall the OS X. You won't lose any files since they are saved on different folder and will be preserved when you reinstall. Reinstalling the OS X will create a new Private folder along with new files* and then your system will boot as normal.

You can use external DVD drive to reinstall the OS X if you are using 10.6 or lower version.

If you are using 10.7 or later, then you can reinstall the OS X by booting into OS X recovery with using the DVD. Tell me the version of OS X are you using and I will send you the instructions to reinstall.

Expert:  Ashik replied 1 year ago.

Sorry there is a correct. If you are using 10.7 or later, then you can reinstall the OS X by booting into OS X recovery WITHOUT using the DVD. Tell me the version of OS X are you using and I will send you the instructions to reinstall.

Customer: replied 1 year ago.
its 10 6... also im using a pc keyboard so im not sure which key is compatible to the apple command...
Expert:  Ashik replied 1 year ago.

There is typo in my previous answer. If you are using 10.7 or later, then you can reinstall the OS X by booting into OS X recovery WITHOUT using the DVD.

In PC keyboard, Command is Start menu

Alt is Option

Expert:  Ashik replied 1 year ago.

In PC keyboard, Command is Start button

Alt is Option. Others are same

Customer: replied 1 year ago.
is the start button the key with the window symbol on it?
Expert:  Ashik replied 1 year ago.

Yes

Expert:  Ashik replied 1 year ago.

Disk Utility might not work since you deleted core system files. Disk Utility usually repair the files. But try it.

Is there any you could get an external DVD drive ? You can reinstall the OS X with it.

Customer: replied 1 year ago.
I talked with a computer repair place and they said to bring it in in the morning... can they reinstall ox without loosing anything..
Customer: replied 1 year ago.
i tried single mode but I keep getting the logo with spinning wheel
Expert:  Ashik replied 1 year ago.

Yes, they can. The OS X can be reinstalled without affecting the User Account folder that means all your files will be there. Only the missing system files or corrupted system files will be replaced. If you get an external DVD drive, you can reinstall yourself. It is a very easy process. All you have to do is, boot into the OS X disc (by holding dow C key) and follow the onscreen instructions to reinstall.

And make sure you tell them not to erase the hard disk. Some computer shops go ahead and erase the drive and install fresh OS X.

Expert:  Ashik replied 1 year ago.

If they can't reinstall, don't allow them to erase. Because there are many ways to recover the files from that Mac using tools like Disk Warrior, Target Disk Mode (by connecting to another Mac with Firewire cable) etc

Customer: replied 1 year ago.
yea they kept saying they would have to reinstall the operating system and erase the drive. but i could go to my time machine and restore. I have another mac how would i do the firewire thing?
Expert:  Ashik replied 1 year ago.

Believe me, 10.6 can be reinstalled without erasing the drive. They are just going for the easy way to fix the Mac. Erase and install only takes less time than reinstall.

If you have another Mac, then you can setup Thunderbolt/Firewire Target Disk Mode (you need the right cable to connect both Macs). See this article --> https://support.apple.com/kb/PH10725?locale=en_US

Expert:  Ashik replied 1 year ago.

Ignore the Mountain Lion heading in the above article. The process is same for all OS X.

See this article as well --> https://support.apple.com/en-in/HT201462

Customer: replied 1 year ago.
will you give me a minute to review the article?
Expert:  Ashik replied 1 year ago.

Of course. Take your time. I also have one more suggestion you should do before reinstalling the OS X or trying Target Disk mode.

Customer: replied 1 year ago.
im back... i do have the cable but havent done anything what is your next suggestion?
Expert:  Ashik replied 1 year ago.

Try to boot into Single User Mode. To do that, turn off your Mac. Turn it back and immediately hold down Command(Windows) and S keys for 10 seconds. This will boot into Single User Mode.

Then type the following commands (there are spaces between characters, make sure you do them correctly).

mount -uw /

After typing the above command press enter then type the following command and press enter

cp -rf /Volumes/your hard disk name comes here/Users/your username or home folder name comes here/.Trash/private /Volumes/your hard disk name comes here/

(Note -> There are spaces between cp and -rf, -rf and /

and private and /

Do this. If that didn't work, then we can setup Target Disk Mode and then try to put the private folder back to its location.

Customer: replied 1 year ago.
I typed it in and it said no such file or directory... the good thing is it booted in single mode :)
Customer: replied 1 year ago.
I plugged the keyboard directly into a usb port and not a hub... should i try to restart it using the p and r command?
Expert:  Ashik replied 1 year ago.

Make sure you enter the commands correctly.

You have to enter the correct hard disk name and also your home folder name

If the name of the hard disk is Macintosh HD and home folder name is ***** ***** command will be

cp -rf /Volumes/Macintosh HD/Users/Stone/.Trash/private /Volumes/Macintosh HD/

If that didn't work, then try this command --> cp -rf /Volumes/"Macintosh HD"/Users/Stone/.Trash/private /Volumes/"Macintosh HD"/

Expert:  Ashik replied 1 year ago.

Make sure you also enter the first command correctly. The first command is to get permission to modify your HD --> mount -uw /

There is a space between mount and - and also space between w and /

PRAM reset will not work.

Customer: replied 1 year ago.
i tried both but it says no such file or directory...is it case sensitive for user and drive names?
Customer: replied 1 year ago.
is there a way to list the name of the drive so that I know Im typing it right... I though I named my drive Malcom
Customer: replied 1 year ago.
thought
Expert:  Ashik replied 1 year ago.

Yes and it will not work if Private isn't trash. So try Target Disk Mode

Expert:  Ashik replied 1 year ago.

It will not work if Private isn't in Trash.

Do Target Disk Mode

Customer: replied 1 year ago.
do I just shut down the mac?
Customer: replied 1 year ago.
do i need to leave single mode?
Customer: replied 1 year ago.
you there?
Expert:  Ashik replied 1 year ago.

Sorry I didn't see your message re the name of drive

Type /sbin/fsck -fy

Press return and you will see the volume name at the end of completed message after running some checks

Customer: replied 1 year ago.
it finished the checks and it says that there is an Invalid volume directory count. it also says /dev/rdiskOs2 (hfs) EXITED WITH SIGNAL 8. The HD is Malcom
Expert:  Ashik replied 1 year ago.

OK, the name is correct.

Can you try Target Disk Mode

Customer: replied 1 year ago.
sure how do i get out of the single mode
Expert:  Ashik replied 1 year ago.

Type reboot or shutdown and press return

Customer: replied 1 year ago.
okay I used my laptop as the target disk they are connected and i started the imac.. still getting logo and spinning wheel
Expert:  Ashik replied 1 year ago.

You have to start iMac in Target Disk Mode and it will appear on your laptop. Remember, they have to be connected via Firewire/Thunderbolt

Ethernet or USB will not work

Connect both Macs. Then turn on Laptop. Then turn off iMac. Turn on iMac and immediately hold down T key on your keyboard and you should see firewire icon iMac. Let me know

Customer: replied 1 year ago.
Expert:  Ashik replied 1 year ago.

Do you see the hard disk icon your laptop now ?

Expert:  Ashik replied 1 year ago.

Do you see the hard disk icon on your laptop now ?

Customer: replied 1 year ago.
i do
Expert:  Ashik replied 1 year ago.

Great ! First backup all your files to your laptop. You can copy them to your laptop.

And what version of OS X are you running on your laptop ?

Customer: replied 1 year ago.
its 10.6.8can I back them up to an external drive... not sure if theres enough room on the laptop
Expert:  Ashik replied 1 year ago.

Yes, you can backup them to the external drive.

Copy the private folder from your laptop to the iMac's drive. Since they are running same version, it might work.

Customer: replied 1 year ago.
okay I have 700 GB on Malcom.. do I need to back it up first before trying to copy the private folder?
Customer: replied 1 year ago.
700 GB of information
Expert:  Ashik replied 1 year ago.

Yes, always better to have a backup.

After that, copy the private folder from laptop to iMac's Malcom (to exact place where you deleted it first place).

Then just restart the iMac. If it doesn't work, then you can take it to reinstall the OS X.

Customer: replied 1 year ago.
okay.. so to in order to back it up, all I do is copy Malcom and paste it to the external drive?
Expert:  Ashik replied 1 year ago.

Yes. Don't copy the Malcom drive itself, but the copy the files inside the Malcom drive.

Customer: replied 1 year ago.
it gave me some error msg so Im trying it again.. if I have it backed up on time machine do I still need to copy it? it says it has close to 500,000 files
Expert:  Ashik replied 1 year ago.

No need if you have already backed up to Time Machine.

If you want to manually backup some important documents or others files to your laptio, then you can do them now.

You can do a complete restore from time machine even if the drive is erased.

Did you copy the private folder from laptop to iMac ?

Customer: replied 1 year ago.
no... where can I find it?
Expert:  Ashik replied 1 year ago.

Open the HD of your laptop and you will see the private folder there. Then copy to the HD of iMac.

If you don't see private folder, then it is hidden. Follow the steps

  1. Open Terminal found in Finder > Applications > Utilities.
  2. In Terminal, wirte the following: defaults write com.apple.finder AppleShowAllFiles YES

Then hold the 'Option/alt' key, then right click on the Finder icon in the dock and click Relaunch. You should see hidden files now

Customer: replied 1 year ago.
Man its taking a long time to copy
Customer: replied 1 year ago.
How much is this costing me?
Expert:  Ashik replied 1 year ago.

Yes, it will take time since you are copying to external drive. External drives are slow

I don't have access to your account, but the question value is $34. So it'd be $34

Customer: replied 1 year ago.
Not sure what time it is where you are but its 3 in the am... are you going to be here while this transfer?
Expert:  Ashik replied 1 year ago.

It is 2:00 PM here. Yes, I will be here.

Customer: replied 1 year ago.
okay.. im gonna go watch a movie and come back and check on it.
Expert:  Ashik replied 1 year ago.

May be you should get some sleep. Add a bookmark of this page, so you can get back to me later or any time you want.

Customer: replied 1 year ago.
k... will do and thanks for the help so far.
Expert:  Ashik replied 1 year ago.

No problem.

Customer: replied 1 year ago.
hey are you there
Expert:  Ashik replied 1 year ago.

Hi, Yes. I'm here.

Customer: replied 1 year ago.
okay i was able to copy the private file to my imac.. i restarted it and it booted up fine. But the login screen is the same as my macbook... do i now login as if i was going to log into my macbook?
Expert:  Ashik replied 1 year ago.

Yes. Try that.

Customer: replied 1 year ago.
alright im in... what do i need to do to get it back to its original state? can I plugin my external and try to restore it from time machine?
Expert:  Ashik replied 1 year ago.

Open the Time Machine. Then restore the private folder from that time machine and replace it with private folder of iMac.

To do a complete system restore, you will have to boot into the OS X disc

Customer: replied 1 year ago.
do i do it using two different computers or can I do this all on the imac itself.
Expert:  Ashik replied 1 year ago.

You can do it using your iMac.

Customer: replied 1 year ago.
its giving me an error code -8003 and now the private folder has a red and white circle on it.. the no access symbol
Expert:  Ashik replied 1 year ago.

Might be because your modifying the system files within the system. Restore the private folder from Time Machine to a desktop of iMac. Then copy it to your external drive.

Then boot your iMac in Target Disk Mode and and replace the private folder (restored from backup of iMac from Time Machine) using laptop

Customer: replied 1 year ago.
question... if i use omni disk sweeper to erase the private file on the imac and then replace it with the copy from time machine.. then reboot... do you think that will work?
Expert:  Ashik replied 1 year ago.

Yes, I think. If that didn't work, then restore that private folder from TM to external/USB drive, then boot the iMac in Target Disk Mode and copy the private folder from external/USB drive to iMac's HD