Ubuntu 10.04 DVD as the upgrade Source

Source: Internet
Author: User

The software in the DVD is more than the software in the CD, which is undoubtedly used as the source for upgrade. It is very important for computers that cannot access the Internet without having to access the Internet. I searched the internet for a lot of methods. Generally, I checked something in the source manager. I don't like this GUI method. In case of failure, you don't know where the problem is. in Linux, you should use the command line method that Linux is good. I also said on the Internet, using the sudo apt-CDROM add command, which I also tried and failed.

In fact, we will not be confused if we look at what the real source looks like.

Open the 163 source Directory: http://mirrors.163.com, find Ubuntu/, next to help. In help, there is a sources. list template.

Deb http://mirrors.163.com/ubuntu/ karmic main restricted universe multiverse

Deb http://mirrors.163.com/ubuntu/ karmic-security main restricted universe multiverse

Deb http://mirrors.163.com/ubuntu/ karmic-Updates main restricted universe multiverse

Deb http://mirrors.163.com/ubuntu/ karmic-proposed main restricted universe multiverse

Deb http://mirrors.163.com/ubuntu/ karmic-backports main restricted universe multiverse

Deb-Src http://mirrors.163.com/ubuntu/ karmic main restricted universe multiverse

The Deb-Src http://mirrors.163.com/ubuntu/ karmic-security main restricted universe multiverse

Deb-Src http://mirrors.163.com/ubuntu/ karmic-Updates main restricted universe multiverse

Deb-Src http://mirrors.163.com/ubuntu/ karmic-proposed main restricted universe multiverse

Deb-Src Co., http://mirrors.163.com/ubuntu/. Karmic-backports main restricted universe multiverse

This is the source of karmic (Ubuntu 9.10). What does it mean? First look at help

Man sources. List

You can find the format

Deb URI distribution [component1] [component2]...

Deb refers to the source. The corresponding Deb-Src is the source file. uri indicates the URL, distribution indicates the release version, 9.10 is karmic, and 10.04 is lucid. the following is the component of the corresponding release.

However, the above explanation only refers to the logic. What is the actual situation? You just need to check the source directory.

Open the URL mirrors.163.com/ubuntu, there are so many directories and files: dists/, indices/, pool/, Project/, ls-IR.gz.

Don't worry. Check the directory in the Ubuntu 10.04 DVD. The DVD can be mounted through a CD, or through the ISO mount. ISO mount command is

Sudo mkdir/Media/Ubuntu

Sudo Mount-o loop-T iso9660/Media/Ubuntu/yourpath/to/ubuntu-dvd-i386.iso

As you can see, there are two identical directories under the root directory of the DVD: dists/and pools /.

Then, you will naturally think that dists represents the release version. Open the dists directory, whether it is mirrors.163.com/ubuntu/distsor /media/ubuntu/dists on the Internet, there is a lucid directory below. open lucid and find the main and restricted directories. the problem is clear. The so-called release version is only a sub-directory under the dists directory, and the component is a sub-directory of the next layer. therefore

Deb http://mirrors.163.com/ubuntu/ karmic main restricted universe multiverse

This is just a few directories.

Http://mirrors.163.com/ubuntu/dists/karmic/main

Http://mirrors.163.com/ubuntu/dists/karmic/restricted

Http://mirrors.163.com/ubuntu/dists/karmic/universe

Http://mirrors.163.com/ubuntu/dists/karmic/multiverse

Then the problem is solved. Add it to/etc/APT/sources. List.

Deb file: // media/Ubuntu lucid main restricted

Deb file: // media/Ubuntu stable main restricted

Deb file: // media/Ubuntu unstable main restricted

In this case, it depends entirely on the directory structure. It indicates the following directories.

File: // media/Ubuntu/dists/lucid/main restricted

File: // media/Ubuntu/dists/lucid/restricted

File: // media/Ubuntu/dists/stable/main

File: // media/Ubuntu/dists/stable/restricted

File: // media/Ubuntu/dists/unstable/main

File: // media/Ubuntu/dists/unstable/restricted

If you cannot access the Internet, it is also possible to clear other sources. These operations are directly targeted at/etc/APT/sources. list, rather than clicking it with the mouse.

Then, update the source

Sudo apt-Get update

Next, you can install the software based on the new package manager or sudo apt-Get. Of course, you can only install the software in the DVD. The package is obviously incomplete.

In addition, there is another problem. When a DVD disc is directly attached, the update is unsuccessful. Check the source and find that it is written in this way.

Deb CDROM: [Ubuntu 10.04 lts _ lucid Lynx _-release i386 (20100429)]/lucid main restricted

It seems that it is automatically found in the optical drive, but it is not naturally found from the file. find the actual directory to which the DVD is mounted and follow the previous method. however, the problem is that the directory contains spaces, sources. the URL in the list does not seem to contain spaces. What should I do? Make a soft link.

Sudo ln-S/Media/Ubuntu/10.04/i386/Media/Ubuntu

 

 

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.