Thank you for being a valued part of the CNET community. As of December 1, 2020, the forums are in read-only format. In early 2021, CNET Forums will no longer be available. We are grateful for the participation and advice you have provided to one another over the years.

Thanks,

CNET Support

Question

Restore Settings from Terminal Bash Backup

Jan 16, 2014 6:01AM PST

Hi all!

My web searches on this topic were fruitless; please accept sincerest apologies if this is a re-post of a previous question, as I have not been able to find it...

My previous internal HD was failing and unable to complete a Time Machine backup because there were some corrupted files that stopped the back-up. Instead, I used a Terminal Bash command (Sudo cp -Rv) to back all of my information up onto an external drive.

I have installed a new internal HD and Mac OS X (using an old machine - A1181), but I am struggling to figure out how to restore all of my settings (and documents!!) from the Backup Terminal Bash file. Any guidance on how to do this would be MUCH appreciated, as I live several hours from the nearest Genius Bar.

Many thanks!

Discussion is locked

- Collapse -
Answer
Is this any good?
Jan 16, 2014 8:23AM PST
- Collapse -
I may have overstated my familiarity with a Mac
Jan 16, 2014 2:03PM PST

Thanks for the link. So if I'm interpreting this right, I should be able to run the Restore files command?

/bin/tar -xpzf /path-to-backups/www-2012-04-25.tar.gz -C /

Sorry, just a bit lost and not quite THAT Mac-savvy.

- Collapse -
I don't play on this side of the street either,
Jan 16, 2014 8:40PM PST

I assumed, incorrectly, that you were at least familiar with what you were doing.

In hindsight, you would have been better finding those corrupted files.

Give the script a whirl, after reading everything twice, and see if it picks up your backup file


P

- Collapse -
Playing in the road at this point
Jan 17, 2014 12:26AM PST

The old hard drive hasn't died yet. And I kept a copy of the results of the Terminal Bash so I could identify the corrupted files. No problem reinstalling and from there I should be able to find the corrupted files...would I just delete them or is there some way to salvage? Once that all was cleaned up, theoretically, Time Machine would then work, yeah? Thanks for your patience.

- Collapse -
There is a possibility that those corrupted files
Jan 17, 2014 7:44AM PST

are actually on your Time Machine backup.

I presume that the TM backups were running fine for a while there so the possibility is that these files were backed up at least once before they became corrupted.

Once you find which files are the culprits, go to the folder that you have them stored in, Enter TM and go back to a time before they messed with your TM backups.
Then Restore them.

P

- Collapse -
Stupid but....
Jan 18, 2014 4:20AM PST

They were backed-up, but for some reason TM would not backup unless I completely deleted it, and then backed-up. So that's what I've done *forehead slap* This worked just fine until the hard drive started to fail, or the files became corrupted, and then I was left with nothing as a backup and TM not able to complete b/c of the corrupted files.

If I locate these, put them in the trash bin, empty the trash, and then try the TM backup again, should it work?

- Collapse -
Theoretically, yes,
Jan 18, 2014 10:19PM PST

but no guarantees

P