Remove package manager installed program from command line?

Quick to answer questions about finding your way around Linux Mint as a new user.
Forum rules
There are no such things as "stupid" questions. However if you think your question is a bit stupid, then this is the right place for you to post it. Stick to easy to-the-point questions that you feel people can answer fast. For long and complicated questions use the other forums in the support section.
Before you post read how to get help. Topics in this forum are automatically closed 6 months after creation.
Locked
farna

Remove package manager installed program from command line?

Post by farna »

I'm not getting anything in my post on removing a Radeon driver, so I'm trying another tack! I found a proprietary ATI Radeon 9600 driver on the ATI site and have been reading the instructions. This IS NOT the driver I installed earlier, that one was in the GUI Package Manager. Right now I'm on my WinXP machine, the Radeon driver I installed is apparently for newer cards than my 9600 and has trashed the graphics video on my Mint machine.

The ATI instructions say:
"If the initial installation of the driver was done via the Operating Systems package
management software (RPM, APT, etc.) then please use that package management
software to remove the ATI Proprietary Linux Driver."

So how can I do this from the command line?

The document also says:
"If the ATI Proprietary Linux Driver was installed using either the Automatic or
Custom options, then do the following:
1 Launch the Terminal Application/Window and navigate to the /usr/share/ati
folder
2 With superuser permissions, enter the command "sh ./fglrx-uninstall.sh"
You have now successfully uninstalled the ATI Linux Proprietary Driver."

"Automatic or Custom options" refers to using the ATI installer software. But an I use
this method to uninstall anyway? I understand that in Mint I would have to use "sudo"
in front of the uninstall command.
Last edited by LockBot on Wed Dec 28, 2022 7:16 am, edited 1 time in total.
Reason: Topic automatically closed 6 months after creation. New replies are no longer allowed.
Fred

Re: Remove package manager installed program from command line?

Post by Fred »

farna,

To uninstall a program from the command line use the command below.

sudo apt-get --purge remove program_name

This will work if the program was installed using the package management system or it was registered with the package management system by the external install script.

If it wasn't registered with the package management system you will have to run the uninstall script, if there is one. Or failing that you will have to search the file system for all the pieces. Not a fun project in most cases.

As a rule of thumb, you should always favor using the repos and package management system. That is especially true for new users. :-)

Fred
farna

Re: Remove package manager installed program from command line?

Post by farna »

Thanks Fred! I'll give that a try. I've tried a number of things that haven't worked, and the Linux help files haven't been much help. I've considered just pulling the XP CD out and forgetting this frustrating thing! I'm not new to computers or cryptic operating systems, but it's been a long time (since a cryptic OS), and I had better manuals. Every "flavor" of Linux does things just enough different that a couple generic Linux books I have are going to the dump -- totally useless. "Linux for Dummies" doesn't have enough useful info to be worth the price. Lots of general info, not very useful once you've taken the plunge!

One simple thing -- is there no switch for the DIR command to pause per screen or list the directory in columns? I tried using the "man" command but saw nothing. There is a column width switch, but not enough there to tell how to use it. Putting in the number of columns desired doesn't work, and I tried characters across the screen too (64), and it didn't like that either! I do remember DOS having a "/p" switch for DIR to pause the screen when it's full, hit a key and it would fill the screen then pause again, until the entire directory had been displayed. Should be something similar in bash??
DrHu

Re: Remove package manager installed program from command line?

Post by DrHu »

farna wrote:I do remember DOS having a "/p" switch for DIR to pause the screen when it's full, hit a key and it would fill the screen then pause again, until the entire directory had been displayed. Should be something similar in bash??
In terminal, check
  • dir --help
You are able to pipe command ( | ) to either more or less to display by pages
dir |more
dir |less
  • you use the space key on the keyboard to page through the display
Linux commands..
http://www.comptechdoc.org/os/linux/use ... asics.html
farna

Re: Remove package manager installed program from command line?

Post by farna »

The Radeon driver is installed according to GREP (someone on LinuxQuestions.org suggested using 'dpkg -l | grep fglrx' to see if the modules were installed). I'm not the least bit familiar with the proper use (or any use!) of GREP, but it didn't give a location for the 3-4 modules it found, so it wasn't of much help. The same person had some other suggestions, but the Mint directory structure is different. I managed to get around that, but didn't know about piping to more or less (thanks Dr. Hu!! I needed that!!), which made manually searching directories difficult. I finally stumbled on the "find" command, which helped also. But I still haven't been able to restore video.

It shouldn't be so damned hard to remove a recalcitrant driver from the command line. I do understand that part of the difficulty is me being new to Linux, but help is hard to come by for newbies like me, especially with something like this. Instead of slipping my XP CD in though, I'm going to just do a fresh install of Mint. Won't be too hard to reconfigure, and only a few e-mail files will be lost for good. I tried booting from the CD and using the package manager, but that does no good... not that I thought it would.

Would be nice if there were a recovery mode that wouldn't delete all user files, but I'm not betting on it! THAT is something to put on the list!! XP will do a recovery install that just replaces OS files and leave the rest of the directory structure (and installed files, desktop, etc.) alone. Rarely fixes things, as XP is usually well munged up by the time someone tries to use it, but it should work well in Linux.
I'm not too disappointed that I'm having to reinstall everything to get the system back, was sort of expecting it.

I've also decided that the Radeon 9600 needs to go! The only other AGP card I have on hand is an ATI Rage 128 w/64MB, so I'm leaving the 9600 in for now. So I'm going to search the forum for a video card recommendation that will do 3D hardware acceleration. That might fix some Windows/Wine software problems...
Rifferation

Re: Remove package manager installed program from command line?

Post by Rifferation »

It has been brought to my attention I posted this in the wrong location and I apologize, no need to read the next three lines.
Last edited by Rifferation on Fri Nov 13, 2009 4:09 pm, edited 1 time in total.
mick55

Re: Remove package manager installed program from command line?

Post by mick55 »

Please don't hijack someone else's thread.
This is closely related to what I am looking for.
This has absolutely no relation to the above topic about removing a
video card driver.
When you install a program using wine where are the files located.
When you install a program through Wine it installs to the C drive.

If you need further assistance open your own topic.
Rifferation

Re: Remove package manager installed program from command line?

Post by Rifferation »

my mistake, I consciously try not to hijack threads, I thought they were trying to uninstall wine programs from the command line utility and was hoping that would lead to the location of the files are located, for some reason I looked all over my C drive and couldn't find it, please disregard these three lines they contain absolutely no relevant information whatsoever.
Locked

Return to “Beginner Questions”