RiM3Y.net | BlogZero

Neither a nerd nor a geek. Just born techie.

RiM3Y.net | BlogZero - Neither a nerd nor a geek. Just born techie.

Gutsy and Compiz Fusion

I used to run Ubuntu 7.04, and I’m very happy with it. Everything works, including my Compiz Fusion (after some XGL tweaking). Just about 2 hours Ubuntu Gutsy 7.10 released, I immediately upgrade my system. After 4 hours of upgrading, I received a message saying that I should remove my XGL session as it is no longer needed.

Short story, I enabled my restricted driver, removed XGL session, and enable effect appearance. However, I cant enable some plugin as it won’t save whatever setting I made. Research after research and test after test, after several start and reboot, I finally find the solution. I want to link to all the resources I found but I realise some site can be down when you need it the most. So I compile and rewrite it here. Credits goes to Michael37.

 

Before we begin — supported hardware list
Taken from fglrx driver description for Gutsy.
This version of the ATI driver officially supports:

  • FireGL: V7350, V7300, V7200, V7100, V5200, V5100, V5000, V3400,
    V3300, V3200, V3100, X3-256, X3, X2-256, Z1-128, T2-128,
    X1-128, X1-256p
  • FireMV: 2200 (Single card PCI-e configuration)
  • Mobility FireGL: V5000, T2
  • Mobility Radeon: X1800, X1600, X1400, X1300, X800, X700, X600, X300,
    9800, 9600, 9550, 9500
  • Radeon Xpress: 200M series, 1250 IGP, 200 series
  • Radeon: X1900, X1800, X1600, X1300, X850, X800, X700, X600, X550,
    X300, 9800, 9700, 9600, 9550, 9500

ATI All-in-Wonder variants of the above cards/chips are also supported,
but video capture is not.

If you are doing fresh install of Gutsy

  1. Enable fgrlx driver.
    Install linux-restricted-modules and restricted-manager provied in the restricted repositories:

    Code:

    sudo apt-get update

    sudo apt-get install linux-restricted-modules-generic restricted-manager

     

    Open the restricted drivers manager in “System -> Administration -> Restricted Drivers Manager” and select “ATI accelerated graphics driver”.

  2. Install xserver-xgl package

    Code:

    sudo apt-get install xserver-xgl

     
  3. Install compiz

    Code:

    sudo apt-get install compizconfig-settings-manager compiz compiz-core compiz-fusion-plugins-main compiz-fusion-plugins-extra compiz-gnome compiz-plugins libcompizconfig-backend-gconf libcompizconfig0
    
    
  4. Reboot
  5. Log in. 3D effects should be enabled!
  6. Customize Compiz Fusion.
    Select System → Preferences → Advanced Desktop Effects Settings
    In the new window, General Options → Desktop Size → Horizontal Virtual Size. Set it to 4.
    The other two options have to be left at 1.
    Continue customization per Forlong’s guide at http://forlong.blogage.de/article/2007/8/29/How-to-set-up-Compiz-Fusion

 

If you are upgrading from Feisty 7.04 or earlier versions and you have run Xgl before.
When upgrading, you may experience blank screen, a screen with no windows and toolbars, a screen with only a background, or any other mess. It is caused by the customized scripts for Xgl which do not work with Gutsy. So, we need to clean up.
If you really can’t log into a working X session and open a terminal, simply press “Ctrl-Alt-F1” to get into the text prompt and follow the removal steps (1-4) from the text interface. After a reboot, the graphics should work better.

  1. Remove compiz

    Code:

    sudo echo "activate sudo"

    sudo apt-get --purge remove compiz*

    sudo apt-get --purge remove libcompiz*

    sudo apt-get --purge remove libdecoration0

    sudo apt-get --purge remove compizconfig-settings-manager

    sudo apt-get --purge remove python-compizconfig

     

  2. Remove Xgl

    Code:

    sudo apt-get --purge remove xserver-xgl
    
    

     
  3. Clean up

    Code:

    sudo apt-get autoremove
    
    

     
  4. Remove customizations

    Code:

    rm -rf ~/.compiz

    rm -rf ~/.config/compiz

    rm -rf ~/.gconf/apps/compiz

    sudo rm -i /usr/local/bin/startxgl.sh

    sudo rm -i /usr/share/xsessions/xgl.desktop

     

    When asked to remove the files, type YES. If the files were present and you removed them, proceed to the next item. Otherwise, undo customizations to /etc/gdm/gdm.conf and /etc/gdm/gdm.conf-custom that you have made from this section of the guide

  5. Reboot
  6. Login back in and find yourself in a 3D effect devoid session. You may not even be running a windows manager. If you can’t move windows and don’t see window decorations, press “Alt-F2” and type

    Code:

    metacity --replace
    
    

     
  7. Verify that everything else is working properly, e.g. Firefox opens, Wired and/or Wireless Network connects, etc. This is the best time to troubleshoot everything else until we enable 3D effects.
  8. Enable fgrlx driver.
    Install linux-restricted-modules and restricted-manager provided in the restricted repositories:

    Code:

    sudo apt-get update

    sudo apt-get install linux-restricted-modules-generic restricted-manager

    Open the restricted drivers manager in “System -> Administration -> Restricted Drivers Manager” and select “ATI accelerated graphics driver”.

  9. Reboot if necessary.
  10. After reboot, log back in.
    Open terminal and run

    Code:

    fglrxinfo -display :0
    
    

    and verify that you see something like this:

    display: :0.0  screen: 0
    OpenGL vendor string: ATI Technologies Inc.
    OpenGL renderer string: ATI Mobility Radeon X1400
    OpenGL version string: 2.0.6473 (8.37.6)

    If you don’t have command fglrxinfo, you either don’t have a supported ATI card or you missed a step or two. Go back through all steps.
    If you see “Mesa GLX Indirect” instead of “ATI Technologies”, see Troubleshooting section below. If still unsure, post your /etc/X11/xorg.conf in this thread. DO NOT CONTINUE INSTALLATION UNTIL YOU FIX THIS ISSUE AND GET RID OF MESA.

  11. =================================
  12. Are you ready to get back into the wobbly windows and Desktop Cube?
  13. =================================
  14. Install Xgl.

    Code:

    sudo apt-get install xserver-xgl
    
    

     
  15. Install compiz

    Code:

    sudo apt-get install compizconfig-settings-manager compiz compiz-core compiz-fusion-plugins-main compiz-fusion-plugins-extra compiz-gnome compiz-plugins libcompizconfig-backend-gconf libcompizconfig0
    
    

     

  16. Reboot
  17. Log in. 3D effects should be enabled! You no longer need to select a special Xgl session.
  18. Customize Compiz Fusion.
    Select System → Preferences → Advanced Desktop Effects Settings
    In the new window, General Options → Desktop Size → Horizontal Virtual Size. Set it to 4.
    The other two options have to be left at 1.
    Continue customization per Forlong’s guide at http://forlong.blogage.de/article/2007/8/29/How-to-set-up-Compiz-Fusion

 

Troubleshooting
Solving the ‘Mesa nightmares’ mystery. This is becoming a hot topic in this guide.
A common problem in step 10 is fgrlxinfo output like this:

# fglrxinfo -display :0
display: :0.0 screen: 0
OpenGL vendor string: Mesa project: www.mesa3d.org
OpenGL renderer string: Mesa GLX Indirect
OpenGL version string: 1.4 (2.1 Mesa 7.0.1)

That means you are not using the restricted driver. Enable it via Restricted Driver Manager — see step 8. Just in case, run command

Code:

sudo aticonfig --initial

 

then reboot.

More Mesa troubleshooting.

Some people reported broken drivers. This has nothing to do with compiz or Xgl — it’s a matter of having a broken driver installed. Technically speaking, there are two drivers for the video card. One driver is a part of the kernel, and one driver is for X. They need to both work and match.

Kernel driver
Verify that the most recent kernel is installed:

Code:

uname -r

should 2.6.22-14-generic
and both packages are installed:

Code:

dpkg -l linux-restricted-modules-2.6.22-14-generic

dpkg -l linux-image-2.6.22-14-generic

Check if your kernel module is loaded:

Code:

lsmod | grep fglrx

should return something like:

fglrx 765588 51

You can also check if you are using the right version of the kernel
driver:

Code:

modinfo fglrx

 

should return something like this:

filename: /lib/modules/2.6.22-14-generic/volatile/fglrx.ko
depends: agpgart
vermagic: 2.6.22-14-generic SMP mod_unload 586
license: Proprietary. (C) 2002 – ATI Technologies, Starnberg, GERMANY
description: ATI Fire GL
author: Fire GL – ATI Research GmbH, Germany
parm: firegl:charp

If you don’t have fglrx kernel module loaded, please report the problem in this thread. I don’t have generic instructions for you yet.
If you are running a wrong version of kernel, your install may have a bigger issue than non-working 3D effects. Please address those issues first.

 

X driver
See if your X driver is installed

Code:

dpkg -l xorg-driver-fglrx

 

You should have version 7.1.0-8.37.6+2.6.22.4-14.9 installed. If you got something else, I recommend to uninstall it and reinstall it:
Typical output is:
ii xorg-driver-fg 7.1.0-8.37.6+2 Video driver for ATI graphics accelerators

Code:

sudo apt-get --purge remove xorg-driver-fglrx

sudo apt-get install xorg-driver-fglrx

 

Once done, reboot and get back into X session. Go back to step 8 and enable the restricted driver. You may need yet another reboot after enabling the driver.
If that didn’t help, you are running into the dreaded “Mesa issue”. Gutsy “Restricted Driver Manager” does everything possible to avoid it. I have never run into the “Mesa issue”, so I don’t know how to troubleshoot it. Please refer to this excellent updated Wiki page or Fixing the “Mesa Issue” for ATI Cards thread — the original post is very outdated, but the troubleshooting section at the end is good.

 

Envy and/or newer drivers from ATI
Some users report using Envy or alternative mechanisms to install newer drivers. This is very dangerous. As this press-release indicates, many with older GPUs had immediately upgraded with some then having a foul experience. In this guide, “older” means anything but 2000HD series!!! That’s what most of us run. So, if you have have a video card from the supported hardware section (see my previous post), then you must not upgrade to the newer driver.

 

References
DO NOT FOLLOW THESE LINKS BLINDLY. MOST ARE WRITTEN FOR FEISTY AND THIS GUIDE UNDOES WHAT IS SUGGESTED IN THESE GUIDES.
http://ubuntuforums.org/showpost.php?p=3285132&postcount=217
http://ubuntuforums.org/showthread.php?t=488385
https://help.ubuntu.com/community/BinaryDriverHowto/ATI
https://help.ubuntu.com/community/RestrictedDrivers/ATI
https://help.ubuntu.com/community/CompositeManager/Xgl