Kein php5-mysqli für PHP 5.6?

testit

Well-Known Member
Hallo,

hatte bei mir unter FreeBSD 10.1 PHP 5.6 installiert.

Eine Webanwendung (Joomla) hatte dann eine Inkompatibilität bzw. das Fehlen der korrekten mysqli angemeckert.

Darauf hin habe ich mit pkg install versucht, das fehlende php5-mysqli nachzuinstallieren.
Ende der Geschichte sieht man unten: PHP 5.6 ist weg und stattdessen PHP 5.4.44 installiert worden.

Gibt es für PHP 5.6 kein passendes php5-mysqli?

Habe das Ganze mit pkg gemacht, weil es hier an anderer Stelle (glaube, es war Yamagi) empfohlen wurde.

Danke und viele Grüße
testit


Code:
pkg install php5-mysqli
Updating FreeBSD repository catalogue...
FreeBSD repository is up-to-date.
All repositories are up-to-date.
The following 2 package(s) will be affected (of 0 checked):

New packages to be INSTALLED:
  php5-mysqli: 5.4.44
  php5: 5.4.44

The process will require 15 MiB more space.
2 MiB to be downloaded.

Proceed with this action? [y/N]: y
Fetching php5-mysqli-5.4.44.txz: 100%  39 KiB  39.8kB/s  00:01
Fetching php5-5.4.44.txz: 100%  2 MiB  2.0MB/s  00:01
Checking integrity... done (2 conflicting)
Checking integrity... done (0 conflicting)
Conflicts with the existing packages have been found.
One more solver iteration is needed to resolve them.
The following 21 package(s) will be affected (of 0 checked):

Installed packages to be REMOVED:
  phpvirtualbox-4.3.2
  phpMyAdmin-4.4.14
  mod_php56-5.6.12
  php56-soap-5.6.12
  php56-xml-5.6.12
  php56-simplexml-5.6.12
  php56-session-5.6.12
  php56-ctype-5.6.12
  php56-openssl-5.6.12
  php56-mcrypt-5.6.12
  php56-filter-5.6.12
  php56-gd-5.6.12
  php56-json-5.6.12
  php56-mbstring-5.6.12
  php56-zlib-5.6.12
  php56-zip-5.6.12_1
  php56-bz2-5.6.12
  php56-5.6.12
  php56-mysqli-5.6.12

New packages to be INSTALLED:
  php5: 5.4.44
  php5-mysqli: 5.4.44

The operation will free 52 MiB.

Proceed with this action? [y/N]: y
[1/21] Deinstalling phpvirtualbox-4.3.2...
You may need to manually remove /usr/local/www/phpvirtualbox/config.php if it's no longer needed.
[1/21] Deleting files for phpvirtualbox-4.3.2: 100%
[2/21] Deinstalling phpMyAdmin-4.4.14...
[2/21] Deleting files for phpMyAdmin-4.4.14: 100%
[3/21] Deinstalling php56-soap-5.6.12...
[3/21] Deleting files for php56-soap-5.6.12: 100%
[4/21] Deinstalling mod_php56-5.6.12...
[preparing module `php5' in /usr/local/etc/apache24/httpd.conf]
[4/21] Deleting files for mod_php56-5.6.12: 100%
[5/21] Deinstalling php56-xml-5.6.12...
[5/21] Deleting files for php56-xml-5.6.12: 100%
[6/21] Deinstalling php56-simplexml-5.6.12...
[6/21] Deleting files for php56-simplexml-5.6.12: 100%
[7/21] Deinstalling php56-session-5.6.12...
[7/21] Deleting files for php56-session-5.6.12: 100%
[8/21] Deinstalling php56-ctype-5.6.12...
[8/21] Deleting files for php56-ctype-5.6.12: 100%
[9/21] Deinstalling php56-openssl-5.6.12...
[9/21] Deleting files for php56-openssl-5.6.12: 100%
[10/21] Deinstalling php56-mcrypt-5.6.12...
[10/21] Deleting files for php56-mcrypt-5.6.12: 100%
[11/21] Deinstalling php56-filter-5.6.12...
[11/21] Deleting files for php56-filter-5.6.12: 100%
[12/21] Deinstalling php56-gd-5.6.12...
[12/21] Deleting files for php56-gd-5.6.12: 100%
[13/21] Deinstalling php56-json-5.6.12...
[13/21] Deleting files for php56-json-5.6.12: 100%
[14/21] Deinstalling php56-mbstring-5.6.12...
[14/21] Deleting files for php56-mbstring-5.6.12: 100%
[15/21] Deinstalling php56-zlib-5.6.12...
[15/21] Deleting files for php56-zlib-5.6.12: 100%
[16/21] Deinstalling php56-zip-5.6.12_1...
[16/21] Deleting files for php56-zip-5.6.12_1: 100%
[17/21] Deinstalling php56-bz2-5.6.12...
[17/21] Deleting files for php56-bz2-5.6.12: 100%
[18/21] Deinstalling php56-mysqli-5.6.12...
[18/21] Deleting files for php56-mysqli-5.6.12: 100%
[19/21] Deinstalling php56-5.6.12...
[19/21] Deleting files for php56-5.6.12: 100%
[20/21] Installing php5-5.4.44...
[20/21] Extracting php5-5.4.44: 100%
[21/21] Installing php5-mysqli-5.4.44...
[21/21] Extracting php5-mysqli-5.4.44: 100%

:/usr/local/etc #
 
Schau mal, die Pakete deiner Extensions für php-5.6 haben/hatten alle das Präfix php56-.

Du hättest

$ pkg install php56-mysqli

aufrufen müssen.

EDIT: mysqli war bereits installiert, vielleicht war es nur nicht aktiviert (/usr/local/etc/php/extensions.ini).

Rob
 
Hallo Rob,

herzlichen Dank! Das war wohl der entscheidende Punkt!

Was mich wundert: Ein php -m mit dem installierten PHP 5.6 gibt mysqli als einkompiliertes Modul aus.
Daher bedarf es doch eigentlich überhaupt keiner separaten extension mehr. Wie kommt das?

Noch eine Frage:

pkg install php56-extensions installiert 19 extensions, aber bspw. NICHT php56-mysql-5.6.12

Wird überhaupt noch benötigt, wenn bereits mysqli installiert ist?

Besten Dank und viele Grüße
testit
 
$ php -m

zeigt dir auch die Module an, die dynamisch geladen werden, nicht nur die statisch einkompilierten.

Zur Extension mysql: man braucht entweder mysql, mysqli oder pdo_mysql. Ab PHP 7 ist mysql gar nicht mehr vorhanden, warscheinlich will der Paketbauer da bereits vorgreifen. Die meisten Anwendungen nutzen mysqli oder pdo_mysql.

Rob
 
Zurück
Oben