Как установить PHP 5.6 на Debian 7.10? (Проблемы с установкой.)

Привет Я был следуя этому руководству

и пытался установить php 5.6 на моем Debian Wheezy (64 бита).

Я делаю это потому, что у меня на сервере стоит virtualmin и моя версия php - 5.4, а мне нужна 5.6, чтобы сделать резервную копию моего wordpress через "Duplicator", однако он требует от меня как минимум 5.6.

Я пытался установить php 5.6 вручную (btw я не смог найти пакет libdb5.3-dev ), но когда я попытался извлечь и переместить php5.6, он выдал ошибку.

Я пытался использовать wget несколько раз, и все равно всегда была одна и та же ошибка.

Вот ошибка:

root@ns3009614:/# tar -xvjpf /home/downloads/php-5.6.31.tar.gz -C /opt/build
bzip2: (stdin) is not a bzip2 file.
tar: Child returned status 2
tar: Error is not recoverable: exiting now
root@ns3009614:/# tar -xvjpf /home/downloads -C /opt/build
tar (child): /home/downloads: Cannot read: Is a directory
tar (child): At beginning of tape, quitting now
tar (child): Error is not recoverable: exiting now

bzip2: Compressed file ends unexpectedly;
        perhaps it is corrupted?  *Possible* reason follows.
bzip2: Inappropriate ioctl for device
        Input file = (stdin), output file = (stdout)

It is possible that the compressed file(s) have become corrupted.
You can use the -tvv option to test integrity of such files.

You can use the `bzip2recover' program to attempt to recover
data from undamaged sections of corrupted files.

tar: Child returned status 2
tar: Error is not recoverable: exiting now

Не могли бы вы мне помочь?

Спасибо!

0
24.08.2017, 23:49
2 ответа

У вас возникает проблема, потому что вы пытаетесь обрабатывать файл php-5.6.31.tar.gzкак сжатый файл bzip2. Хотя фактический файл представляет собой сжатый файл gzip.

Измените tar -xvjpf php-5.6.31.tar.gzна tar -xvzf php-5.6.31.tar.gz, и это должно решить вашу проблему.

1
28.01.2020, 04:41

Отредактируйте свой /etc/apt/sources.list, добавив следующие строки:

deb http://packages.dotdeb.org wheezy-php56 all
deb-src http://packages.dotdeb.org wheezy-php56 all

Получить и установить ключ GnuPG:

wget https://www.dotdeb.org/dotdeb.gpg
sudo apt-key add dotdeb.gpg

Установите PHP 5.6:

sudo apt-get update
sudo apt-get install php5

Дополнительные параметры:Инструкции на dotdeb.org

1
28.01.2020, 04:41

Теги

Похожие вопросы