Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I installed downloaded from the ATI Website.

However I installed the generic version instead of building a distribution specific installer.

Now I have the gnome-shell graphic glitches that are associated with having the old Fglrx drivers installed.

How can I remove these drivers? They do not show up in the additional drivers dialog, and I cannot install any other drivers till these are removed.

share|improve this question
up vote 18 down vote accepted

Run both this commands:

sudo sh /usr/share/ati/ 
sudo apt-get remove --purge fglrx fglrx_* fglrx-amdcccle* fglrx-dev*

Plus refer to this site: ATI - Ubuntu Oneiric Installation Guide

share|improve this answer
after running the first one I get sh: Can't open /usr/share/ati/ should I still run the second command? – Hailwood Nov 13 '11 at 0:19
"Skip the first command if it does not exist". As stated in the link I sent you. – bioShark Nov 13 '11 at 0:21
So yes...just the second command is needed. Did it work? – bioShark Nov 13 '11 at 0:32
Thank you very muchly :D – Hailwood Nov 13 '11 at 0:47
The first command also didn't work for me but the second worked like a champ after removing the ` from the end of the command. Ty for the tip bioshark – user37314 Dec 9 '11 at 20:19

Removing Catalyst/fglrx

The uninstall script in the first command will only exist if you downloaded the drivers and installed them directly (rather than building packages as this guide does). Skip the first command if it does not exist.

sudo sh /usr/share/ati/
sudo apt-get remove --purge fglrx fglrx_* fglrx-amdcccle* fglrx-dev*

If you plan on using open-source drivers, you will need to reinstall some packages because Catalyst overwrites or diverts some key 3D libraries with proprietary versions. For more information on this issue, see this Ubuntu wiki page

sudo apt-get remove --purge xserver-xorg-video-ati xserver-xorg-video-radeon
sudo apt-get install xserver-xorg-video-ati
sudo apt-get install --reinstall libgl1-mesa-glx libgl1-mesa-dri xserver-xorg-core
sudo mv /etc/X11/xorg.conf /etc/X11/xorg.conf.backup
sudo rm -rf /etc/ati

If you receive $ E: Internal Error, No file name for libgl1-mesa-dri, change the third command above to:

sudo apt-get install --reinstall libgl1-mesa-glx:i386 libgl1-mesa-glx:amd64 libgl1-mesa-dri:i386 libgl1-mesa-dri:amd64 xserver-xorg-core

After you finished all, reboot, then install the legacy 12.6 Driver, following the same procedure in the same Wiki:

Start from "Before you start" section, and skip the "wget" download, instead use the 12.6 Legacy you have downloaded. All the rest the same. It will eventually work !

After you installed, do not forget to:

sudo amdconfig --initial -f
share|improve this answer

The most thorough removal attempt involves running two commands. However, there are several possible variants of the first command. In general, the two commands look like this (in pseudo code):

sudo sh /path/to/
sudo apt-get remove --purge fglrx and related packages

Now let me give the specific actual commands.

First Command:

Here are all the variants of the first command. Try them in order. When you get one that works, you are done and you can move on to the second command:

sudo sh /usr/share/ati/
sudo sh /usr/share/ati/
sudo sh /usr/share/ati/ 
sudo aticonfig --uninstall (NOTE: assumes the executable is in the path)
sudo sh --uninstall 

As you probably see, the first 3 variants just involve changes to the script name that happened over time. You could simply do a listing of /usr/share/ati/ and look for the correct file name rather than trying all 3 of those command variants.

The last two variants come from the official Catalyst Linux doc. These involve passing the --uninstall parameter to another script. However, you still need to find the correct name of that script. There could be more variants than shown above, although these are the only two listed in the official Catalyst Linux doc.

If you get a response to any of the first command variants above like this:

failed: No such file or directory

then try the next variants. If you exhaust all the variants of the first command without anything executing, consider the job done.

Second Command:

Now, execute the second command. This form should cover all cases (thanks to the use of wildcards):

sudo apt-get remove --purge fglrx fglrx_* fglrx-amdcccle* fglrx-dev*  

Restore original config

The original Xorg configuration file was automatically restored for me by the above steps. However, the official Catalyst Linux doc gives the following manual steps:

  • Locate backup configuration files: ls /etc/X11/xorg.conf.original-*
  • Take the latest version with the highest number and copy it over the existing xorg.conf file: cp /etc/X11/xorg.conf.original- /etc/X11/xorg.conf

Furthermore, I think it is important to read this link:

X/Troubleshooting/VideoDriverDetection - Ubuntu Wiki

This question is about removing fglrx, but you also want to be able to reboot your computer into a working configuration after removing fglrx. The link above gives several steps. I think they are probably too long to paste here since it is not directly related to the question. But I mention it because it is important to reinstall the original drivers. In short, the command will be similar to:

sudo apt-get install --reinstall libgl1-mesa-glx libgl1-mesa-dri xserver-xorg-core

lts hardware enablement stack

Important: if you are running the lts hardware enablement stack, things may be a bit more difficult. I found a solution here:

It is in response to this question:

12.04 - Experiencing major issues on graphic displays - Ask Ubuntu
Experiencing major issues on graphic displays

See the link for full details.

Here are some related links:

Microsoft Word - Catalyst_Linux_Installer.doc - catalyst_linux_installer.pdf

BinaryDriverHowto/ATI - Community Ubuntu Documentation

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.