Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

Possible Duplicate:
How to forbid a specific package to be updated?

I don't want my kernel or grub updated until I do it manually. Is this possible in Ubuntu (10.04, I suppose)?

share|improve this question

marked as duplicate by hhlp, Jorge Castro, Marco Ceppi Feb 20 '11 at 14:16

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

    
posible duplicate askubuntu.com/questions/18654/… –  hhlp Feb 19 '11 at 17:25
add comment

2 Answers 2

up vote 9 down vote accepted

As your question is tagged synaptic, I'll assume that this you package manager of choice. In order to hold a package back with synaptic, you simply need to "lock the version."

Find and select the package you wish to hold back. Then go to Package > Lock Version in the menu bar.

synaptic

When you are ready to upgrade that package, simply highlight the package and un-check "Lock Version." It can now be upgraded normally.

If you like to do this from the command line, you can use dpkg --set-selections

echo package_name hold | sudo dpkg --set-selections

To remove the hold, run:

echo package_name install | sudo dpkg --set-selections
share|improve this answer
    
what if I dont have synaptic, I mean I want to learn if there are some-other way to do it? –  pahnin Feb 19 '11 at 13:32
    
The worst thing about this is that locking the package in synaptic has absolutely no influence on apt-get - even if you lock in synaptic, apt-get will still want to upgrade the packages (check with dpkg --get-selections packagename afterwards); so the package_name hold | sudo dpkg --set-selections is required for apt-get, independently of synaptic. Cheers! –  sdaau Jun 7 '12 at 11:17
add comment

The best resource I know of for explaining the different ways to accomplish this kind of package hold is on the Ubuntu Pinning How-to page . I really recommend checking it out. It describes several ways to do this in addition to using the Synaptic lock as andrew has detailed.

There are solutions to closely related problems in several threads on askubuntu.

Is There a Way to Disable Kernel Updates?

Blacklisting Packages from Installing

How to Prevent Package Removal Upon Upgrade

How to Remove a Package from the List of Packages to be Installed

How Do I Pin a Particular MySQL Version to Avoid Unnecessary Upgrade

share|improve this answer
    
It hurts me to say this, but the GUI approach is so much easier. =( –  Erigami Feb 19 '11 at 9:06
    
Relly? Seams to me the Pinning How-to page shows how to do it with one command. –  Rafał Cieślak Feb 19 '11 at 14:02
add comment

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