What exactly is generic version of ubuntu ? how it differes from other versions?

Solution 1:

There are several different flavours of the kernel available, but -generic is very likely what you want.

The specialised versions are:

  • linux-image-server: tuned to respond to lots of requests rather than handle real-time interaction with a user. EDIT: This appears to have been discontinued and just points to -generic.
  • linux-image-virtual: I think this mostly just involves removing hardware drivers that are unlikely to be encountered in a virtual machine to save space.
  • linux-image-lowlatency: I think this is intended for eg, audio editing where low latency is important (see Why choose a low latency kernel over a generic or realtime one? ).

As to the folders in /usr/src, all these different kernels are actually very similar except for a few options, so most the the headers are stored in the non-specific /usr/src/linux-headers-x.y.z. The specific folder /usr/src/linux-headers-x.y.z-generic (or -server, -lowlatency) etc consists mostly of links to /usr/src/linux-headers-x.y.z, plus any files (eg .config) changed compared to the non-specific version (to avoid duplication if you have multiple flavours of the same kernel version installed).

Solution 2:

Why do I have those two linux folders in /usr

Those are the header files for the kernel(s) you have on your system. Both can be removed through apt-get (do not do it manually). (probably sudo apt-get purge linux-image-3.8.0-29)

What exactly is generic version of ubuntu ? how it differes from other versions?

"generic" means the general usage kernel. It is the kernel used for desktop installations. Before 12.04 we also had a "generic-pae ", "server" and "virtual" version next to "generic" but that distinction was removed. Nowadays we have "omap" (Kernel for TI OMAP3 and OMAP4) and "highbank" (Kernel for Calxeda Highbank).

In general the difference are optimal setttings for that specific hardware. Here is a list for several Ubuntu versions.