Problem: Auf Ihrem Server funktionieren tar, gzip und bzip2 ordnungsgemäß. Sie erhalten jedoch „CPAN.pm benötigt entweder die externen Programme tar, gzip und bzip2 installiert. Kann nicht fortfahren. ” Fehlermeldung beim Installieren eines Perl-Moduls mit cpan. Dieser Artikel erklärt, wie Sie dieses Problem lösen können.
Bitte lesen Sie auch unseren vorherigen Artikel zur Installation von Perl-Modulen mit der manuellen und der cpan-Methode.
Lösung:
Der Fehler tritt auf, weil CPAN den Speicherort der tar-, bzip2- und gzip-Datei nicht kennt. Konfigurieren Sie diese Standorte wie unten gezeigt.
# perl -MCPAN -eshell cpan shell -- CPAN exploration and modules installation (v1.9205) ReadLine support available (maybe install Bundle::CPAN or Bundle::CPANxxl?) cpan[1]> o conf tar /bin/tar tar [/bin/tar] Please use 'o conf commit' to make the config permanent! cpan[2]> o conf bzip2 /bin/bzip2 bzip2 [/bin/bzip2] Please use 'o conf commit' to make the config permanent! cpan[3]> o conf gzip /bin/gzip gzip [/bin/gzip] Please use 'o conf commit' to make the config permanent! cpan[4]> o conf commit commit: wrote '/usr/lib/perl5/5.10.0/CPAN/Config.pm' cpan[5]> quit No history written (no histfile specified). Lockfile removed.
Stellen Sie sicher, dass Sie einen Commit durchführen, um die Konfigurationsänderungen wie oben gezeigt zu speichern.