Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Recovering /var/db ???
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Duplicate Threads
View previous topic :: View next topic  
Author Message
fearofcarpet
Tux's lil' helper
Tux's lil' helper


Joined: 02 Apr 2005
Posts: 89
Location: Cambridge, MA

PostPosted: Tue Sep 05, 2006 11:07 am    Post subject: Recovering /var/db ??? Reply with quote

For whatever reason Gentoo decided to hang during shutdown (not reboot for some reason though) and I had to hard reset... Well, long story short the entire /var directory is hosed. To its credit Gentoo was able to boot fine missing /var (I had to re-create a couple of subdirs), but since I lost /var/db/pkg portage has no idea what packages are installed.

I think I know the answer to this (i.e. re-install from scratch), but is there any way I can somehow rebuild /var/db/? Thus far I've just been re-emerging everything, but of course I can't remember all the packages that were installed and some are starting to break because portage has no idea what dependencies are installed.
Back to top
View user's profile Send private message
msalerno
Veteran
Veteran


Joined: 17 Dec 2002
Posts: 1336
Location: Sweating in South Florida

PostPosted: Tue Sep 05, 2006 12:42 pm    Post subject: Reply with quote

Did you try a revdep-rebuild? or the dep tool by ecatmur?

They won't catch 100% of everything, but it might get you close enough to not have to reinstall from scratch.
_________________
When harmonious relationships dissolve
Then respect and devotion arise;
When a nation falls to chaos
Then loyalty and patriotism are born.
-Lao Tse
Back to top
View user's profile Send private message
fearofcarpet
Tux's lil' helper
Tux's lil' helper


Joined: 02 Apr 2005
Posts: 89
Location: Cambridge, MA

PostPosted: Tue Sep 05, 2006 3:00 pm    Post subject: Reply with quote

msalerno wrote:
Did you try a revdep-rebuild? or the dep tool by ecatmur?

They won't catch 100% of everything, but it might get you close enough to not have to reinstall from scratch.




Thanks, I'll give those a try... I wasn't sure if they were the sort of tools that could do more harm than good, but I suppose what do I have to lose..?
Back to top
View user's profile Send private message
UncleOwen
Veteran
Veteran


Joined: 27 Feb 2003
Posts: 1493
Location: Germany, Hamburg

PostPosted: Tue Sep 05, 2006 3:29 pm    Post subject: Reply with quote

They won't help. The only thing that will rebuild you /var/db/pkg is emerge -e world.
Back to top
View user's profile Send private message
fearofcarpet
Tux's lil' helper
Tux's lil' helper


Joined: 02 Apr 2005
Posts: 89
Location: Cambridge, MA

PostPosted: Wed Sep 06, 2006 9:59 am    Post subject: Reply with quote

UncleOwen wrote:
They won't help. The only thing that will rebuild you /var/db/pkg is emerge -e world.


Yeah it's been chewing on that one for a while now :)
Back to top
View user's profile Send private message
Polynomial-C
Developer
Developer


Joined: 01 Jun 2003
Posts: 1392
Location: germany

PostPosted: Wed Sep 06, 2006 10:46 am    Post subject: Reply with quote

Hi,

UncleOwen wrote:
They won't help. The only thing that will rebuild you /var/db/pkg is emerge -e world.

Which also won't work as world resides in /var/lib/portage/world

fearofcarpet you are screwed, no doubt about that. The only other solution than reinstall from scratch that comes to my mind would be to emerge -e system and then try to figure out yourself, which other software you have installed on that machine and reinstall that as well. But this can be a painful thing to do and you should really consider to reinstall from scratch after you did a backup of /home and /etc.

Cheers
Poly-C
_________________
The manual said "Requires Windows7 or better" so I installed GNU/Linux...

my portage overlay

Need a stage1 tarball? (Unofficial builds)
Back to top
View user's profile Send private message
UncleOwen
Veteran
Veteran


Joined: 27 Feb 2003
Posts: 1493
Location: Germany, Hamburg

PostPosted: Wed Sep 06, 2006 10:51 am    Post subject: Reply with quote

Polynomial-C wrote:
UncleOwen wrote:
They won't help. The only thing that will rebuild you /var/db/pkg is emerge -e world.

Which also won't work as world resides in /var/lib/portage/world

Ouch, you are right. Missed the part where ALL of /var was lost...
Back to top
View user's profile Send private message
tomk
Administrator
Administrator


Joined: 23 Sep 2003
Posts: 7219
Location: Sat in front of my computer

PostPosted: Wed Sep 06, 2006 12:03 pm    Post subject: Reply with quote

Moved from Portage & Programming to Duplicate Threads, please see these topics:

lost /var
Restoring /var/db/pkg?
_________________
Search | Read | Answer | Report | Strip
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Duplicate Threads All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum