LinHES Forums
http://forums.linhes.org/

Restoring /etc
http://forums.linhes.org/viewtopic.php?f=25&t=24159
Page 1 of 1

Author:  nicom [ Fri Mar 20, 2015 11:58 pm ]
Post subject:  Restoring /etc

I recently did something to my machine which caused problems with both the xorg setup and the remote. The video output was so bad the frontend would not open properly but the backend was OK. It operated like that for a couple of days so I worked out the simplest way to fix would be to restore the /etc directory from a backup but not database. The wiki says that restoring /etc and /home should be done manually. My concern is that doing a straight tar -zxpf of the backup file would also restore an old database which I did not want.

I successfully did the restore but wonder if there is a simpler way. My method involved extracting the backup to a /temp directory
Code:
sudo tar -zxpf /data/storage/disk0/backup/system_backups/backup-xxxx.tgz -C /temp
then rebooting to a version of Puppy linux on a usb, delete /etc then copy the backup /etc to /etc, then delete /temp. It occurred to me afterwards I could have done the following:
Use a file manager on another machine connected by samba to make a copy of the backup file, open the archive and delete everything other than the /etc directory.
Using ssh, extract the copy archive using tar -zxpf .

Would that work?
Is there a better way?

Author:  mattbatt [ Sun Mar 22, 2015 7:43 am ]
Post subject:  Re: Restoring /etc

Are you asking if you can Frankenstein an etc from an old archived backup and a good database from a new backup, re "tar" them and then restore the front end from the Frankensteined backup? I don't know the answer but it seems like it might be worth a try. I would try it in a virtual machine on a different computer first.
1 install fresh
2 restore from current broken backup and check to see if its still broken.
3 make the Frankenstein backup
4 restore from Frankenstein backup
5 see if it goes well and if it fixed the problems in step 2

Author:  mattbatt [ Sun Mar 22, 2015 7:46 am ]
Post subject:  Re: Restoring /etc

There is also partial restore if you don't mind reconfiguring everything here are the warnings. https://www.mythtv.org/wiki/Database_Ba ... f_a_backup

Author:  nicom [ Mon Mar 23, 2015 7:43 pm ]
Post subject:  Re: Restoring /etc

The intention was not to touch the database as the backend had been working happily and keeping the database up to date. I only wanted to restore the /etc directory.

As far as partial restore goes, I thought that only restored the database or do you have the ability to select what you want to restore.

Author:  mattbatt [ Mon Mar 23, 2015 8:22 pm ]
Post subject:  Re: Restoring /etc

A partial restore only restores the most critical info you have, the database of your shows. It blows away everything else, it's like hitting the reset button without loosing your recordings. At some point it's less of a pain to re-configure the system than it is to keep trying to figure out what went wrong. I had to do a Partial restore when I was going from 6.2 to 8.0. I had made some bad choices early in my MythTV days and I couldn't tease them out and they were preventing me from upgrading to 7.* and 8.* http://forum.linhes.org/viewtopic.php?f ... 8&p=138291

I'm not enough of a LInux/MythTV/LinHES Guru to tell you what will or wont work. That's why I said make sure you try it in a virtual machine first. If the VM blows up it's 0 missed recordings.

Page 1 of 1 All times are UTC - 6 hours
Powered by phpBB® Forum Software © phpBB Group
http://www.phpbb.com/