This is a bug that’s really been bothering me since I installed Ubuntu 8.04 Beta. When using Compiz, window shadows would appear pink, another odd colour, or not at all. Restarting Compiz a few times would usually cause the shadows to stop displaying.
This is a bug in the way that the proprietary Nvidia driver is packaged for Ubuntu. It’s been known for a while, but recently a somewhat easy workaround has been found.
The command below creates a symlink for the Nvidia driver. Copy and paste it (one line) into a terminal and run it:
sudo ln -sf /usr/lib/nvidia/libwfb.so.xserver-xorg-core /usr/lib/xorg/modules/libwfb.so
Log out and back in, and your Compiz shadows should be working properly. Hopefully now it won’t be long until the the package is fixed.