Hi,
I promised Lior Kaplan and answer about the way I install packages on a debian
machine that is not connected to the internet.
But first: he and Oded Arbel were right in their answer about my path problem.
I have still to find out when and where is Debian different from the
distributions I used before.
Basically, I use the procedure presented by Jason Gunthorpe <[EMAIL PROTECTED]>,
in the file /usr/share/doc/apt/offline.text.gz of the distribution ( I guess
one can find that on the line as well). The method is best suited for use
with a zip drive or a disk-on-key device. As I have neither, I modified it
slightly.
In my case, there are three machines: a debian machine unconnected to the net
at home, UD, a debian machine connected to the net at work, CD, and a windows
machine connected to the net at home, CW. In the two debian machines, I built
the following structure:
/home/avraham/apt_get/
archives/
partial/
lists/
partial/
status
sources.list
apt.conf
The file apt.conf:
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 debian_get directory for state information and redirect the status
file from
the /var/lib/dpkg default */
State "/home/avraham/debian_get/";
State::status "status";
/* Binary caches will be stored locally */
Cache::archives "/home/avraham/debian_get/archives/";
Cache "/tmp/";
/* Location of the source list. */
Etc "/home/avraham/debian_get/";
};
The command: # export APT_CONFIG="/home/avraham/debian_get/apt.conf"
is required to instruct the UD and CD machines to use this file and not the
default. It is worth checking with echo $APT_CONFIG.
At the end of the process it is to be cancelled by APT_CONFIG=. Check
again to avoid nasy surprises.
On both debian machines, the status file is an uptodate copy of the
UD-/var/lib/dpkg/status file.
On both debian machines, the sources.list is an uptodate copy of the
CD-/etc/apt/sources.list file.
The directory "lists" is populated by the command apt-get update on CD. Copy
it to the corresponding directory on UD.
(if after apt-get update, the lists directory remains empty, this is a sure
sign that the system used the default configuration, either because one
has not told it to do otherwise or because of some typo in apt.conf)
The lists/partial, archives and archives/partial directories are empty at
this stage.
Assume now, for example, that I wish to install the package wajig. I can
find out exactly what packages and versions are necessary by running: aptget
-s -u install wajig in either of the debian machines.
In the CD i can obtain the files by aptget -d install wajig. The wajig
package and, in my case one additional required package are stored in the
archives directory. I transfer them to the corresponding directory in UD.
Alternately I can download the packages with the CW machine and transfer
them to the archives directories of the UD.
On UD I issue then the command:
apt-get --no-d -o dir::etc::status=/var/lib/dpkg/status install wajig
Which installs wajig and updates the /var/lib/dpkg/status file (but not the
debian_get/status file on either computer, whence the need to update it
before any new use of the process)
This last command, slightly different from the one given by Gunthorpe, is
from Frank Ronnenburg's DebianGNU/Linux Anwenderhandbuch, in German. I simply
came across it before reading Gunthorpe's file and checked this
command. It seems to work all right. I prefered to refer to Gunthyorpe's
paper because the number of English reading people in this list probably far
outweights that of those who can read German.
If I guess correctly, Gunthorpe's version updates the wrong status file, but,
as I already had a working procedure, I did not check. You know: "If ain't
broken, do not mend it" (I am sure the owner of the list will be able to quote
similar proverbs in other languages...).
That was terribly long. I certainly forgot a lot of points. But I tried to
use yanking and mouse cut-and-paste wherever possible to avoid introducing
mistakes when quoting commands.
May that be of use to someone. Good luck, Avraham
~
=================================================================
To unsubscribe, send mail to [EMAIL PROTECTED] with
the word "unsubscribe" in the message body, e.g., run the command
echo unsubscribe | mail [EMAIL PROTECTED]