Vous n'êtes pas identifié.
Topic (non résolu) contrôlé le 13.08.2006 par calimarno.
J'ai un problème avec mon nouveau serveur dédié Debian 3.1 Sarge.
php ne fonctionne pas.
J'ai installé Apache 2 , MySQL 5, PHP5, ....
Voici un extraît de l'installation PHP5 ...
sd1222:/etc/apt# apt-get install php5 Reading Package Lists... Done Building Dependency Tree... Done The following extra packages will be installed: apache-common libapache-mod-php5 libbz2-1.0 libkrb53 libxml2 libxslt1.1 lynx php5-common ucf Suggested packages: apache apache-ssl apache-perl php5-pear libbz2-dev bzip2 krb5-doc krb5-user Recommended packages: xml-core debconf-utils The following NEW packages will be installed: apache-common libapache-mod-php5 libbz2-1.0 libkrb53 libxml2 libxslt1.1 lynx php5 php5-common ucf 0 upgraded, 10 newly installed, 0 to remove and 0 not upgraded. Need to get 6216kB of archives. After unpacking 15.8MB of additional disk space will be used. Do you want to continue? [Y/n] Y Get:1 http://packages.dotdeb.org stable/all php5-common 5.0.5-1.dotdeb.1 [83.7kB] Get:2 http://security.debian.org stable/updates/main libkrb53 1.3.6-2sarge2 [349kB] Get:3 ftp://debian.sivit.org stable/main libbz2-1.0 1.0.2-7 [38.7kB] Get:4 ftp://debian.sivit.org stable/main ucf 1.17 [36.9kB] Get:5 ftp://debian.sivit.org stable/main lynx 2.8.5-2 [1855kB] Get:6 http://packages.dotdeb.org stable/all libapache-mod-php5 5.0.5-1.dotdeb.1 [2212kB] Get:7 http://security.debian.org stable/updates/main apache-common 1.3.33-6sarge1 [845kB] Get:8 ftp://debian.sivit.org stable/main libxml2 2.6.16-7 [602kB] Get:9 ftp://debian.sivit.org stable/main libxslt1.1 1.1.12-8 [193kB] Get:10 http://packages.dotdeb.org stable/all php5 5.0.5-1.dotdeb.1 [1146B] Fetched 6216kB in 6s (967kB/s) Preconfiguring packages ... Selecting previously deselected package libbz2-1.0. (Reading database ... 17489 files and directories currently installed.) Unpacking libbz2-1.0 (from .../libbz2-1.0_1.0.2-7_i386.deb) ... Selecting previously deselected package libkrb53. Unpacking libkrb53 (from .../libkrb53_1.3.6-2sarge2_i386.deb) ... Selecting previously deselected package ucf. Unpacking ucf (from .../apt/archives/ucf_1.17_all.deb) ... Moving old data out of the way Selecting previously deselected package lynx. Unpacking lynx (from .../archives/lynx_2.8.5-2_i386.deb) ... Selecting previously deselected package apache-common. Unpacking apache-common (from .../apache-common_1.3.33-6sarge1_i386.deb) ... Selecting previously deselected package libxml2. Unpacking libxml2 (from .../libxml2_2.6.16-7_i386.deb) ... Selecting previously deselected package libxslt1.1. Unpacking libxslt1.1 (from .../libxslt1.1_1.1.12-8_i386.deb) ... Selecting previously deselected package php5-common. Unpacking php5-common (from .../php5-common_5.0.5-1.dotdeb.1_i386.deb) ... Selecting previously deselected package libapache-mod-php5. Unpacking libapache-mod-php5 (from .../libapache-mod-php5_5.0.5-1.dotdeb.1_i386.deb) ... Selecting previously deselected package php5. Unpacking php5 (from .../php5_5.0.5-1.dotdeb.1_all.deb) ... Setting up libbz2-1.0 (1.0.2-7) ... Setting up libkrb53 (1.3.6-2sarge2) ... Setting up ucf (1.17) ... Setting up lynx (2.8.5-2) ... Setting up apache-common (1.3.33-6sarge1) ... Setting up libxml2 (2.6.16-7) ... Setting up libxslt1.1 (1.1.12-8) ... Setting up php5-common (5.0.5-1.dotdeb.1) ... Setting up libapache-mod-php5 (5.0.5-1.dotdeb.1) ... Setting up php5 (5.0.5-1.dotdeb.1) ...
Le problème c'est quand j'appel mon programme de test ( test.php avec l'instruction phpinfo(); ) je reçoit la fenêtre de téléchargement au lieu des informations sur la configuration du serveur !
J'ai également essayé d'installer le paquet libapache2-mod-php5 ...
sd1222:/opt# apt-get install libapache2-mod-php5 Reading Package Lists... Done Building Dependency Tree... Done Suggested packages: php5-pear The following NEW packages will be installed: libapache2-mod-php5 0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded. Need to get 2210kB of archives. After unpacking 4706kB of additional disk space will be used. Get:1 http://packages.dotdeb.org stable/all libapache2-mod-php5 5.0.5-1.dotdeb.1 [2210kB] Fetched 2210kB in 6s (358kB/s) Selecting previously deselected package libapache2-mod-php5. (Reading database ... 22547 files and directories currently installed.) Unpacking libapache2-mod-php5 (from .../libapache2-mod-php5_5.0.5-1.dotdeb.1_i386.deb) ... Setting up libapache2-mod-php5 (5.0.5-1.dotdeb.1) ... Your apache2 configuration is broken, so we're not restarting it for you. sd1222:/opt# /etc/init.d/apache2 restart Forcing reload of web server: Apache2[Wed Oct 19 02:38:00 2005] [crit] Apache is running a threaded MPM, but your PHP Module is not compiled to be threadsafe. You need to recompile PHP. Pre-configuration failed sd1222:/opt#
mais je reçoit un message m'invitant à recompiler php5 ?
Le fait d'installer ce packet me fait planter mon serveur Apache 2. J'ai donc désinstalle le packet, pour le moment en tout cas, et le serveur Apache fonctionne de nouveau (à l'exeption de php biensur).
Comment doit je faire pour faire fonctionner php5 en cooperation avec Apache 2 et le serveur MySQL?
Doit je réinstaller le packet libapache2-mod-php5 ? Si Oui, quelles sont les instructions pour compiller le tout correctement (Apache, MySQL et PHP) ?
Merci d'avance pour votre aide.
Hors ligne
PHP5 n'est pas en stable chez Debian, et n'est même pas en testing mais bien unstable sur la SID.
Du coup si tu as un mélange d'un Apache2 trop ancien pour reconnaitre le module PHP5 alors tu as la réponse à ton problème. A moins que tu es aussi pris Apache2 sur la SID. Mais il nous faudrait plus d'informations. Et savoir si tu as fais un dist-upgrade de tout le système en unstable ou alors si tu as juste installé spécifiquement les quelques paquetages que tu voulais.
PS : ton sources.list me semble douteux :
Get:6 http://packages.dotdeb.org stable/all libapache-mod-php5 5.0.5-1.dotdeb.1 [2212kB] Get:7 http://security.debian.org stable/updates/main apache-common 1.3.33-6sarge1 [845kB]
En plus tu as chargé le vieux apache 1.3.33 tout comme le dépot dit stable ce qui est instable ?!?
Hors ligne
Salut Skywalker13,
Voila plus d'informations.
apache est la version Apache/2.0.54 (Debian GNU/Linux). Non, apache ne vien pas du même SID, c'est peut-être d'ou viens le problème?
sd1222:/# apt-get install apache2 Reading Package Lists... Done Building Dependency Tree... Done The following extra packages will be installed: apache2-common apache2-mpm-worker apache2-utils libapr0 libexpat1 libmagic1 mime-support ssl-cert Suggested packages: apache2-doc lynx www-browser file The following NEW packages will be installed: apache2 apache2-common apache2-mpm-worker apache2-utils libapr0 libexpat1 libmagic1 mime-support ssl-cert 0 upgraded, 9 newly installed, 0 to remove and 0 not upgraded. Need to get 1589kB of archives. After unpacking 6169kB of additional disk space will be used. Do you want to continue? [Y/n] Y Get:1 http://security.debian.org stable/updates/main libapr0 2.0.54-5 [131kB] Get:2 ftp://debian.sivit.org stable/main libmagic1 4.12-1 [233kB] Get:3 ftp://debian.sivit.org stable/main mime-support 3.28-1 [28.8kB] Get:4 http://security.debian.org stable/updates/main apache2-utils 2.0.54-5 [91.0kB] Get:5 http://security.debian.org stable/updates/main apache2-common 2.0.54-5 [800kB] Get:6 ftp://debian.sivit.org stable/main libexpat1 1.95.8-3 [59.6kB] Get:7 ftp://debian.sivit.org stable/main ssl-cert 1.0-11 [6904B] Get:8 http://security.debian.org stable/updates/main apache2-mpm-worker 2.0.54-5 [206kB] Get:9 http://security.debian.org stable/updates/main apache2 2.0.54-5 [33.4kB] Fetched 1589kB in 0s (6411kB/s) Preconfiguring packages ... Selecting previously deselected package libmagic1. (Reading database ... 16961 files and directories currently installed.) Unpacking libmagic1 (from .../libmagic1_4.12-1_i386.deb) ... Selecting previously deselected package mime-support. Unpacking mime-support (from .../mime-support_3.28-1_all.deb) ... Selecting previously deselected package libexpat1. Unpacking libexpat1 (from .../libexpat1_1.95.8-3_i386.deb) ... Selecting previously deselected package libapr0. Unpacking libapr0 (from .../libapr0_2.0.54-5_i386.deb) ... Selecting previously deselected package ssl-cert. Unpacking ssl-cert (from .../ssl-cert_1.0-11_all.deb) ... Selecting previously deselected package apache2-utils. Unpacking apache2-utils (from .../apache2-utils_2.0.54-5_i386.deb) ... Selecting previously deselected package apache2-common. Unpacking apache2-common (from .../apache2-common_2.0.54-5_i386.deb) ... Selecting previously deselected package apache2-mpm-worker. Unpacking apache2-mpm-worker (from .../apache2-mpm-worker_2.0.54-5_i386.deb) ...Selecting previously deselected package apache2. Unpacking apache2 (from .../apache2_2.0.54-5_i386.deb) ... Setting up libmagic1 (4.12-1) ... Setting up mime-support (3.28-1) ... Setting up libexpat1 (1.95.8-3) ... Setting up libapr0 (2.0.54-5) ... Setting up ssl-cert (1.0-11) ... Setting up apache2-utils (2.0.54-5) ... Setting up apache2-common (2.0.54-5) ... Setting Apache2 to Listen on port 80. If this is not desired, please edit /etc/apache2/ports.conf as desired. Note that the Port directive no longer works. Module userdir installed; run /etc/init.d/apache2 force-reload to enable. Setting up apache2-mpm-worker (2.0.54-5) ... Starting web server: Apache2. Setting up apache2 (2.0.54-5) ... sd1222:/#
Remarque : J'ai installé apache 2 en premier, avant php5.
Ou est l'erreur?
Hors ligne
Okay, ce que tu n'as pas dis explicitement c'est que tu utilises : http://dotdeb.org/tiki-index.php
Tu sors du contexte de stabilité de la Sarge. Du coup j'ai aucune idée de ce que valent les paquets dotdeb. Et ce problème ne m'étonne pas du tout. Veille a bien avoir que Apache2. Car dans ton premier poste il y a Apache1 puis après tu avais installé le module php5 apache2.
Quand tu seras sûr d'avoir un Apache2 propre et fonctionnel, ensuite tu peux envisager PHP5.
Hors ligne