II. apt-get (尚有多种工具,如apt-cdrom apt-setup apt-key ...常用的就这两个)
III. APT configure file /etc/apt/apt.conf
IV. source list /etc/apt/source.list
V. Packages pool directory /var/cache/apt/archives/ `----partial/
VI. Local index files from source server /var/lib/apt/lists/ |----192.168.10.252_debian_dists_unstable_Release |-----192.168.10.252_debian_dists_unstable_Release.gpg |-----192.168.10.252_debian_dists_unstable_contrib_binary-i386_Packages |-----192.168.10.252_debian_dists_unstable_main_binary-i386_Packages |-----lock `-----partial/
VII. 安装于系统的软件包的信息记录文件,很重要!可在依赖关系不满足时修改之,让其暂时通过:) /var/lib/dpkg/status
B. 有用的配置选项
// From /usr/share/doc/apt/examples/configure-index Note: These are APT system default value
Dir "/" { // Location of the state dir ----------------->Dir::State=/var/lib/apt/ State "var/lib/apt/" { Lists "lists/"; ----------->-o Dir::State::Lists="/tmp/lists/" => /tmp/lists/ xstatus "xstatus"; -o Dir::State::Lists="fuck/" => /var/lib/apt/fuck/ userstatus "status.user"; status "/var/lib/dpkg/status"; cdroms "cdroms.list"; };
// Location of the cache dir Cache "var/cache/apt/" { Archives "archives/"; srcpkgcache "srcpkgcache.bin"; pkgcache "pkgcache.bin"; };
// Config files Etc "etc/apt/" { SourceList "sources.list"; Main "apt.conf"; Preferences "preferences"; Parts "apt.conf.d/"; };
4.1 建立 apt.conf ,置于pool目录下 apt.conf must contain the necessary information to make APT use the pool: APT { /* This is not necessary if the two machines are the same arch, it tells the remote APT what architecture the Debian machine is */ Architecture "i386";
Get::Download-Only "true"; };
Dir { /* Use the disc for state information and redirect the status file from the /var/lib/dpkg default */ State "/tmp/pool/"; State::status "status";
// Binary caches will be stored locally Cache::archives "/tmp/pool/archives/"; Cache "/tmp/";
// Location of the source list. Etc "/tmp/pool/"; };