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

RE: Re: dselect/apt via non-NAT firewa



> From: Jason Gunthorpe [mailto:jgg@ualberta.ca]
> On Thu, 26 Aug 1999, Brian McGroarty wrote:
>
> > Is there something more I should have to use the potato apt
> > with 2.1?
> >
> > I installed and configured apt as below. I can fetch via
> > http proxy just fine. But immediately after fetching, apt
> > (or dselect?) returns with "/bin/sh: /bin/sh: cannot execute
> > binary file" and "E: Write error - write (32 Broken pipe)"
>
> No idea what that is, did you put something wrong in the conf
> file?

The default configuration was pretty close to what I
needed; here's what I ended up with. (I'm using the
http:// method).

Of note, entering /var/cache/apt and manually keying "dpkg
 -i *.deb" installed everything which had been downloaded. So
it seems to be fetching appropriately. Hopefully this
narrows the range of possible problems.

Also of note, this is a near virgin slink machine. All that
have been installed or configured are the default
recommended packages based on the 2.1 binary discs and
dhcpd.


cat /etc/apt/apt.config
// Options for APT in general
APT
{
  Architecture "i386";

  // Options for apt-get
  Get
  {
     Download-Only "false";
     Simulate "false";
     Assume-Yes "false";
     Force-Yes "false";             // I would never set this.
     Fix-Broken "true";
     Fix-Missing "true";
     Show-Upgraded "true";
     No-Upgrade "false";
     Print-URIs "false";
     Compile "false";
     No-Download "false";
     Purge "false";
     List-Cleanup "true";
  };

  Cache
  {
     Important "false";
  };

  CDROM
  {
     Rename "false";
     NoMount "false";
     Fast "false";
     NoAct "false";
  };

  // Some general options
  Ignore-Hold "false";
  Immediate-Configure "true";      // DO NOT turn this off, see the man page
  Force-LoopBreak "false";         // DO NOT turn this on, see the man page
};

// Options for the downloading routines
Acquire
{
  Queue-Mode "host";       // host|access
  Retries "0";

  // HTTP method configuration
  http
  {
    Proxy "http://wingate:80";;
    //Proxy::http.us.debian.org "DIRECT";  // Specific per-host setting
    Timeout "120";

    // Cache Control. Note these do not work with Squid 2.0.2
    No-Cache "false";
    Max-Age "86400";     // 1 Day age on index files
    No-Store "false";    // Prevent the cache from storing archives
  };

  ftp
  {
    Proxy "ftp://wingate/";;
    //Proxy::http.us.debian.org "DIRECT"; // Specific per-host setting

    /* Required script to perform proxy login. This example should work
       for tisfwtk */
    ProxyLogin
    {
       //"USER $(PROXY_USER)";
       //"PASS $(PROXY_PASS)";
       "USER $(SITE_USER)@$(SITE):$(SITE_PORT)";
       "PASS $(SITE_PASS)";
    };

    Timeout "120";

    /* Passive mode control, proxy, non-proxy and per-host. Pasv mode
       is prefered if possible */
    Passive "true";
    Proxy::Passive "true";
    //Passive::http.us.debian.org "true"; // Specific per-host setting
  };

  cdrom
  {
    Mount "/cdrom";

    // You need the trailing slash!
    "/cdrom/"
    {
       Mount "sleep 1000";
       UMount "sleep 500";
    }
  };
};

// Directory layout
Dir
{
  // Location of the state dir
  State "/var/state/apt/"
  {
     lists "lists/";
     xstatus "xstatus";
     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";
  };

  // Locations of binaries
  Bin {
     methods "/usr/lib/apt/methods/";
     gzip "/bin/gzip";
     dpkg "/usr/bin/dpkg";
     dpkg-source "/usr/bin/dpkg-source";
     dpkg-buildpackage "/usr/bin/dpkg-buildpackage"
     apt-get "/usr/bin/apt-get";
     apt-cache "/usr/bin/apt-cache";
  };
};

// Things that effect the APT dselect method
DSelect
{
   Clean "auto";   // always|auto|prompt|never
   Options "-f";
   UpdateOptions "";
   PromptAfterUpdate "no";
}

DPkg
{
   // Probably don't want to set this one..
   //Options {"--force-downgrade";}

   // Auto re-mounting of a readonly /usr
   Pre-Invoke {"mount -o remount,rw /usr";};
   Post-Invoke {"mount -o remount,ro /usr";};

   // Prevents daemons from getting cwd as something mountable (default)
   Run-Directory "/";

   // Build options for apt-get source --compile
   Build-Options "-b -uc";

   // Pre-configure all packages before they are installed using debconf.
   Pre-Install-Pkgs {"dpkg-preconfig --apt --priority=low
 --frontend=dialog";};
}

/* Options you can set to see some debugging text They corrispond to names
   of classes in the source code */
Debug
{
  pkgProblemResolver "true";
  pkgAcquire "false";
  pkgAcquire::Worker "false";
  pkgDPkgPM "false";

  pkgInitialize "false";   // This one will dump the configuration space
  NoLocking "false";
  Acquire::Ftp "false";    // Show ftp command traffic
  aptcdrom "false";        // Show found package files
}


Reply to: