Simple Method for creating Ubuntu local source

Source: Internet
Author: User
The following describes the simplest way to create Ubuntu Local Source: There are two types of packages in the packs Folder: one is the. Deb package (full dependency package and software package), and the other is packages.gz, which focuses on the second type of package: this package contains the list of required software packages and dependency information. This package is generated later. Run the following command: sudodpkg-scanpackagespacks/dev/null | gzip & gt; packs/Packages. g

The following describes how to create a Ubuntu local source:
There are two types of packages in the packs Folder: one is a. Deb package (full dependency package and software package, and the other is packages.gz.

The second type of package includes the list of required software packages and dependency information.
This package is generated later. It is generated using the following command:
Sudo dpkg-scanpackages packs/dev/null | gzip> packs/Packages.gz ### packs contains the folder of all software packages. This command is executed in a directory on the pakcs folder. Packages.gz is generated in the packs folder.

1. Copy all packages in packs to the/var/cache/apt/archives/directory.
Command:
Sudo cp ~ /Packs/*. deb/var/cache/apt/archives/
Sudo chmod 777-R/var/cache/apt/archives/

2. Create such a directory under the/media directory:
Create gutsy and create packs under gutsy ### note that all files are folders
Copy packages.gz to packs and grant the permission.
Command:
Sudo mkdir/media/gutsy
Sudo mkdir/media/gutsy/packs
Sudo cp ~ /Packages.gz/media/packs/
Sudo chmod 777-R/media/gutsy/
Sudo chmod 777-R/var/cache/apt/archives/

3. After completing the above work, execute the following command:
Sudo gedit/etc/apt/sources. list
Enter the sources. list file, clear the content in the file, and fill in the following line:
Deb file: // media/gutsy packs/
After the three steps are completed, the local source is created.
Run
Sudo apt-get update
After sudo apt-get dist-upgrade, everything is normal.

Related Article

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.