Re: redesigning the debian installer
Joey Hess wrote:
>
> Retrievers
> ----------
>
> Retrievers are modules that can download or otherwise retrieve
> files[1], including other modules and Packages files. It is expected that at
> least the following types will eventually be implemented:
>
> - cd retriever
> Ensures an install cd is mounted, and finds files on it. No real
> retrieving done.
> - floppy retriever
> May or may not need to deal with files split across multiple
> floppies. In any case, pulls files off floppies.
> - hard disk retriever
> Gets a file from a local hard disk (dos, linux, etc).
> - http retriever
> Downloads a file from a remote http mirror.
> - ftp retriever (needed?)
> Downloads a file from a remote ftp mirror.
> - nfs retriever
> Gets a file via nfs.
>
> A retriever must be able to do the following:
>
> - Set itself up so it can access the cdrom, mirror, or whatever.
> - Get a list of the modules that are available. This will be done by
> retrieving a standard Packages file.
> - Retrieve a file.
>
> A separate module will take care of parsing the Packages files, and
> checking md5sums of downloaded modules, and a separate program
> (udpkg) will handle actually installing modules.
>
> Since retrievers are debian packages, they can have a postinst that is
> run to set them up. During setup, they may need to prompt the user for
> information (using debconf). For example, a nfs retriever will probably
> need to prompt the user for a nfs server name. [ I'm not sure that doing
> such setup in the postinst is a good idea. ]
>
> Retrievers may also need to depend on additional modules. For example the
> http/ftp/nfs retrievers will need to depend on a module to set up networking,
> while the cdrom retriever may need to depend on module(s) that include kernel
> modules for the iso9660 filesystem and cd drivers.
>
> Retrievers may also need to interact with the user when they are retrieving
> a file. For example, the floppy retriever will need to prompt for disks.
> This interaction will also be accomplished via debconf.
>
> Retriever interface
> -------------------
>
> All retrievers should support the following interface.
>
> [ This interface is preliminary and depends on the filesystem layout and
> ramdisk allocation scheme used by the installer, and so the location may
> change. ]
>
> /usr/lib/debian-installer/retriever/<retriever name> is a executable. It
> is run with the following parameters:
>
> filename dest-directory
> Download the specified file to the specified destination
> directory[2]. The filename is the Filename field of a Packages
> file.
>
> Thus, retrieving the Packages file itself is something like this:
> program Packages /tmp/
>
> While retrieving a deb is something like this:
> program retrievers/http-retriever.deb /tmp/
>
> If the destination file already exists, the retriever may want to attempt
> to continue a download. Note that the destination file may also be a fifo
> or a named pipe.
>
> Once ran, retrievers are free to prompt the user, or do whatever else is
> necessary to retrieve the file.
>
> Note that this simple interface requires that retrievers know the location
> of the base directory of the archive. This will not be a problem for many
> -- the cdrom retriever simply uses whatever is available, in a hard-coded
> location. Other retrievers may require more configuration. For example, the
> http retriever will need to know what version of Debian is being installed,
> what site to install from, and probably what version of the debian-installer
> is being used as well. The user will likely have to be prompted for some of
> this data during retriever setup.
>
> Footnotes
> ---------
>
> [1] Conceptually, rather similar to apt's methods, although the interface
> is a lot more simplistic and we don't need to support things like
> pipelining multiple downloads.
> [2] Some retrievers may want to show progress displays while downloading.
> Support for this may need to be added to debconf, via a new data type.
> It's rather hard to do in the context of debconf -- details to be
> determined.
>
A week or so ago someone uploaded a busyboxed wget command, which is
quite small, in the apt source i see occasional reference to wget, so
this would probably be a good spot to start for http ftp retriever.
btw i havent looked a mini debconf for a number of weeks now, im
currently working in tighter integration between busybox ar, tar, gzip.
It should enable files to be extracted from a deb one at a time which
could give more control for excluding files, maybe im getting a bit
carried away with it though....
Glenn
--
To UNSUBSCRIBE, email to debian-boot-request@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
Reply to: