Re: SOLVED (!) Re: dpkg-divert Was: Probleme mit slocate und apt nach vServerumzug

2006-02-21 Diskussionsfäden Gerhard Gaußling
Am Dienstag, 21. Februar 2006 11:38 schrieb Frank Küster:
> dpkg-divert listet keine Probleme, sondern korrekt divert'ete
> Dateien.
Ok, danke für die Hilfe. Dann ist das ja nun erledigt.

ciao

Gerhard



Re: SOLVED (?) Re: dpkg-divert Was: Probleme mit slocate und apt nach vServerumzug

2006-02-21 Diskussionsfäden Frank Küster
Gerhard Gaußling <[EMAIL PROTECTED]> wrote:

> # mv /etc/cron.daily/find.old /var/backups/find.old
>
> Danach funktionierte die Reinstallation. 
[...[
> dpkg-divert hat das Problem aber immer noch gelistet:
> # dpkg-divert --list
[...]
> diversion of /usr/share/man/man1/locate.1.gz 
> to /usr/share/man/man1/locate.notslocate.1.gz by slocate
> diversion of /usr/share/man/man1/updatedb.1.gz 
> to /usr/share/man/man1/updatedb.notslocate.1.gz by slocate
> diversion of /etc/cron.daily/find to /etc/cron.daily/find.notslocate by 
> slocate
>
> ???

dpkg-divert listet keine Probleme, sondern korrekt divert'ete Dateien.  

Gruß, Frank
-- 
Frank Küster
Single Molecule Spectroscopy, Protein Folding @ Inst. f. Biochemie, Univ. Zürich
Debian Developer (teTeX)



SOLVED (?) Re: dpkg-divert Was: Probleme mit slocate und apt nach vServerumzug

2006-02-20 Diskussionsfäden Gerhard Gaußling
Am Montag, 20. Februar 2006 12:57 schrieb Frank Küster:
> Gerhard Gaußling <[EMAIL PROTECTED]> wrote:
> > Hmm.. sind ja nicht so viele, aber wie bekomme ich das in den
> > Griff?
>
> Ich bin mir auch nicht sicher.  Schauen wir mal, du schriebst:
>
> pv10:/home/gerhard# apt-get install --reinstall  slocate
> [...]
> ===
> ===Error. The following diversions still exist:
> diversion of /etc/cron.daily/find to /etc/cron.daily/find.notslocate
> by slocate
> ===
> dpkg: Fehler beim Bearbeiten
> von /var/cache/apt/archives/slocate_2.7-4_i386.deb (--unpack):
>  Unterprozess pre-installation script gab den Fehlerwert 1 zur
>
> Also schau einmal in /var/lib/dpkg/info/slocate.preinst sowie in
> slocate/prerm, welche dpkg-divert-Aufrufe da drin stehen.  prerm (das
> Skript der alten Version, aber die sind hier ja gleich) wird zuerst
> aufgerufen, dann preinst.
>
> Ruf doch mal alle diese Befehle separat auf und schaue, welcher
> scheitert.
>
Ich habe es "gelöst":

Vorher hatte ich das hier (ohne eigendlich zu verstehen, was da 
passiert) gemacht:
pv10:/home/gerhard# dpkg-divert --package slocate --add --rename 
--divert /etc/cron.daily/find.notslocate  /etc/cron.daily/find
Leaving `diversion of /etc/cron.daily/find 
to /etc/cron.daily/find.notslocate by slocate'
pv10:/home/gerhard# apt-get install --reinstall  slocate 
[]
dpkg-divert: rename involves overwriting `/etc/cron.daily/find' with
  different file `/etc/cron.daily/find.notslocate', not allowed
dpkg: Fehler beim Bearbeiten 
von /var/cache/apt/archives/slocate_2.7-4_i386.deb (--unpack):
 Unterprozess pre-installation script gab den Fehlerwert 2 zur
Fehler traten auf beim Bearbeiten von:
 /var/cache/apt/archives/slocate_2.7-4_i386.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)
pv10:/home/gerhard# dpkg -i 
--force-overwrite /var/cache/apt/archives/slocate_2.7-4_i386.deb
(Lese Datenbank ... 50456 Dateien und Verzeichnisse sind derzeit 
installiert.)
Vorbereiten zum Ersetzen von slocate 2.7-4 
(durch .../slocate_2.7-4_i386.deb) ...
Removing `diversion of /etc/cron.daily/find 
to /etc/cron.daily/find.notslocate by slocate'
dpkg-divert: rename involves overwriting `/etc/cron.daily/find' with
  different file `/etc/cron.daily/find.notslocate', not allowed
[...]

Na, dann halt remove statt add:
pv10:/home/gerhard# dpkg-divert --package slocate --remove 
--divert /etc/cron.daily/find.notslocate  /etc/cron.daily/find
Removing `diversion of /etc/cron.daily/find 
to /etc/cron.daily/find.notslocate by slocate'
dpkg-divert: rename involves overwriting `/etc/cron.daily/find' with
  different file `/etc/cron.daily/find.notslocate', not allowed

ok, so bin ich zu folgende Lösung gekommen (da ich dpkg-divert nicht 
verstehe, auch nicht so recht die deutsche Erklärung im Ganten):

# mv /etc/cron.daily/find.old /var/backups/find.old

Danach funktionierte die Reinstallation. 
# apt-get install --reinstall  slocate
Paketlisten werden gelesen... Fertig
Abh￿ngigkeitsbaum wird aufgebaut... Fertig
0 aktualisiert, 0 neu installiert, 1 erneut installiert, 0 zu entfernen 
und 0 nicht aktualisiert.
Es m￿ssen noch 0B von 27,2kB Archiven geholt werden.
Nach dem Auspacken werden 0B Plattenplatz zus￿tzlich benutzt.
M￿chten Sie fortfahren [J/n]?
Reading package fields... Done
Reading package status... Done
Retrieving bug reports... Done
(Lese Datenbank ... 50456 Dateien und Verzeichnisse sind derzeit 
installiert.)
Vorbereiten zum Ersetzen von slocate 2.7-4 
(durch .../slocate_2.7-4_i386.deb) ...
Removing `diversion of /etc/cron.daily/find 
to /etc/cron.daily/find.notslocate by slocate'
Adding `diversion of /usr/bin/locate to /usr/bin/locate.notslocate by 
slocate'
Adding `diversion of /usr/bin/updatedb to /usr/bin/updatedb.notslocate 
by slocate'
Adding `diversion of /usr/share/man/man1/locate.1.gz 
to /usr/share/man/man1/locate.notslocate.1.gz by slocate'
Adding `diversion of /usr/share/man/man1/updatedb.1.gz 
to /usr/share/man/man1/updatedb.notslocate.1.gz by slocate'
Adding `diversion of /etc/cron.daily/find 
to /etc/cron.daily/find.notslocate by slocate'
Entpacke Ersatz für slocate ...
Richte slocate ein (2.7-4) ...

dpkg-divert hat das Problem aber immer noch gelistet:
# dpkg-divert --list
diversion of /usr/bin/autoconf to /usr/bin/autoconf2.50 by autoconf2.13
diversion of /usr/share/man/man1/autoconf.1.gz 
to /usr/share/man/man1/autoconf2.50.1.gz by autoconf2.13
diversion of /usr/bin/autoheader to /usr/bin/autoheader2.50 by 
autoconf2.13
diversion of /usr/share/man/man1/autoheader.1.gz 
to /usr/share/man/man1/autoheader2.50.1.gz by autoconf2.13
diversion of /usr/bin/autoreconf to /usr/bin/autoreconf2.50 by 
autoconf2.13
diversion of /usr/share/man/man1/autoreconf.1.gz 
to /usr/share/man/man1/autoreconf2.50.1.gz by autoconf2.13
diversion of /usr/bin/locate to /usr/bin/locate.notslocate by slocate
diversion of /usr/bin/updatedb to /usr/bin/updatedb.notslocate by 
slocate
diversion of /us