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

--command-pipe mostly working, transcript below



==
yakko:/etc/init.d# cat /tmp/cmds 
--unpack /var/cache/apt/archives/jx-lib_1.5.3-3_i386.deb
--purge jx-lib
--unpack /var/cache/apt/archives/jx-lib_1.5.3-3_i386.deb
--configure jx-lib
--purge jx-lib
yakko:/etc/init.d# time dpkg --command-pipe 4 4</tmp/cmds
Selecting previously deselected package jx-lib.
(Reading database ... 34600 files and directories currently installed.)
Unpacking jx-lib (from .../jx-lib_1.5.3-3_i386.deb) ...
Removing jx-lib ...
Purging configuration files for jx-lib ...
Selecting previously deselected package jx-lib.
Setting up jx-lib (1.5.3-3) ...

Removing jx-lib ...
Purging configuration files for jx-lib ...

real    0m6.924s
yakko:/etc/init.d# time (cat /tmp/cmds|while read cmd;do dpkg $cmd;done)
(Reading database ... 
dpkg: serious warning: files list file for package `jx-lib' missing,
assuming package has no files currently installed.
34600 files and directories currently installed.)
Preparing to replace jx-lib 1.5.3-3 (using .../jx-lib_1.5.3-3_i386.deb) ...
Unpacking replacement jx-lib ...
(Reading database ... 34632 files and directories currently installed.)
Removing jx-lib ...
Purging configuration files for jx-lib ...
Selecting previously deselected package jx-lib.
(Reading database ... 34600 files and directories currently installed.)
Unpacking jx-lib (from .../jx-lib_1.5.3-3_i386.deb) ...
Setting up jx-lib (1.5.3-3) ...

(Reading database ... 34632 files and directories currently installed.)
Removing jx-lib ...
Purging configuration files for jx-lib ...

real    0m8.379s
==

This is on my dual celeron 333.  On slower machines it will most likely be
faster, as reading the database really hurts on low-end machines(both cpu and
memory).  Note: the 2nd method reads the database several times, which it the
main slowdown for dpkg on low-end machines.

Still left to do is a --status-pipe.  It is believed, that once this option is
done, then dpkg will properly function in daemon like mode.

----BEGIN GEEK CODE BLOCK----
Version: 3.12
GCS d- s: a-- c+++ UL++++ P+ L++++ !E W+ M o+ K- W--- !O M- !V PS--
PE++ Y+ PGP++ t* 5++ X+ tv b+ D++ G e h*! !r z?
-----END GEEK CODE BLOCK-----
----BEGIN PGP INFO----
Adam Heath <doogie@debian.org>        Finger Print | KeyID
67 01 42 93 CA 37 FB 1E    63 C9 80 1D 08 CF 84 0A | DE656B05 PGP
AD46 C888 F587 F8A3 A6DA  3261 8A2C 7DC2 8BD4 A489 | 8BD4A489 GPG
-----END PGP INFO-----



Reply to: