apt-get update > apt-get upgrade again!

Discussion in 'Server Operation' started by edge, Jan 6, 2007.

  1. edge

    edge Active Member Moderator

    Okay,

    On one of my Denian Sarge servers I still have the "old" 2.4 kernel as backup.
    I'm using the 2.6.8-3-686-smp kernal.

    Now when I apt-get update and apt-get upgrade, I get the following:

    I do not want to upgrade the 2.4.27-3 stuff.
    Is there a way to kill this message, so what it does not show anymore when I do a apt-get update > upgrade?
     
  2. Hans

    Hans Moderator ISPConfig Developer

    I think you can do that with:

    apt-get hold <packagename>

    To undo it again:

    apt-get unhold <packagename>

    To see what your packages on hold are, do an:

    dpkg --get-selections | grep hold


    I think it is possible that way, but maybe Falko has a better solution for you.
     
    Last edited: Jan 6, 2007
  3. edge

    edge Active Member Moderator

    Eej Hans,

    No apt-get hold here :/
    I think I need to use the -d option (Download only - do NOT install or unpack archives)
     
  4. iberry

    iberry New Member

    the answer is "pin"

    Seems that what you want to do is pin to that version of the 2.4 kernel. Pinning is described in section 3.10 of the APT HOWTO.

    For example, I have pinned to version 0.5.* of network-manager by creating and adding the following lines to /etc/apt/preferences:

    Package: network-manager
    Pin: version 0.5*
    Pin-Priority: 1001

    Hope that helps to point you in the right direction.

    --Ian

    apt-get moo
     
  5. Hans

    Hans Moderator ISPConfig Developer

    Maybe this:

    To put a package to hold:
    echo "package_name hold"|dpkg --set-selections

    to 'unhold' it:
    echo "package_name install"|dpkg --set-selecions

    To see what your packages on hold are, do an:

    dpkg --get-selections | grep hold
     
  6. edge

    edge Active Member Moderator

    Welcome to the helping team iberry!

    pin does look like a nice option, and I'll give it a try on a test server later today.

    Hans,

    I'll give your option also a go.
     
  7. edge

    edge Active Member Moderator

    Looks like echo "package_name hold"|dpkg --set-selections did the trick for me

    and
    and
     
  8. Hans

    Hans Moderator ISPConfig Developer

    That's nice!

    I've also read that if you use aptitute that you can put an "=" in front of the package name to set it on hold.

    (i use apt myself not aptitute)
     
  9. falko

    falko Super Moderator ISPConfig Developer

Share This Page