The command to upgrade to a new kernel from Ubuntu repositories

24,789

Solution 1

Simply installing the new kernel package will handle everything for you. Most of the time, you want to go ahead and upgrade all of your packages, as it will mostly include bug fixes and security updates:

apt-get update
apt-get upgrade

If you call "install" on a package that is already installed, it will be upgraded if an upgrade is available.

apt-get update
apt-get install linux-image-ac100

Solution 2

On Ubuntu, there is no special command to upgrade the kernel. All kernels come with the standard packaging mechanism. If you run the usual upgrade commands, either from the graphical interface (that's what most Ubuntu users use), or from the command line (apt-get update && apt-get upgrade). The package's post-installation scripts take care of updating the bootloader and the initramfs.

You mention a PPA at https://launchpad.net/ubuntu/quantal/+source/linux-ac100. A PPA is not part of Ubuntu, it's a third-party package that Ubuntu provides an installation channel for. This particular PPA is managed by the Ubuntu kernel team, so it's pretty close to official. However, you link to the page for quantal, which is Ubuntu 12.10, currently alpha. Unless you want to test (as opposed to use) the next Ubuntu release, stick to precise (Ubuntu 12.04). The latest kernel version in this PPA at the time of writing is 3.0.27.

If you've added the PPA in the Software center or manually under /etc/apt/sources.list.d/, the usual system upgrades will pull in upgrades to the PPA as well.

If you want to have an even more recent kernel, you're pretty much on your own. Ubuntu releases a new distribution every 6 months, they do not support intermediate upgrades except for grave bugs.

Solution 3

Have you tried the Ubuntu Update Manager? (System->Administration->Update Manager)

Solution 4

Try the following command in your terminal

sudo apt-get install linux-generic
Share:
24,789

Related videos on Youtube

imz -- Ivan Zakharyaschev
Author by

imz -- Ivan Zakharyaschev

My name is Ivan Zakharyaschev, Иван Захарьящев, imz.

Updated on September 18, 2022

Comments

  • imz -- Ivan Zakharyaschev
    imz -- Ivan Zakharyaschev over 1 year

    In the distro I'm most familiar with -- ALTLinux, a command like apt-get install kernel-image-std-def#3.0.... would install another kernel, and update the initramfs and the bootloader config accordingly; an even better command would be the specific update-kernel, which would also install the accompanying kernel modules for the new version of the kernel (the ones that are installed in the running system, so that the support for the hardware of this system is not lost in the case of the new kernel). (A short manual on this topic for ALT (in Russian).)

    Now I want to upgrade the kernel in my Ubuntu 12.04 system on a Toshiba AC100 (ARM). What would be the command in Ubuntu to install the new kernel, so that all the required things are done: initramfs is generated, the bootloader is updated, and no required module is lost?

    I'm especially interested in a command that would ensure that everything is done correctly, because I don't understand the peculiar boot process on this computer very well.

  • imz -- Ivan Zakharyaschev
    imz -- Ivan Zakharyaschev over 11 years
    Thanks for trying to help! Perhaps, that would work in another variant of Ubuntu, but in this Ubuntu 12.04 there's no hierarchical menu.
  • imz -- Ivan Zakharyaschev
    imz -- Ivan Zakharyaschev over 11 years
    Is "Update Manager" the preferred way to upgrade the kernel? (I have removed the package update-manager, because I was afraid it could consume resources of my computer in the background, and also I was tired of constant update notifications, and wanted to get rid of them. But if it's the way to upgrade the kernel, then I will install it back and try to carefully get rid only of the notification stuff.)
  • RDV
    RDV over 11 years
    I am using 10.04, so the menus might have changed. "Update Manager" is the only way I have tried done updates (including kernel updates) in Ubuntu. There is a Settings button in Update Manager that lets you set how often it checks for updates (though I have mine set for daily, because if there is a security vulnerability I want it patched yesterday) and you can also tell it to install security patches automatically, and to only look for "important security updates". I do still see the update manager window occasionally, but it shows up minimized.
  • imz -- Ivan Zakharyaschev
    imz -- Ivan Zakharyaschev over 11 years
    I see. I was also concerned with the kernel modules not being lost, but it seems Ubuntu doesn't have separate packages for kernel modules: ` dpkg --search /lib/modules/*` outputs only linux-image-3.0.27-1-ac100. So there is no such problem.
  • imz -- Ivan Zakharyaschev
    imz -- Ivan Zakharyaschev over 11 years
    But there are separate packages for modules listed on launchpad.net/ubuntu/+source/linux-ac100/3.0.27-1.1 and launchpad.net/ubuntu/+source/linux-ac100/3.1.10-4.5 . I do not see such separate packaging in the repositories for my Ubuntu 12.04, but perhaps the way the kernel and the modules are packaged is to be changed for Ubuntu 12.10, and there will be separate packages for modules, and my concern will be legitimate then. On the last linked page, the listed packages with modules are said to be published in universe for Ubuntu 12.10. So I guess it's not a PPA.
  • imz -- Ivan Zakharyaschev
    imz -- Ivan Zakharyaschev over 11 years
    Hmm... But there are also such modules packages published for Ubuntu 12.04: launchpad.net/ubuntu/precise/armhf/… . I can't understand what they are for and why I don't see them in APT's database...
  • Gilles 'SO- stop being evil'
    Gilles 'SO- stop being evil' over 11 years
    @imz What you link to on launchpad are PPAs, they aren't part of the Ubuntu distribution. In the Ubuntu distribution, the linux-image-VERSION packages contain the boot image and the modules. There are a few separate packages with additional modules containing non-free or experimental drivers that not everyone wants to have installed.
  • imz -- Ivan Zakharyaschev
    imz -- Ivan Zakharyaschev over 11 years
    Just for everything to be clear: No, as far as I can see, what I'm linking to is not a PPA, it's part of the Ubuntu "universe" repository. PPAs are presented diferently on this website, like here: launchpad.net/~ac100/+archive/ppa (this really a). As for how the kernel is packages in Ubuntu: yes, now I see that there is basically a single package, and the packages with modules that I have found mentioned on the website are for the "debian installer" section (and they have a "di" postfix inthe name hence) -- they are probably useful for the installer on early stages of installation.
  • imz -- Ivan Zakharyaschev
    imz -- Ivan Zakharyaschev over 11 years
    I was also concerned with the kernel modules not being lost, but it seems Ubuntu doesn't have separate packages for kernel modules: ` dpkg --search /lib/modules/*` outputs only linux-image-3.0.27-1-ac100. So there is no such problem.
  • imz -- Ivan Zakharyaschev
    imz -- Ivan Zakharyaschev over 11 years
    # apt-get install linux-image Reading package lists... Done Building dependency tree Reading state information... Done Package linux-image is a virtual package provided by: ... You should explicitly select one to install. E: Package 'linux-image' has no installation candidate
  • jordanm
    jordanm over 11 years
    @imz--IvanZakharyaschev Debian provides a meta package that will pull in the latest while leaving the older versions available, eg - linux-image-amd64.
  • imz -- Ivan Zakharyaschev
    imz -- Ivan Zakharyaschev over 11 years
    I do have linux-image-ac100 indeed. You are correct: Description-en: Linux kernel image for the ac100 architecture. This package will always depend on the latest kernel image available for ARM ac100 systems.
  • imz -- Ivan Zakharyaschev
    imz -- Ivan Zakharyaschev over 11 years
    A more precise package name (with the architecture tag) wouldn't have mislead me, as linux-image did.
  • imz -- Ivan Zakharyaschev
    imz -- Ivan Zakharyaschev about 9 years
    As for the separate packages with modules which I saw somewhere and which lead me to believe I needed to install them to: "As for how the kernel is packaged in Ubuntu: yes, now I see that there is basically a single package, and the packages with modules that I have found mentioned on the website are for the "debian installer" section (and they have a "di" postfix inthe name hence) -- they are probably useful for the installer on early stages of installation."