Help! Data loss.

Joined
Jan 6, 2011
Messages
14
Reaction score
0
Points
1
I wanted to reset the view settings for all folders, so I followed the advice posted by someone on the Apple forum. I opened Terminal and entered:
Code:
rm -rf .DS_Store /
The process took a long time, my computer became unresponsive, and it eventually locked up. When I restarted, I just got a flashing "?". I used my emergency partition to boot up the computer and not only was my internal HD wiped (except for a few empty folders), but my entire 1TB external backup drive was empty too. My entire life was on there! :mad:

I understand that modern file systems have backup file allocation tables. Is it possible to recover what was there using those? I hear that some rescue apps are unable to retrieve the original filenames, but they should all still be there right? I'm keeping the affected partitions unmounted to preserve them. Which tool is the best for my situation? I know of FileSalvage, Data Rescue, and Disk Drill. Thanks.
 
Joined
Apr 26, 2008
Messages
2,963
Reaction score
120
Points
63
Location
Belgium
Your Mac's Specs
iPad Pro 12.9 latest iOS
There are tools available ( as you indicated ) and they can attempt to recover some of your data.
But let's be realistic here ..... Your only change of recovering your data in full is to restore from a previous backup.

Never heard of " backup file allocation tables ", so can't comment on that.

Cheers ... McBie
 

chscag

Well-known member
Staff member
Admin
Joined
Jan 23, 2008
Messages
65,248
Reaction score
1,833
Points
113
Location
Keller, Texas
Your Mac's Specs
2017 27" iMac, 10.5" iPad Pro, iPhone 8, iPhone 11, iPhone 12 Mini, Numerous iPods, Monterey
There is no file allocation table per se nor a backup FAT. That terminology refers to file systems such as FAT-16 and FAT-32. OS X uses HFS+ which is a journaled file system.

As member McBie stated, without a good backup you're pretty much done. A reinstallation is in order. As you found out, using terminal to run commands that you are not familiar with can be disastrous.
 
Joined
May 19, 2009
Messages
8,428
Reaction score
295
Points
83
Location
Waiting for a mate . . .
Your Mac's Specs
21" iMac 2.9Ghz 16GB RAM - 10.11.3, iPhone6s & iPad Air 2 - iOS 9.2.1, ATV 4Th Gen tvOS, ATV3
A rm command coinciding with .DS_Store could only come to one conclusion. . . . . Disaster. Sorry to hear of your loss . . . For future reference rm = Delete
 
OP
T
Joined
Jan 6, 2011
Messages
14
Reaction score
0
Points
1
I did some reading, and it's the partition table that has a redundant copy, not the file catalog (the HFS+ equivalent of a FAT allocation table). I know RM means delete. I've used it many times before. The DS_Store file should only contain folder view settings, so I'm thinking the extra "/" at the end caused this problem. As I said, my external HD containing my backup which was connected at the time got wiped as well.

Anyway, I picked up a 2TB external HD today for data extraction. Hopefully these recovery tools can save my bacon. All my data is still there, untouched, just unlinked from the file catalog. It's just a matter of turning it back into files. Wish me luck.
 
Joined
Sep 21, 2011
Messages
726
Reaction score
28
Points
28
Location
London, Londonshire, England.
Your Mac's Specs
13" Late 2011 MBP,iPad '3' 32gb,iPhone4 32gb
Good luck! Let us know if you had any joy!
 

vansmith

Senior Member
Joined
Oct 19, 2008
Messages
19,924
Reaction score
559
Points
113
Location
Queensland
Your Mac's Specs
Mini (2014, 2018, 2020), MBA (2020), iPad Pro (2018), iPhone 13 Pro Max, Watch (S6)
The command you executed shouldn't have done irreparable damage because it wasn't executed with elevated privileges. Without elevated privileges, rm wouldn't have been able to remove much outside of your home directory (it could remove a few such as /tmp). Did you execute it with elevated privileges? In other words, did you put "sudo" in front of the command?

If that command did finish however, you would have deleted your user directory so all your pictures, documents, etc would be gone.
 
Joined
Mar 17, 2008
Messages
6,879
Reaction score
191
Points
63
Location
Tucson, AZ
Your Mac's Specs
Way... way too many specs to list.
the / certainly did. What you did, was tell it to remove, unconditionally and recursively, .DS_Store AND / with '/' being the root contents of your hard drive (so because it was recursive, you blew the lot away). Find would have been a better choice, and I don't bother blowing away .DS_Store files anyway, unless they're corrupted.

You've only done a delete though, so it's likely that data restore software could restore it. That said, I have no idea whose software is worth a darn in that field.

Now, I agree with van.. unless sudo was involved somehow, this shouldn't have done that. That somehow would include switching user to root.
 

chscag

Well-known member
Staff member
Admin
Joined
Jan 23, 2008
Messages
65,248
Reaction score
1,833
Points
113
Location
Keller, Texas
Your Mac's Specs
2017 27" iMac, 10.5" iPad Pro, iPhone 8, iPhone 11, iPhone 12 Mini, Numerous iPods, Monterey
Data Rescue 3 from ProSoft is best at recovering deleted files provided the drive has not been written to since. It will have to be run from either a disk or another drive though. The fun part for the OP is going to be putting all the rescued data back with the proper folder and file names.
 
OP
T
Joined
Jan 6, 2011
Messages
14
Reaction score
0
Points
1
Yes, sudo was used. I'm actually considering making backups of my backups now. What is the cheapest system? I expected it to be tapes but they are surprisingly costly!
 
Joined
Mar 17, 2008
Messages
6,879
Reaction score
191
Points
63
Location
Tucson, AZ
Your Mac's Specs
Way... way too many specs to list.
Tape is the industry standard for ultimate backup destination and no, it ain't cheap. You could do a cloud based back up, they'll eventually spin it to tape.
 
Joined
Apr 26, 2008
Messages
2,963
Reaction score
120
Points
63
Location
Belgium
Your Mac's Specs
iPad Pro 12.9 latest iOS
Yes, sudo was used. I'm actually considering making backups of my backups now. What is the cheapest system? I expected it to be tapes but they are surprisingly costly!

.... Cheapest System ? ....
That question surprises me and let me counter that with another question ...
What is the value of your data and how much money and time are you willing to invest to recreate your lost ( or corrupted ) data ?

Once you answered this, you can talk about the cost of your backup strategy.

I use disks as my backup media and I use 2 copies.
One is stored in my safe deposit box in the bank ... not the most friendly environment for storing magnetic media, but that is the price I want to pay. ( and the risk I want to take )

About storing your backups " in the cloud " .... all very well if you accept the risk that there is no legal framework for this and you have absolutely NO guarantee that your data in the cloud will be available when you need it.
Again, it is all about evaluating risks.

Cheers ... McBie
 
Joined
Mar 17, 2008
Messages
6,879
Reaction score
191
Points
63
Location
Tucson, AZ
Your Mac's Specs
Way... way too many specs to list.
..
About storing your backups " in the cloud " .... all very well if you accept the risk that there is no legal framework for this and you have absolutely NO guarantee that your data in the cloud will be available when you need it.

Really? So these pay-to-play backup offerings have absolutely no Service Level Agreements? Ok, in that case... I'd go tape. I've honestly never looked, then again I have a tape system.
 
Joined
Apr 26, 2008
Messages
2,963
Reaction score
120
Points
63
Location
Belgium
Your Mac's Specs
iPad Pro 12.9 latest iOS
Really? So these pay-to-play backup offerings have absolutely no Service Level Agreements? Ok, in that case... I'd go tape. I've honestly never looked, then again I have a tape system.

Think about how many components are involved between your machine and the ultimate destination of your data " in the cloud " ( Wherever that may be )
There will be hosting centers involved, and your ISP.
The operations of the hosting center will be outsourced to another 3rd party, who have hardware maintenance agreements with the manufacturers of the disks/tapes.
So you might have an SLA with your ISP ( for which you do not have the calculation method ) and then you might have a separate SLA with the vendor that sells you " the cloud " ......
So you are looking at a % times a % times a % times a % for each component in the complete chain. If you are lucky you will end up with an SLA of less than 10% on availability of your data.
And then again 10% of what exactly ... ( since the calculation formula are unknown and so are the data sources for that SLA calculation )
Availability is one thing, but if that cloud vendor has a problem somewhere, you won't have a clue which legislation will be applicable .....because you don't know in which country your data resides.

Your data in the cloud .... maybe, but certainly not mine.

Apologies for hijacking the thread -_-

Cheers ... McBie
 

robduckyworth


Retired Staff
Joined
Jan 4, 2011
Messages
2,971
Reaction score
109
Points
63
Location
Reading, UK
Your Mac's Specs
15" MBP, 2.5GHz i7, 750GB, 6770M 1GB, iPad 3, iPhone 4, custom PC
moved to more appropriate forum.
 
Joined
Mar 17, 2008
Messages
6,879
Reaction score
191
Points
63
Location
Tucson, AZ
Your Mac's Specs
Way... way too many specs to list.
Ohhh ok, I see what you're saying and this is absolutely correct. It is also true, btw, for the enterprise market. Who will routinely copy their data (real time) from their production site, to a DR site, then copy that data again to their backup site. Same set of connections apply, in that there are ISP's involved, multiple data centers, multiple storage devices, etc (and generally hefty fines if they're not compliant with regulatory requirements for all this duplication).
 

vansmith

Senior Member
Joined
Oct 19, 2008
Messages
19,924
Reaction score
559
Points
113
Location
Queensland
Your Mac's Specs
Mini (2014, 2018, 2020), MBA (2020), iPad Pro (2018), iPhone 13 Pro Max, Watch (S6)
Availability is one thing, but if that cloud vendor has a problem somewhere, you won't have a clue which legislation will be applicable .....because you don't know in which country your data resides.
I think this problem is more pronounced for smaller but highly wired nations such as mine and yours. Many of the cloud services are outside the country and it's very possible that there can be jurisdictional differences regarding the legality of my content.

timelessbeing: The answer to your question depends on how much data you have, what kind of security you want for it and options for storing the backups (can you keep them offsite for example).
 
OP
T
Joined
Jan 6, 2011
Messages
14
Reaction score
0
Points
1
There's no way I'm waiting for 1100GB to up/download to some place far away from my computer. Expensive does not = better. It's about meeting my needs, and I'm certainly not as paranoid about my data as you are. Would be nice to be able to burn those 128GB bluray discs.
I use disks as my backup media
That's very ambiguous.
 
Joined
Mar 17, 2008
Messages
6,879
Reaction score
191
Points
63
Location
Tucson, AZ
Your Mac's Specs
Way... way too many specs to list.
There's no way I'm waiting for 1100GB to up/download to some place far away from my computer. Expensive does not = better. It's about meeting my needs, and I'm certainly not as paranoid about my data as you are. Would be nice to be able to burn those 128GB bluray discs.
That's very ambiguous.

It is, I just don't trust things that spin, nor do I trust optical media in general. The former has failure potential on spin-up, the latter has issues when not stored correctly in the first place, and a history of varied media quality (even among same brand). Now, keep in mind that I'm a poor person for this sort of feedback. I spend an inordinate amount of my time looking at disk failures, thus I see more than most people ever will.

I believe he uses external hard disks as backups.
 
Joined
Apr 26, 2008
Messages
2,963
Reaction score
120
Points
63
Location
Belgium
Your Mac's Specs
iPad Pro 12.9 latest iOS
It is, I just don't trust things that spin, nor do I trust optical media in general. The former has failure potential on spin-up, the latter has issues when not stored correctly in the first place, and a history of varied media quality (even among same brand). Now, keep in mind that I'm a poor person for this sort of feedback. I spend an inordinate amount of my time looking at disk failures, thus I see more than most people ever will.

I believe he uses external hard disks as backups.

Apologies for being ambiguous .... I use external hard drives as my backup media.

Cheers ... McBie
 

Shop Amazon


Shop for your Apple, Mac, iPhone and other computer products on Amazon.
We are a participant in the Amazon Services LLC Associates Program, an affiliate program designed to provide a means for us to earn fees by linking to Amazon and affiliated sites.
Top