2012-08-09 3 views
0

je redémarrer mon serveur apache par cette commande "restart service httpd" et faire passer le message suivant:Apache httpd restart n'a pas

arrêthttpd: [ECHEC] httpd A partir: [OK]

Avant que le problème n'arrive, ce que j'ai fait est simplement de remplacer un ancien fichier de base de données par un nouveau. Ce fichier de base de données sera utilisé par un autre fichier php. Quand j'ai fait le remplacement, je n'ai pas arrêté httpd. Après avoir échoué à redémarrer le serveur Apache, j'ai navigué sur le Web pour trouver une solution et j'ai essayé les méthodes suivantes.

1) Essayez ceci "netstat -lnp | grep httpd" et "lsof -i: 80" pour trouver s'il y a un port de liaison de processus 80. Le résultat est aucun processus.

2) Retirez subsys verrouillé par cette "rm -f/var/lock/subsys/httpd" et redémarrer httpd à nouveau, mais le résultat est le même que le message ci-dessus:

Stopping httpd:           [FAILED] 
Starting httpd:           [ OK ] 

3) Il ne semble pas fonctionner même si je redémarre le serveur

Comment faire pour résoudre ce problème?

Le error_log affiche le message suivant:

[Thu Aug 09 15:10:34 2012] [notice] suEXEC mechanism enabled (wrapper: /usr/sbin/suexec) [Thu Aug 09 15:10:34 2012] [info] Init: Seeding PRNG with 256 bytes of entropy [Thu Aug 09 15:10:34 2012] [info] Init: Generating temporary RSA private keys (512/1024 bits) [Thu Aug 09 15:10:34 2012] [info] Init: Generating temporary DH parameters (512/1024 bits) [Thu Aug 09 15:10:34 2012] [info] Init: Initializing (virtual) servers for SSL [Thu Aug 09 15:10:34 2012] [info] Server: Apache/2.2.3, Interface: mod_ssl/2.2.3, Library: OpenSSL/0.9.8e-fips-rhel5 [Thu Aug 09 15:10:34 2012] [notice] Digest: generating secret for digest authentication ... [Thu Aug 09 15:10:34 2012] [notice] Digest: done [Thu Aug 09 15:10:34 2012] [debug] util_ldap.c(2052): LDAP merging Shared Cache conf: shm=0x8541df0 rmm=0x8541e20 for VHOST: localhost.localdomain [Thu Aug 09 15:10:34 2012] [info] APR LDAP: Built with OpenLDAP LDAP SDK [Thu Aug 09 15:10:34 2012] [info] LDAP: SSL support available [Thu Aug 09 15:27:26 2012] [notice] suEXEC mechanism enabled (wrapper: /usr/sbin/suexec) [Thu Aug 09 15:27:26 2012] [info] Init: Seeding PRNG with 256 bytes of entropy [Thu Aug 09 15:27:26 2012] [info] Init: Generating temporary RSA private keys (512/1024 bits) [Thu Aug 09 15:27:26 2012] [info] Init: Generating temporary DH parameters (512/1024 bits) [Thu Aug 09 15:27:26 2012] [info] Init: Initializing (virtual) servers for SSL [Thu Aug 09 15:27:26 2012] [info] Server: Apache/2.2.3, Interface: mod_ssl/2.2.3, Library: OpenSSL/0.9.8e-fips-rhel5 [Thu Aug 09 15:27:26 2012] [notice] Digest: generating secret for digest authentication ... [Thu Aug 09 15:27:26 2012] [notice] Digest: done [Thu Aug 09 15:27:26 2012] [debug] util_ldap.c(2052): LDAP merging Shared Cache conf: shm=0x97f4df0 rmm=0x97f4e20 for VHOST: localhost.localdomain [Thu Aug 09 15:27:26 2012] [info] APR LDAP: Built with OpenLDAP LDAP SDK [Thu Aug 09 15:27:26 2012] [info] LDAP: SSL support available ssl_error_log: [Thu Aug 09 15:10:34 2012] [notice] suEXEC mechanism enabled (wrapper: /usr/sbin/suexec) [Thu Aug 09 15:10:34 2012] [info] Init: Seeding PRNG with 256 bytes of entropy [Thu Aug 09 15:10:34 2012] [info] Init: Generating temporary RSA private keys (512/1024 bits) [Thu Aug 09 15:10:34 2012] [info] Init: Generating temporary DH parameters (512/1024 bits) [Thu Aug 09 15:10:34 2012] [info] Init: Initializing (virtual) servers for SSL [Thu Aug 09 15:10:34 2012] [info] Server: Apache/2.2.3, Interface: mod_ssl/2.2.3, Library: OpenSSL/0.9.8e-fips-rhel5 [Thu Aug 09 15:10:34 2012] [notice] Digest: generating secret for digest authentication ... [Thu Aug 09 15:10:34 2012] [notice] Digest: done [Thu Aug 09 15:10:34 2012] [debug] util_ldap.c(2052): LDAP merging Shared Cache conf: shm=0x8541df0 rmm=0x8541e20 for VHOST: localhost.localdomain [Thu Aug 09 15:10:34 2012] [info] APR LDAP: Built with OpenLDAP LDAP SDK [Thu Aug 09 15:10:34 2012] [info] LDAP: SSL support available [Thu Aug 09 15:27:26 2012] [notice] suEXEC mechanism enabled (wrapper: /usr/sbin/suexec) [Thu Aug 09 15:27:26 2012] [info] Init: Seeding PRNG with 256 bytes of entropy [Thu Aug 09 15:27:26 2012] [info] Init: Generating temporary RSA private keys (512/1024 bits) [Thu Aug 09 15:27:26 2012] [info] Init: Generating temporary DH parameters (512/1024 bits) [Thu Aug 09 15:27:26 2012] [info] Init: Initializing (virtual) servers for SSL [Thu Aug 09 15:27:26 2012] [info] Server: Apache/2.2.3, Interface: mod_ssl/2.2.3, Library: OpenSSL/0.9.8e-fips-rhel5 [Thu Aug 09 15:27:26 2012] [notice] Digest: generating secret for digest authentication ... [Thu Aug 09 15:27:26 2012] [notice] Digest: done [Thu Aug 09 15:27:26 2012] [debug] util_ldap.c(2052): LDAP merging Shared Cache conf: shm=0x97f4df0 rmm=0x97f4e20 for VHOST: localhost.localdomain [Thu Aug 09 15:27:26 2012] [info] APR LDAP: Built with OpenLDAP LDAP SDK [Thu Aug 09 15:27:26 2012] [info] LDAP: SSL support available Merci pour toute aide!

+0

vous avez la première base de données de mise à jour en utilisant 'commande de mise à jour', puis redémarrez le serveur apache. – Sandy8086

+0

Les journaux ne montrent aucune erreur (ou quelque chose en rapport avec votre problème). Quel type de fichier de base de données est-il? '.sql'? –

+0

Essayez '' \ etc \ init.d \ apache2 stop' puis 'pkill -9 apache2' et démarrez. Juste pour informations. –

Répondre

1

Pouvez-vous activer DebugLevel Debug dans le fichier httpd.conf et essayez de démarrer le service. Vous devriez alors pouvoir obtenir plus de détails dans les journaux d'erreurs. D'ailleurs, vous semblez avoir activé le SSL, donc ce ne sera probablement pas le port 80 mais le port 443. Si c'est un problème avec SSL, vous pouvez probablement désactiver SSL et simplement activer http et vérifier le démarrage d'Apache. Vous êtes également configuré pour communiquer avec n'importe quel serveur LDAP pour l'authentification.

+0

J'ai défini LogLevel en tant que débogage. Vous pouvez trouver quelques "débogage" entre crochets dans les messages du journal ci-dessus. J'ai également vérifié le numéro de port 443, mais aucun processus trouvé pour écouter ce port. Quand j'ai essayé toutes les méthodes possibles pour redémarrer httpd et que je l'ai vérifié en utilisant "service httpd status", il m'a juste dit "httpd dead mais subsys locked". –

0

faisait face au même problème, mais

sudo /etc/init.d/apache2 reload 

fonctionne très bien pour moi

0

Pour moi, cela a fonctionné sur RH Linux:

d'abord activer le mode super utilisateur:

sudo su - 

Maintenant, allez à l'emplacement Apache (httpd) dans le terminal: cd /usr/sbin

To start Apache server:    httpd -k start 
To stop Apache server:    httpd -k stop 
Check if httpd service is running: pgrep httpd 

Espérons que ça aide quelqu'un.