summaryrefslogtreecommitdiff
path: root/Distrib/DebianAptOffline.mdwn
blob: d2dac6b8125c21030096f774bfe83cf4aa9d1798 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
# How to Installing Packages without a Network Connection from your Hurd Installation

This procedure is based on that found in
file:///usr/share/doc/apt-doc/offline.text.gz (package apt-doc).

This requires having apt installed on the Host operating system.

Put a copy of [apt.conf.offline](http://www.bddebian.com/~wiki/Distrib/DebianAptOffline/apt.conf.offline)
into your Debian GNU/Hurd installations /etc/apt/ directory.

## If you _can_ mount your Debian GNU/Hurd partition from another OS, which can connect to the Internet

As root on the internet connected OS:

    # mount /dev/DEBIAN_GNU_HURD_PARTITON /mnt
    # cd /mnt
    # apt-get -c etc/apt/apt.conf.offline {update, upgrade, install foo, etc.}

Then , reboot into your Debian GNU/Hurd installation and as root, run:

    # apt-get {update, upgrade, install foo, etc.}

## If you _cannot_ mount your Debian GNU/Hurd partition under another OS.

From your Debian GNU/Hurd installation run, as the root user:

    # tar cf myhurdsconf.tar /etc/apt/{apt.conf.offline,sources.list} /var/lib/dpkg/status

Copy _myhurdsconf.tar_ to the remote system.

This copies your apt configuration and the status of your system
(what packages are installed, which versions, etc.)

From the remote sytem, as any user, run:

    $ mkdir myhurd
    $ cd myhurd
    $ tar -xf myhurdsconf.tar
    $ mkdir -p var/lib/apt/lists/partial var/cache/apt/archives/partial tmp
    $ apt-get -c etc/apt/apt.conf.offline {update, upgrade, install foo, etc.}
    $ tar cf myhurdsconf.tar etc/apt/{apt.conf.offline,sources.list} var/

Copy _myhurdsconf.tar_ back to your Debian GNU/Hurd system.

Finally, from your Debian GNU/Hurd installation as the root user:

    # mkdir tmp
    # cd tmp
    # tar -xf myhurdsconf.tar
    # mv var/cache/apt/archives/*.deb /var/cache/apt/archives/
    # mv var/lib/apt/lists/*_* /var/lib/apt/lists/
    # apt-get {update, upgrade, install foo, etc.}