Téléchargement
illégal
Posez votre question Signaler

Test installation Apache : problèmes ! [Résolu]

bob031 7903Messages postés 7 août 2004Date d'inscription 25 avril 2012Dernière intervention - Dernière réponse le 20 août 2011 à 10:28
Bonjour,
Je viens d'installer Apache (httpd.2.2.4) !
L'installation basique s'est bien déroulée : lorsque je tape http://localhost/ dans mon navigateur : j'obtiens une page avec "It works" (je suppose que cela fonctionne !)
Mon problème :
j'ai modifié dans le fichier httpd.conf de telle manière :
User nobody
Group nobody
et là losque je tape la commande :
./bin/apachectl -k [stop start restart ou graceful] j'ai la réponse :
httpd: bad group name nobody
Autre question : il semble que les processus ne se terminent pas :
[root@localhost apache2]# ./bin/apachectl -k restart
httpd: bad group name nobody
[root@localhost apache2]# ps aux | grep apache
root 7353 0.0 0.1 3480 1572 ? Ss 12:02 0:00 /usr/local/apache2/bin/httpd -k graceful
toto 7363 0.0 0.1 3768 1664 ? S 12:03 0:00 /usr/local/apache2/bin/httpd -k graceful
toto 7364 0.0 0.1 3768 1708 ? S 12:03 0:00 /usr/local/apache2/bin/httpd -k graceful
toto 7365 0.0 0.1 3768 1708 ? S 12:03 0:00 /usr/local/apache2/bin/httpd -k graceful
toto 7366 0.0 0.1 3768 1676 ? S 12:03 0:00 /usr/local/apache2/bin/httpd -k graceful
toto 7367 0.0 0.1 3768 1308 ? S 12:03 0:00 /usr/local/apache2/bin/httpd -k graceful
toto 7453 0.0 0.1 3768 1308 ? S 12:13 0:00 /usr/local/apache2/bin/httpd -k graceful
root 7577 0.0 0.0 2964 752 pts/0 R+ 12:34 0:00 grep --color apache
[root@localhost apache2]# ./bin/apachectl -k stop
httpd: bad group name nobody
[root@localhost apache2]# ps aux | grep apache
root 7353 0.0 0.1 3480 1572 ? Ss 12:02 0:00 /usr/local/apache2/bin/httpd -k graceful
toto 7363 0.0 0.1 3768 1664 ? S 12:03 0:00 /usr/local/apache2/bin/httpd -k graceful
toto 7364 0.0 0.1 3768 1708 ? S 12:03 0:00 /usr/local/apache2/bin/httpd -k graceful
toto 7365 0.0 0.1 3768 1708 ? S 12:03 0:00 /usr/local/apache2/bin/httpd -k graceful
toto 7366 0.0 0.1 3768 1676 ? S 12:03 0:00 /usr/local/apache2/bin/httpd -k graceful
toto 7367 0.0 0.1 3768 1308 ? S 12:03 0:00 /usr/local/apache2/bin/httpd -k graceful
toto 7453 0.0 0.1 3768 1308 ? S 12:13 0:00 /usr/local/apache2/bin/httpd -k graceful
root 7582 0.0 0.0 2960 764 pts/0 S+ 12:35 0:00 grep --color apache
D'avance merci !
bob
Lire la suite 

Test installation Apache : problèmes »

20 réponses
Réponse
+8
moins plus
Mets par exemple
ServerName 127.0.0.1
Si la commande
debian:/home/lami20j# grep localhost /etc/hosts
127.0.0.1       localhost.localdomain   localhost
te donne un résultat semblable tu peux aussi écrire
ServerName localhost
lami20j- 8 févr. 2007 à 18:40
de rien :-))
teuf - 25 avril 2008 à 09:55
C`etait super comme aide et en plus tres simplement explique.gr0s bravo
nico - 30 avril 2010 à 22:04
Bonjour voila moi mon problème est que quand je fait démaré j'ai 2 fenetre qui s'affiche tout le temps et reste comme sa on ma dit de redémarer mes rien a fair que fair svp ???
Ajouter un commentaire
Réponse
+2
moins plus
moi j'ai un problème avec XAMPP avec apache je clic sur démarer et ça s'enleve 1 seconde je tappe dans le barre d'adresse localhost et ça fonctionne pas aider moi !! j'aurais beacoup besoin d'aide voici mon adresse pour me parler kev_le_bo@hotmail.com
Ajouter un commentaire
Réponse
+1
moins plus
Salut,

kill -9 7353
pour arrêter httpd

httpd: bad group name nobody

regarde dans /etc/group pour voir si tu as ce groupe
tape cette commande
grep nobody /etc/group || echo "*** group nobody n'existe pas! ***"

bob031- 8 févr. 2007 à 13:27
Salut et merci pour ta réponse !

Voci la réponse à ta commande :
[root@localhost Desktop]# grep nobody /etc/group || echo "*** group nobody n'existe pas! ***"
*** group nobody n'existe pas! ***

Je m'en doutais un petit peu ! Je suppose qu'il y a moyen de régler ceci en créant le user et le group nobody ? Sais tu; stp, comment s'y prendre ?

Merci

bob
Ajouter un commentaire
Réponse
+1
moins plus
Voilà ce que j'ai dans mon httpd.conf

 User webuser
 Group webgroup


et dans /etc/passwd et /etc/group
debian:/home/lami20j# grep web /etc/{passwd,group}
/etc/passwd:webuser:x:50005:50005::/home/webuser:/bin/false
/etc/group:webgroup:x:50005:
et le daemon httpd
lami20j@debian:~$ ps aux | grep httpd
root      3150  0.0  0.2  14248   564 ?        Ss   09:49   0:00 /usr/local/httpd/bin/httpd -k start
webuser   3157  0.0  0.3  19152   800 ?        S    09:49   0:00 /usr/local/httpd/bin/httpd -k start
webuser   3158  0.0  0.3  19152   800 ?        S    09:49   0:01 /usr/local/httpd/bin/httpd -k start
webuser   3159  0.0  0.3  19036   796 ?        S    09:49   0:00 /usr/local/httpd/bin/httpd -k start
webuser   3160  0.0  0.3  19020   796 ?        S    09:49   0:00 /usr/local/httpd/bin/httpd -k start
webuser   3161  0.0  0.3  18728   820 ?        S    09:49   0:01 /usr/local/httpd/bin/httpd -k start
webuser   9547  0.0  0.3  18420   796 ?        S    10:28   0:00 /usr/local/httpd/bin/httpd -k start
webuser   9551  0.0  0.3  19104   800 ?        S    10:28   0:00 /usr/local/httpd/bin/httpd -k start
bob031- 8 févr. 2007 à 13:53
Merci encore à toi lami20j,

Je vais m'inspirer de ton modèle ! Je pense pouvoir m'en sortir !
Merci encore !

bob
Ajouter un commentaire
Réponse
+1
moins plus
Fait un signe si ça coince :-))
bob031- 8 févr. 2007 à 14:05
En fait je coince un peu !

J'ai voulu rajouter le user nobody :
[root@localhost etc]# useradd nobody
useradd : l'utilisateur nobody existe
[root@localhost etc]# more group
root:x:0:
bin:x:1:
daemon:x:2:messagebus,haldaemon
sys:x:3:
adm:x:4:
tty:x:5:ups
disk:x:6:
lp:x:7:
mem:x:8:
kmem:x:9:
wheel:x:10:
mail:x:12:
news:x:13:
uucp:x:14:
man:x:15:
floppy:x:19:
games:x:20:
tape:x:21:
cdrom:x:22:
utmp:x:24:
usb:x:43:saned,ups
cdwriter:x:80:saned
audio:x:81:
video:x:82:
users:x:100:
nogroup:x:65534:
vcsa:x:69:
rpm:x:70:
xgrp:x:101:xfs,gdm
ntools:x:102:
ctools:x:103:
messagebus:x:71:
avahi:x:72:
haldaemon:x:73:
xfs:x:74:
lpadmin:x:104:
gdm:x:75:
saned:x:76:
ups:x:77:ups
ntp:x:78:
slocate:x:105:
toto:x:500:
zozo:x:501:
mysql:x:79:
[root@localhost etc]#

Or je ne vois pas nobody dans la liste !

Je comprends plus rien !

bob
Ajouter un commentaire
Réponse
+1
moins plus
C'est normal puisque le group dont fait partie nobody s'appelle nogroup

nogroup:x:65534:

tape la commande
lami20j@debian:~$ id nobody
uid=65534(nobody) gid=65534(nogroup) groupes=65534(nogroup)

bob031- 8 févr. 2007 à 14:21
Tu as raison !

En fait il fallait écrire dans httpd.conf :
User nobody
Group nogroup

et non pas :
User nobody
Group nobody


Quel imbécile je fais ...............parfois ! -))

Encore un grand merci à toi lami20j

bob

@suivre .....
Ajouter un commentaire
Réponse
+1
moins plus
J'aurais plutôt nommé l'utilisateur nouser au lieu de nobody, pour garder une rassemblence avec nogroup
nouser
nogroup

Mais respectons le choix faite par les développeurs :-))
Ajouter un commentaire
Réponse
+1
moins plus
En effet pourquoi pas ?
L'habitude de voir nobody dans les docs !
:-))

@++
bob
Ajouter un commentaire
Réponse
+1
moins plus
Re-,

Je poursuis mes bidouillages sur Apache !
J'ai récupéré le fichier http.conf original qui remplace donc l'ancien fichier httpd.conf (j'avais fait des modif. mais impossible de me souvenir lesquelles!).
Bref voici en fait ce que j'ai dans le fichier original :
User daemon
Group daemon

Si je tape http://localhost/ dans mon navigateur cela fonctionne !

Mais voici le message d'eereur que j'obtiens lorsque je relance Apache :

[root@localhost apache2]# ./bin/apachectl stop
httpd: Could not reliably determine the server's fully qualified domain name, using 127.0.0.1 for ServerName
[root@localhost apache2]#
[root@localhost apache2]# ./bin/apachectl graceful
httpd: Could not reliably determine the server's fully qualified domain name, using 127.0.0.1 for ServerName
httpd not running, trying to start
[root@localhost apache2]# ./bin/apachectl start
httpd: Could not reliably determine the server's fully qualified domain name, using 127.0.0.1 for ServerName
httpd (pid 9500) already running
[root@localhost apache2]#

Une idée svp ?

D'avance merci.

Hafed
Ajouter un commentaire
Réponse
+1
moins plus
grep -i servername /chemin/vers/httpd.conf 
te donne quoi
bob031- 8 févr. 2007 à 17:56
voici la réponse :

[root@localhost conf]# grep -i servername /usr/local/apache2/conf/httpd.conf
# ServerName gives the name and port that the server uses to identify itself.
#ServerName www.example.com:80
[root@localhost conf]#

Que dois-je incrire dans le fichier httpd.conf ?

Est-ce que localhost serait correct ?

Merci à toi lami20j

bob
Ajouter un commentaire
Réponse
+1
moins plus
Administration de Apache2 sous Linux ...

Configuration et exemple :

http://www.artduweb.com/unix-linux/http
Ajouter un commentaire
Ce document intitulé « Test installation Apache : problèmes ! » issu de CommentCaMarche (www.commentcamarche.net) est mis à disposition sous les termes de la licence Creative Commons. Vous pouvez copier, modifier des copies de cette page, dans les conditions fixées par la licence, tant que cette note apparaît clairement.
Dossier à la une
Passage au tout numérique : quel coût pour les particuliers ?