Create your dream Linux PC and support maysville linux users group!

Home  

 


  Create an account

Search


[x]  
 
 [x]
Categories Menu
· All Categories
· Commands
· Distro News
· General
· Link of the Week
· Linux Jobs
· Security
· Software
· Tips

 
Navigation
 
User Info
Welcome, Anonymous

Username:
Password:

(Register)

Membership:
Latest: lnkpmob
New Today: 0
New Yesterday: 0
Overall: 313

People Online:
Visitors: 7
Members: 0
Total: 7

 
hacker Beware
You have been warned!
We have caught 1741 shameful hackers.

NukeSentinel(tm) 2.5.14

 
Hot Downloads
 
  
Maysville Linux Users Group (MLUG) - Linux Users Helping Linux Users: Forums

MLUG :: View topic - gentoo / sabayon libdbus-1.so.2 errors
 Forum FAQForum FAQ   SearchSearch   UsergroupsUsergroups   ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 


gentoo / sabayon libdbus-1.so.2 errors

 
Post new topic   Reply to topic    MLUG Forum Index -> Help Requests
View previous topic :: View next topic  
Author Message
ewiget
Site Admin
Site Admin


Joined: Aug 13, 2004
Posts: 344
Location: Maysville, KY

PostPosted: Thu Dec 14, 2006 6:38 am    Post subject: gentoo / sabayon libdbus-1.so.2 errors Reply with quote

I have been pulling my hair out over many errors related to libdbus-1.so.2 in sabayon linux (based on gentoo). Practically every single gnome application is dependent on it. Let me explain what happened:

There are graphical utilities, such as kuroo, that allows you to update packages on your gentoo/sabayon linux distribution. I have used gentoo for years, but recently started using sabayon because the installation is only about 10 minutes for a working system verses about 7 days for a gentoo stage 1 install. Anyways, I prefer to do the old fashioned command line way of updating which basically requires these steps:

First, we need to sync with the repositories and download any changes. To explain the code:

'emerge' is the actual command



'--sync' means to sync the local repository with the only repository



'&&' means when the first command completes, do the next command



'layman' is the command used to sync with optional 'overlay' repositories. An overlay repository is generally stuff that is not considered stable enough to be in the main gentoo repositories



'-S' is the same as --sync but is the short format for '--sync-all'



Code:

emerge --sync && layman -S





Next, I get a full listing of what will be updated for system profile. The 'system' profile is the base system, basically what the system needs to function and compile other applications.

Some explanation about the code: (only explaining what I haven't explained)




'p' means pretend, don't do anything but display what you will do.



'u' means update packages that need updating.



'v' means verbose, print lots of information.



'D' means deep, also compile dependancies that are needed if they are not already available.



There is two other option not used here that are used in special circumstances. I will explain anyways:



'N' option which is what you would use if you specific new use flags in the /etc/make.conf file.



'e' options is used when you want to 'empty' the portage cache. This means to emerge everything in this profile - usually only done after you upgrade the kernel, glibc, or some other very major part of linux base system that deals with the compiler (such as changing CFLAGS (will cover this some other time).

Since I hadn't specified any new use flags and I don't need to empty the system file, this is my code for updating the system:



Code:

emerge -puvD system



Also, I can use emerge and pipe to redirect the emerge results to the wc command to display a count. The code explanation:



'wc' means print newline, word, and byte counts for file



'-l' is for lines

So, if I wanted to know how many packages were in my base system I would use the command:



Code:

emerge -pe system | wc-l





And it gives the result 265.





If the first pretend upgrade looks o.k., you then remove the 'p' option and re-run the code again to actually update the system:



Code:

emerge -uvD system







Next is updating 'world'. world means all other packages on the system. Everything else is identical, except the code looks like this:



Code:

emerge -puvD world

So anyways, back to my problem. I had already updated system and updated world using the methods above. But, I had some major system packages updated during these updates and I needed to use the '-pe' option for both system and world. System had completed just fine, but during the world command, I had to stop in order to go on a service call. This is generally not a good thing to do.

After I had to stop world, several days later I went back to finishing where I had left off....except I did the '-uvD' options first and that was the mistake I made.



Code:

revdep-rebuild





Which checks all system libraries and files and recompiles any that are broken, generally in the correct order that the packages need compiled. Except, in my case, it wouldn't work because it didn't know the correct order. Everything it wanted to recompile failed due to libdbus library.

What I had to do to fix it was:



Code:

emerge dbus dbus-glib





Then run the revdep-rebuild command again.

I had to do a little trick to force it to continue, otherwise I would have to manually restart the emerge with the --resume and --skipfirst options. Those options mean:



'--resume' - start where you left off



'--skipfirst' - skip the first package (meaning the one that failed)

The little trick I used was this command (you could compare this to a "FOR" loop, but its strictly bash:



Code:

emerge --resume --skipfirst || until emerge --resume --skipfirst; do emerge --resume --skipfirst; done





What the above code does, is basically says "everytime you fail, restart automatically using the options --resume --skipfirst until you are completely done.

When that completed, now I had to run revdep-rebuild again because I had to skip some packages since they weren't in the correct order, until there were finally no more packages left.

This required me to do this (as root user in a terminal and also within the root directory /root):



Code:

rm -rf .revdep*





This removes the old hidden .revdep* directories from when I ran revdep-rebuild previously.



Code:

revdep-rebuild





Check for missing libraries and packages again.

If it fails, use the trick above with the emerge --resume --skipfirst || until emerge --resume --skipfirst; dp emerge --resume --skipfirst; done

When it completes, start over again first deleting the .revdep* directories, then running revdep-rebuild, and if it fails, run the long LOOP command again.

Finally it completed but I still had the same error messages as when I started.  So, then I used equery command to list all of the packages related to dbus-glib and dbus and what I found made me realize the simplist thing was the problem all along:

cd /usr/lib

ls -la libdbus*

if the libdbus-1.so.2 file does not exist, then create the correct link (use the same file that all the other libdbus* files link to, in my case it was libdbus-1.so.3.2.0

ln -s libdbus-1.so.3.2.0 libdbus-1.so.2

Then revdep-rebuild one more time to fix all problems....problem resolved and the funny thing is, it wasn't that big of a deal to fix had I just checked to make sure the link existed beforehand.  Sometimes when there is a problem in linux, you can "think" the problem is worse or harder to fix than it really is....and often times, it turns out being the simplist things....like a damn missing link.


_________________
Ed Wiget
RHP Studios
Keeping Your Data Safe!
606-759-1175
http://www.rhpstudios.com
http://www.xtremewebhosts.com
http://www.edwiget.name
http://counter.li.org/cgi-bin/runscript/display-person.cgi?user=162711

Back to top
View user's profile Send private message Visit poster's website AIM Address Yahoo Messenger MSN Messenger
Display posts from previous:   
Post new topic   Reply to topic    MLUG Forum Index -> Help Requests All times are GMT + 10 Hours
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

Powered by phpBB © 2001, 2005 phpBB Group
Forums ©

 
All content Copyright 2000 - 2008, Maysville Linux Users Group unless otherwise credited.
All Rights Reserved!
The opinions expressed by visitors to this web site are their own and not necessarily the opinions of the MLUG!


Web site powered by PHP-Nuke Web site powered by PHP-Nuke-NIP-76.0

You can syndicate our news using the file backend.php or ultramode.txt