[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: apt-proxy einrichten



On Sun, Aug 11, 2002 at 07:43:03PM +0200, Sven Hartge wrote:

Hallo Sven!

> >> On Thu, Aug 08, 2002 at 12:11:17AM +0200, Thomas Wegner wrote:
> >> > ---------------------schnipp---------------------------
> >> > chef:/home/tommi# apt-proxy-import -d /var/cache/apt/archives 
> >> > Backend /var/cache/apt-proxy/debian/ does not have filelists - skipped
> >> > Backend /var/cache/apt-proxy/non-US/ does not have filelists - skipped
> >> > Backend /var/cache/apt-proxy/security/ does not have filelists - skipped
> >> > apt-proxy-import: No backend filelists found.
> >> > --------------------schnapp---------------------------------
> >> > Was muss ich machen? Ein apt-get update hatte ich vorher gerade
> >> > durchlaufen lassen. apt-proxy-import habe ich als root ausgeführt?
> >> 
> >> Als du 'apt-get update' durchgefuhrt hast, ging das wirklich durch
> >> apt-proxy?  Du must sources.list ändern.  Schau in /var/log/apt-proxy.log,
> >> ob apt-proxy was macht.
> 
> > Diese Datei gibt es nicht bei mir. Läuft apt-proxy als daemon? Hier
> > ist nämlich nichts in /etc/init.d.
> 
> apt-proxy (v1) läuft über inetd
> 
> > Ich sitze hier am Rechner, der eigentlich als Proxy dienen
> > soll. Diesen Rechner will ich so konfigurieren, dass er seinseits
> > Pakte aus dem Internet mittels apt-proxy abholt. Wenn ich die
> > Sources.list anpasse z. B.:
> > 
> > deb ftp://ftp.de.debian.org:9999/debian testing main contrib non-free
> 
> Nein, so läuft das nicht.
> 
> So muss das aussehen:
> 
> deb http://ds9:9999/main unstable main contrib non-free
> deb http://ds9:9999/non-US unstable/non-US main contrib non-free
> deb http://ds9:9999/apt-proxy unstable/
> deb http://ds9:9999/blackdown woody non-free
> deb http://ds9:9999/security stable/updates main contrib non-free
> deb http://ds9:9999/security testing/updates main contrib non-free
> deb-src http://ds9:9999/main unstable main contrib non-free
> deb-src http://ds9:9999/non-US unstable/non-US main contrib non-free
> deb-src http://ds9:9999/apt-proxy unstable/
> 
> Statt "ds9" wie bei mir muss dein Rechner stehen, oder "localhost", wenn
> du auf dem gleichen Rechner wie der apt-proxy bist.

So, mein Eintrag in der /etc/sources.list sieht jetzt folgendermaßen
aus:
deb ftp://localhost:9999/main woody main contrib non-free
deb ftp://localhost:9999/non-US woody/non-US main contrib non-free

Der Eintrag in /etc/apt-proxy/apt-proxy.conf sieht so aus:
add_backend /main/                                      \
        $APT_PROXY_CACHE/debian/                        \
        ftp.de.debian.org::debian/                      \
        ftp.nl.debian.org::debian/                      \
        ftp2.de.debian.org::debian/                     \
        ftp.uk.debian.org::debian/

add_backend /non-US/                                    \
        $APT_PROXY_CACHE/non-US/                        \
        ftp.de.debian.org::debian-non-US/               \
        ftp2.de.debian.org::debian-non-US/              \
        ftp.nl.debian.org::debian/non-US/

add_backend /security/                                  \
        $APT_PROXY_CACHE/security/                      \
        http://security.debian.org::debian-security/            \
        http://non-us.debian.org::debian-security/           

Nach einem apt-get udpate als root erscheint dann folgendes:
chef:/home/tommi# apt-get update
Err http://localhost woody/main Packages
  Could not connect to localhost:9999 (127.0.0.1). - connect (111 Connection refused)
Err http://localhost woody/main Release
  Could not connect to localhost:9999 (127.0.0.1). - connect (111 Connection refused)
Err http://localhost woody/contrib Packages
  Could not connect to localhost:9999 (127.0.0.1). - connect (111 Connection refused)
Err http://localhost woody/contrib Release
  Could not connect to localhost:9999 (127.0.0.1). - connect (111 Connection refused)
					...
Failed to fetch http://localhost:9999/main/dists/woody/main/binary-i386/Packages  Could not connect to localhost:9999 (127.0.0.1). - connect (111 Connection refused)
Failed to fetch http://localhost:9999/main/dists/woody/main/binary-i386/Release  Could not connect to localhost:9999 (127.0.0.1). - connect (111 Connection refused)
Failed to fetch http://localhost:9999/main/dists/woody/contrib/binary-i386/Packages  Could not connect to localhost:9999 (127.0.0.1). - connect (111 Connection refused)

                                           ...

 Reading Package Lists... Done
Building Dependency Tree... Done
W: Couldn't stat source package list http://localhost woody/main Packages (/var/lib/apt/lists/localhost:9999_main_dists_woody_main_binary-i386_Packages) - stat (2 No such file or directory)
W: Couldn't stat source package list http://localhost woody/contrib Packages (/var/lib/apt/lists/localhost:9999_main_dists_woody_contrib_binary-i386_Packages) - stat (2 No such file or directory)

OK. Das sieht nach einem Problem mit meiner Netzwerkkonfiguration
aus. Muss ich denn irgendwo den Port noch freigeben? 
In meiner /etc/hosts.deny steht:
# ALL: PARANOID Standardeinstellung
#ALL: ALL EXCEPT localhost   #nachträglich eingetragen

und in meiner /etc/hosts.allow steht für den Test:
ALL: 192.168.0.0/255.0.0.0   #nachträglich eingetragen

#Zugriffsregelung für sshd
sshd : ALL

#Zugriff wegen apt-proxy
http : ALL

Grüsse

Thomas
                  
-- 
E-Mail: thomas_wegner@gmx.net



Reply to: