File: apt-setup.html.in

package info (click to toggle)
debian-cd 2.2.13
  • links: PTS
  • area: main
  • in suites: woody
  • size: 1,480 kB
  • ctags: 120
  • sloc: sh: 1,666; perl: 1,078; makefile: 832
file content (256 lines) | stat: -rw-r--r-- 6,496 bytes parent folder | download | duplicates (3)
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
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256

First of all, comment out every line of <tt>/etc/apt/sources.list</tt> by
placing a hash sign (`<tt>#</tt>') in front of it (if it isn't already
there). 

<P>

Then you need to add new "<tt>deb</tt>" lines describing the location(s)
where apt will get the new packages from. You can add "<tt>deb</tt>" lines
for a packages mirror on a local harddisk, and/or FTP/HTTP mirrors, and/or
(a set of)  CD-ROMs. `Apt' will consider all packages that can be found
via any "<tt>deb</tt>" line, and use the one with the highest version
number, giving priority to the first mentioned lines. (So, in case of
multiple mirror locations, you'd typically first name a local harddisk,
then CD-ROMs, and finally FTP/HTTP mirrors.) 

<P>
<UL>
<LI>
For an archive on a local harddisk, that for example has these directories,

#if OUTPUTtext
<PRE>

         /var/ftp/debian/dists/potato/main/binary-ARCH/...
         /var/ftp/debian/dists/potato/contrib/binary-ARCH/...
         ---------------       ------     |\ 
               \________          \_      | \___
       add:             \           \     |     \ 
                  --------------- ------  |      \ 
         deb file:/var/ftp/debian potato main contrib

</PRE>
#endif
#if OUTPUThtml
<PRE>
  /var/ftp/debian/dists/potato/main/binary-ARCH/...
  /var/ftp/debian/dists/potato/contrib/binary-ARCH/...
  ---------------       ------     |\ 
        \________          \_      | \___
add:             \           \     |     \ 
           --------------- ------  |      \ 
  deb file:/var/ftp/debian potato main contrib
</PRE>
#endif

  As shown, the `<tt>dists</tt>' is added implicitly, and the 3rd
  and following arguments are used to expand the path into multiple
  directories.

<BR>&nbsp;<BR>

  If you have a complete mirror that also has non-free and non-US, you
  typically have to add lines like these:

<BR>&nbsp;<BR>

<tt>&nbsp;
    deb file:/var/ftp/debian potato main contrib non-free <BR>
&nbsp;
    deb file:/var/ftp/debian-non-US potato/non-US main contrib non-free
</tt>

<BR>&nbsp;<BR>

  If you don't have such a structure, other description lines  are
  possible, see the <tt>sources.list</tt>
#if MANPAGEseebelow
  manpage (see below).
#else
  manpage.
#endif

</LI>
<BR>&nbsp;<BR>
<LI>

FTP and HTTP packages mirror addresses can be found on

#if CDROMreadme
#if OUTPUTtext
this CD in README.mirrors.txt, or on
#endif
#if OUTPUThtml
this CD in <a href="README.mirrors.html">README.mirrors.html</a>, or on
#endif
#endif

#if OUTPUTtext
  http://www.debian.org/distrib/ftplist,
#endif
#if OUTPUThtml
  <a href="http://www.debian.org/distrib/ftplist">http://www.debian.org/distrib/ftplist</a>,
#endif
  look at the "Full list of mirrors".

<BR>&nbsp;<BR>

  If the mirror has these directories:

#if OUTPUTtext
<PRE>

         ftp://some-server/debian/dists/potato/main/binary-ARCH/...
         ftp://some-server/debian/dists/potato/contrib/binary-ARCH/...
         ------------------------       ------ |   |
                     \___                 /    |   |
       add:              \               /     |   |
             ------------------------ ------   |   |
         deb ftp://some-server/debian potato main contrib

</PRE>
#endif
#if OUTPUThtml
<PRE>
  ftp://some-server/debian/dists/potato/main/binary-ARCH/...
  ftp://some-server/debian/dists/potato/contrib/binary-ARCH/...
  ------------------------       ------ |   |
              \___                 /    |   |
add:              \               /     |   |
      ------------------------ ------   |   |
  deb ftp://some-server/debian potato main contrib
</PRE>
#endif

  As shown, the `<tt>dists</tt>' is added implicitly, and the 3rd
  and following arguments are used to expand the path into multiple
  directories.

<BR>&nbsp;<BR>

  If you use a complete mirror that also has non-free and non-US, you
  typically have to add lines like these:

<BR>&nbsp;<BR>

<tt>&nbsp;
    deb ftp://some-server/debian potato main contrib non-free <BR>
&nbsp;
    deb ftp://some-server/debian-non-US potato/non-US main contrib non-free
</tt>

<BR>&nbsp;<BR>

  If the mirror doesn't have such a structure, other description lines are
  possible, see the <tt>sources.list</tt>
#if MANPAGEseebelow
  manpage (see below).
#else
  manpage.
#endif

#if UPGRADING
<BR>&nbsp;<BR>

  NOTE: if you're using the static versions of `apt' and `dpkg' from this
  directory, the hostname-lookup is "broken" (which is one reason to just
  use slink's `apt'). The solution is to simply put the mirrors' IP address
  in the "<tt>deb</tt>" line. (Hint: "<tt>nslookup some-server</tt>")
#endif

</LI>
<BR>&nbsp;<BR>
<LI>

If you use (one or more) CD-ROMs, do _not_ add any lines to sources.list
  manually.

<BR>&nbsp;<BR>

  Instead, first make sure there is a line in <tt>/etc/fstab</tt> that
  connects the <tt>/cdrom</tt> mount point with your CD-ROM drive (the
  exact `<tt>/cdrom</tt>' mount point is "required" for apt). For example,
  if
#if ARCHi386
<tt>/dev/hdc</tt>
#else
<tt>/dev/scd0</tt>
#endif
  is your CD-ROM drive, <tt>/etc/fstab</tt> should
  contain a line

#if ARCHi386
#if OUTPUTtext
<PRE>

         /dev/hdc      /cdrom     auto    defaults,noauto,ro     0   0

</PRE>
#endif
#if OUTPUThtml
<PRE>
  /dev/hdc      /cdrom     auto    defaults,noauto,ro     0   0
</PRE>
#endif
#else
#if OUTPUTtext
<PRE>

         /dev/scd0     /cdrom     auto    defaults,noauto,ro     0   0

</PRE>
#endif
#if OUTPUThtml
<PRE>
  /dev/scd0     /cdrom     auto    defaults,noauto,ro     0   0
</PRE>
#endif
#endif

  To test this, insert a CD-ROM and give commands

<BR>&nbsp;<BR>

    <tt>&nbsp; mount /cdrom</tt><BR>
    <tt>&nbsp; ls -alF /cdrom &nbsp;&nbsp;&nbsp;</tt>
                            (this should show the CD-ROM's root directory)<BR>
    <tt>&nbsp; umount /cdrom</tt>

<BR>&nbsp;<BR>

  Then, use the command

<BR>&nbsp;<BR>

<tt>&nbsp;
    apt-cdrom add
</tt>

<BR>&nbsp;<BR>

  to add the data of each CD-ROM to apt's internal database.
  This command will ask for one CD-ROM per run, and mount/unmount the
  CD-ROM automatically. You should repeat this command for all 2.2 `Binary'
  CD-ROMs you have.

#if UPGRADING
(`Source' CD-ROMs can be added as well, but only with the
  latest version of `apt' from this directory, and they are not needed for
  the upgrade anyway.)
#endif

</LI>
</UL>
<P>

When the <tt>sources.list</tt> is correct,
the final step of the preparation is to update apt's internal database
with the command

<P>

<tt>&nbsp;
  apt-get update
</tt>