How to remove gzip from Linux

10,476

Solution 1

Package gzip has priority "required", meaning it must always be installed for the system to work properly. Probably aptitude is therefore refusing to remove it. What output did you get from the remove command?

BTW: Why do you want to remove gzip? Doing so is a really bad idea...

Edit:

If you see gzip consuming a lot of CPU, that's because some other program is using it. If you want to do something about this, find out which program is calling gzip, and change the program (if possible). To do this, use pstree -apl to see all processes with their parents, look for gzip and what its parents are, then check why they call gzip.

Solution 2

i wasn't reading carefully when i tried to uninstall it. this is what it says

WARNING: Performing this action will probably cause your system to break!
         Do NOT continue unless you know EXACTLY what you are doing!
To continue, type the phrase "I am aware that this is a very bad idea":

Abort.

Solution 3

gzip is a very important tool for each and avery linux distribution. Many applications store their files in a compressed format. GZip can create and handle these files.

AFAIK on most distribution management systems like deb and rpm the pacakges are gzipped, too. Basic tools like logrotate use gzup compression. etc, etc, etc. Uninstalling gzip will most likely render your system unuseable and may prevent you from reinstalling it.

If gzip is taking up a lot of resources it's most likely the case that some other application is calling gzip to compress something. In this case gzip is just called as a tool.

Share:
10,476

Related videos on Youtube

tony_sid
Author by

tony_sid

Born and raised in California. Computers are my main hobby.

Updated on September 17, 2022

Comments

  • tony_sid
    tony_sid over 1 year

    I tried

    sudo aptitude remove gzip

    and it looked like it uninstalled but when I typed gzip at the terminal it still ran.

    • HiFi
      HiFi over 13 years
      Umm... why do you want to remove GZip?
    • tony_sid
      tony_sid over 13 years
      i've seen it use lots of cpu and slow down the system. i want to replace it with something else.
    • Janne Pikkarainen
      Janne Pikkarainen over 13 years
      The good news is that if you remove gzip, your system will have a lot of free CPU time, since your system WILL break. gzip isn't a bastard who just consumes CPU just because it's fun, it's a mandatory component used by everything from package management to uncompressing man pages. Do. Not. Remove. Gzip. Doing so is a tip told by a Bad Idea Panda.
    • tony_sid
      tony_sid over 13 years
      If I can't remove gzip then how about replacing it with another program that can do the same thing?
    • user3660103
      user3660103 over 13 years
      @awakeFromNib I don't think that would help. There are few reasons for that: First something is calling gzip. If there is another program that can take gzip's place, that same thing would call the replacement program instead so in the end result would be same. Something else would take up lots of CPU time. Second, lots of programs call gzip and give it command line parameters. Would other program be able to perfectly mimic gzip? You could attempt to somehow get BSD version of gzip (which is different from GNU zip on GNU/Linux), but the main thing is that problem is something else.
    • user3660103
      user3660103 over 13 years
      @awakeFromNib This analogy is a bit simple, but I think that it correctly describes situation: Imagine that you feel dizzy and ask doctor for help and he says "No problem! We'll just chop your head off and get you a new one!" and later it turns out that problem was hypotension!
    • tony_sid
      tony_sid over 13 years
      7zip on Windows is a newer archiver/unarchiver that performs quite well. I think it does better than gzip. I heard that there is a version for Linux. I would like to try to replace gzip with that.
    • user3660103
      user3660103 over 13 years
      @awakeFromNib Check out their man pages. p7zip and gzip have different commands. You'd have to make another program called gzip which will cal p7zip and translate command line arguments. Some cannot be translated. It will still break your system.
  • lajuette
    lajuette over 13 years
    Trust me. It IS a VERY bad idea.
  • sleske
    sleske over 13 years
    Just as I said... even aptitude says it's a bad idea ;-). BTW: Please do not post answers to supplement your question - edit the question instead.
  • tony_sid
    tony_sid over 13 years
    No it wasn't a supplement to my question, but the answer to my question. However someone else posted a better answer so I selected it as the answer.