Ubuntu Apt-get Encounter problems

Source: Internet
Author: User

Install the software always prompt dpkg:warning:files list file for the package ' * * * * * * * * * missing, assuming packages has no files currently installed, resulting Unable to install any software, the results of Baidu +google a lot of tutorials, and finally found the solution is as follows: (Lose no credulous others can only reinstall the system to solve)   #!/bin/bashset-e # clean Out/var/cache /apt/archivesapt-get clean# Fill it with all the. Debs we needapt-get--reinstall-dy install $ (dpkg--get-selections | gr EP ' [[: Space:]]install ' | CUT-F1)  dir=$ (mktemp-d-t info-xxxxxx) for Deb in/var/cache/apt/archives/*.debdo    # Move To working directory    cd "$DIR"     # Create DEBIAN directory     mkdir-p debian    # Extract Control files    dpkg-deb-e "$deb" & nbsp;   # Extract file list, fixing up the leading./And Turning/into/.    dpkg-deb -C "$deb" | awk ' {print $NF} ' | cut-c2-| Sed-e ' s/^\/$/\/./' > debian/list    # figure out Binary package NAME &Nbsp;  deb=$ (basename "$deb" | cut-d_-f1)     # Copy each control file into Place &nbs P;  CD debian    for file in *    do         cp-a "$file"/var/lib/dpkg/info/"$DEB". " $file "    done    # clean up    cd.     RM-RF debiandonermdir "$DIR"    the principle is to re-download all installed packages, and then extract the file list from the information copied to the Info folder. (so please use when the Internet is better)

Problems with Ubuntu Apt-get

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.