zoukankan      html  css  js  c++  java
  • Ubuntu package offline install

    apt-get

    Use apt-get with the "--print-uris" option to do it. I also add "-qq" so it would be quiet.

    Create script:

    sudo apt-get <<>> --print-uris -qq | sed -n "s/'([^ ]+)' ([^ ]+) ([^ ]+) MD5Sum:([^ ]+)/wget -c 1/p" > script.cmd

    Examples

    sudo apt-get install anjuta --print-uris -qq | sed -n "s/'([^ ]+)' ([^ ]+) ([^ ]+) MD5Sum:([^ ]+)/wget -c 1/p" > install-anjuta.cmd
    sudo apt-get upgrade --print-uris -qq | sed -n "s/'([^ ]+)' ([^ ]+) ([^ ]+) MD5Sum:([^ ]+)/wget -c 1/p" > upgrade.cmd
    sudo apt-get dist-upgrade --print-uris -qq | sed -n "s/'([^ ]+)' ([^ ]+) ([^ ]+) MD5Sum:([^ ]+)/wget -c 1/p" > dist-upgrade.cmd

    Create md5sum file:

    sudo apt-get <<>> --print-uris -qq | sed -n -e "s/[0-9]%[0-9a-f][0-9a-f]//" -e "s/'([^ ]+)' ([^ ]+) ([^ ]+) MD5Sum:([^ ]+)/4 ./2/p" > md5sum.txt

    Examples:

    sudo apt-get install anjuta --print-uris -qq | sed -n -e "s/[0-9]%[0-9a-f][0-9a-f]//" -e "s/'([^ ]+)' ([^ ]+) ([^ ]+) MD5Sum:([^ ]+)/4 ./2/p" > md5sum.txt
    sudo apt-get upgrade --print-uris -qq | sed -n -e "s/[0-9]%[0-9a-f][0-9a-f]//" -e "s/'([^ ]+)' ([^ ]+) ([^ ]+) MD5Sum:([^ ]+)/4 ./2/p" > md5sum.txt
    sudo apt-get dist-upgrade --print-uris -qq | sed -n -e "s/[0-9]%[0-9a-f][0-9a-f]//" -e "s/'([^ ]+)' ([^ ]+) ([^ ]+) MD5Sum:([^ ]+)/4 ./2/p" > md5sum.txt

    Create script to download repository listings:

    sudo apt-get update --print-uris -qq | sed -n "s/'([^ ]+)' ([^ ]+) ([^ ]+) :/wget -c 1 -O 2.bz2/p" > update.cmd

    Synaptic

    In synaptic you can select the packages you want to install and under the first menu there is an option to generate a script which you can take to another machine and run there. This script will "wget" (i.e. "download") all the packages you specified that you wanted (and their dependencies) which you run on a computer that does have internet access.

    Once run you'll have all the package files needed by the disconnected computer. Carry them on a CD/USB stick and install them by sudo dpkg -i *.deb.

    Cube

    You can use Cube. It is an offline package management system which is compatible with Ubuntu, Linux Mint and other distributions that use apt-get.
    Latest Preview of Cube 1.0.8 (February 7, 2014 Release) Camicri Cube
    Cube
    Running in freshly installed Ubuntu 12.04 Ubuntu
    Running
    On Windows
    Windows

    References

    1. How can I install software or packages without Internet (offline)? answer1 answer2
    2. Camicri Cube: An Offline And Portable Package Management System
    3. Get packages and dependencies for installing offline
  • 相关阅读:
    httprunner 3.x学习12
    httprunner 3.x学习11
    PyTorch中.view()与.reshape()方法以及.resize_()方法的对比
    算术编码简介
    量化参数QP:quantization parameter 以及 HEVC
    H.265/HEVC编码结构
    H.265 视频编码中的 CTU, CU, PU, TU
    I帧、P帧、B帧、GOP、IDR 和PTS, DTS之间的关系
    视频编码 率失真性能评价指标:PSNR SSIM BD-rate BD-PSNR
    矢量量化(VQ,Vector Quantization)
  • 原文地址:https://www.cnblogs.com/nn0p/p/4334205.html
Copyright © 2011-2022 走看看