Ubuntu: Difference between revisions

From miki
Jump to navigation Jump to search
Line 8: Line 8:


== Repositories ==
== Repositories ==
* [https://help.ubuntu.com/community/Repositories/Ubuntu Ubuntu Repositories]
* [https://help.ubuntu.com/community/Repositories/Ubuntu Ubuntu Repositories] — Examples for ''Lucid'' distribution:
<source lang="text">
* [https://help.ubuntu.com/community/UbuntuBackports#How%20to%20use Ubuntu Backports]
#Stable repository
deb http://be.archive.ubuntu.com/ubuntu/ lucid main restricted universe multiverse
deb-src http://be.archive.ubuntu.com/ubuntu/ lucid main restricted universe multiverse

#Distribution security updates
deb http://be.archive.ubuntu.com/ubuntu/ lucid-security main restricted universe multiverse
deb-src http://be.archive.ubuntu.com/ubuntu/ lucid-security main restricted universe multiverse

#Distribution updates
deb http://be.archive.ubuntu.com/ubuntu/ lucid-updates main restricted universe multiverse
deb-src http://be.archive.ubuntu.com/ubuntu/ lucid-updates main restricted universe multiverse

#Partner repository
deb http://archive.canonical.com/ lucid partner
deb-src http://archive.canonical.com/ lucid partner
</source>
* [https://help.ubuntu.com/community/UbuntuBackports#How%20to%20use Ubuntu Backports]<br/>Provides backports (i.e. new versions of applications from newer distribution re-packaged for the current distribution) of specific applications (like Amarok) on request.
<source lang="text">
deb http://be.archive.ubuntu.com/ubuntu/ lucid-backports main restricted universe multiverse
deb-src http://be.archive.ubuntu.com/ubuntu/ lucid-backports main restricted universe multiverse
</source>
* [https://launchpad.net/~kernel-ppa/+archive/ppa ppa:kernel-ppa/ppa]<br/>Provides kernel backport candidates before making them available in the ''updates'' or ''security'' repositories.<br/>The usual <tt>add-apt-repository</tt> does not work. Instead create file <tt>/etc/apt/sources.list.d/kernel-ppa.list</tt>:
<source lang="text">
deb http://ppa.launchpad.net/kernel-ppa/ppa/ubuntu lucid main
deb-src http://ppa.launchpad.net/kernel-ppa/ppa/ubuntu lucid main
</source>
<source lang="bash">
gpg --keyserver keyserver.ubuntu.com --recv A8267963484B044F
gpg --export A8267963484B044F | sudo apt-key add -
</source>


Other repositories:
Other repositories:

Revision as of 11:13, 25 March 2011

This page is dedicated to the Ubuntu Linux distribution or derivatives

References

Repositories

#Stable repository
deb http://be.archive.ubuntu.com/ubuntu/ lucid main restricted universe multiverse
deb-src http://be.archive.ubuntu.com/ubuntu/ lucid main restricted universe multiverse

#Distribution security updates
deb http://be.archive.ubuntu.com/ubuntu/ lucid-security main restricted universe multiverse
deb-src http://be.archive.ubuntu.com/ubuntu/ lucid-security main restricted universe multiverse

#Distribution updates
deb http://be.archive.ubuntu.com/ubuntu/ lucid-updates main restricted universe multiverse
deb-src http://be.archive.ubuntu.com/ubuntu/ lucid-updates main restricted universe multiverse

#Partner repository
deb http://archive.canonical.com/ lucid partner
deb-src http://archive.canonical.com/ lucid partner
  • Ubuntu Backports
    Provides backports (i.e. new versions of applications from newer distribution re-packaged for the current distribution) of specific applications (like Amarok) on request.
deb http://be.archive.ubuntu.com/ubuntu/ lucid-backports main restricted universe multiverse
deb-src http://be.archive.ubuntu.com/ubuntu/ lucid-backports main restricted universe multiverse
  • ppa:kernel-ppa/ppa
    Provides kernel backport candidates before making them available in the updates or security repositories.
    The usual add-apt-repository does not work. Instead create file /etc/apt/sources.list.d/kernel-ppa.list:
deb http://ppa.launchpad.net/kernel-ppa/ppa/ubuntu lucid main
deb-src http://ppa.launchpad.net/kernel-ppa/ppa/ubuntu lucid main
gpg --keyserver keyserver.ubuntu.com --recv A8267963484B044F
gpg --export A8267963484B044F | sudo apt-key add -

Other repositories:

Install

Create an USB Startup disk

  • Using Ubuntu Startup Disk Creator, one can create easily an USB startup disk (for any release, not just the same as the one used to create the startup disk)

Net boot install from Internet using GRUB

Reference: here

  • Copy files initrd.gz and linux from one of the repository below to /boot
    • Ubuntu 10.10 Maverick Meerkat amd64
    • Ubuntu 10.04 LTS Lucid Lynx amd64 or i386
    • Ubuntu 10.04 Karmic Koala amd64
    • Ubuntu 9.04 Jaunty Jackalope amd64
  • Restart, and type in GRUB command-line (press c in GRUB menu):
root (hd0,6)                         # Select partition where /boot is. Type "root (hd0," and then TAB to get a list of partitions
linux /boot/linux                    # ... or kernel /boot/linux for GRUB 1
initrd /boot/initrd.gz
boot

Net boot install from USB drive

This technique allows for very fast setup of a USB drive that can then be booted to start installation from network (Reference [1])

  • Download the image boot.img.gz
    • Ubuntu 10.10 Maverick Meerkat amd64
  • Plug in the USB, and unmount it if necessary.
  • The boot image is already pre-configured as a USB drive. Uncompress it to USB device (not partition!):
zcat boot.img.gz >/dev/sdb

Administration

Add a new Launchpad PPA repository

use add-apt-repository to add a new launchpad repository

sudo add-apt-repository ppa:kernel-ppa/ppa

Ubuntu Tweak

To install Ubuntu Tweak:

sudo add-apt-repository ppa:tualatrix/ppa
sudo apt-get update
sudo apt-get install ubuntu-tweak

Kernel

Install new kernels

There are several sources for kernel on Ubuntu:

  • The launchpad repository ppa:kernel-ppa/ppa. The usual add-apt-repository does not work. Instead create file /etc/apt/sources.list.d/kernel-ppa.list:
deb http://ppa.launchpad.net/kernel-ppa/ppa/ubuntu lucid main
deb-src http://ppa.launchpad.net/kernel-ppa/ppa/ubuntu lucid main
gpg --keyserver keyserver.ubuntu.com --recv A8267963484B044F
gpg --export A8267963484B044F | sudo apt-key add -
  • Choose manually the kernel version to install. You need to install the headers and the image, for instance:
sudo apt-get install linux-headers-2.6.32-28-generic-pae
sudo apt-get install linux-image-2.6.32-28-generic-pae

Install Maverick kernels on Lucid

There are 2 meta packages that always point to the last kernel in Maverick, so that they are automatically updated when a new kernel is released.

sudo apt-get install linux-image-generic-pae-lts-backport-maverick linux-headers-generic-pae-lts-backport-maverick

Remove old kernels

To remove old kernel entries in GRUB ([2] and [3], or other sol [4])

sudo apt-get remove --purge 2.6.28-11-*     #to remove kernel 2.6.28-11
sudo apt-get purge 2.6.28-11-*              #equivalent

An even easier solution is to install Ubuntu Tweak, and select Package CleanerClean Kernels.

Devices

To see information on all connected input devices:

cat /proc/bus/input/devices
I: Bus=0003 Vendor=0c16 Product=0002 Version=0110
N: Name="Gyration Gyration RF Technology Receiver"
P: Phys=usb-0000:00:06.1-1/input0
S: Sysfs=/devices/pci0000:00/0000:00:06.1/usb3/3-1/3-1:1.0/input/input7
U: Uniq=
H: Handlers=kbd event7 
B: EV=10001f
B: KEY=837fff 2c3027 bf004444 0 0 1 c04 a27c000 267bfa d941dfed e09effdf 1cfffff ffffffff fffffffe
B: REL=40
B: ABS=1 0
B: MSC=10

Medibuntu

To install the Medibuntu repositories (see Community or here)

sudo wget http://www.medibuntu.org/sources.list.d/$(lsb_release -cs).list --output-document=/etc/apt/sources.list.d/medibuntu.list
sudo apt-get -q update
sudo apt-get --yes -q --allow-unauthenticated install medibuntu-keyring
sudo apt-get -q update

Troubleshoot

CIFS shares not properly unmounted during shutdown

When shutting down the PC with Samba (CIFS) shares mounted, the shutdown sequence hangs with the following error messages:

CIFS VFS: server not responding
CIFS VFS: no response for cmd 50 mid xxx 

This is apparently a bug that is creeping in Ubuntu since a long time ago. Basically there are 2 possible fixes (as in [5], [6], [7]):

The one I use, proposed by Daniel Ellis here [[8]]:

sudo mv /etc/rc0.d/S31umountnfs.sh /etc/rc0.d/K31umountnfs.sh
sudo mv /etc/rc0.d/S40umountfs /etc/rc0.d/K40umountfs
sudo mv /etc/rc6.d/S31umountnfs.sh /etc/rc6.d/K31umountnfs.sh
sudo mv /etc/rc6.d/S40umountfs /etc/rc6.d/K40umountfs

Another one (not tried yet):

sudo ln -s /etc/init.d/umountnfs.sh /etc/rc0.d/K15umountnfs.sh
sudo ln -s /etc/init.d/umountnfs.sh /etc/rc6.d/K15umountnfs.sh