If you’re like me and use GNOME Do in dock mode and have it start on login in Ubuntu 10.04 you’ve probably noticed that it seems to crash when you login. After a long while putting it off I eventually went in search of a solution. It seems that Compiz and GNOME Do don’t like loading at the same time. So the solution is to delay GNOME Do from loading until Compiz is loaded, which seems to stop GNOME Do from crashing on Ubuntu. I found the solution on the Ubuntu forums, posted by stinkeye. Below I have copied stinkeye’s instructions so they are not lost in the Ubuntu forums.

How-To

Firstly I would make sure you are running Compiz at startup by installing wmctrl.

sudo apt-get install wmctrl

Once installed, type in the below command and you should get terminal output like the one below

wmctrl -m

and it should tell you what window manager is running.

For example, I get

Name: compiz Class: N/A PID: N/A Window manager's "showing the desktop" mode: OFF

This is a script used to delay gnome-do from starting till compiz is loaded.

#! /bin/bash until [ "$done" = "true" ] do if [ $(dbus-send --print-reply --type=method_call --dest=org.freedesktop.compiz /org/freedesktop/compiz/dbus/screen0 org.freedesktop.compiz.list | wc -l) != 0 ] then DISPLAY=:0.0 gnome-do >/dev/null 2>&1 & done="true"; else echo "GNOME-DO IS WAITING" done="false" sleep 5; fi done exit 0

Save this in your home folder as start_do. Right click on start_do, go to Properties -> Permissions and tick the “execute” box. Go to your gnome do preferences and untick start gnome-do at login. Open startup applications and add start_do to the startup programs by adding

/home/your-username/start_do

Now when you boot that script will be run and only start GNOME Do once Compiz has been completely loaded. Again a big thanks to the original poster of the instructions, stinkeye on the Ubuntu forums

[ad#Adsense_inLine_336*280]