IdentifiantMot de passe
Loading...
Mot de passe oublié ?Je m'inscris ! (gratuit)
Navigation

Inscrivez-vous gratuitement
pour pouvoir participer, suivre les réponses en temps réel, voter pour les messages, poser vos propres questions et recevoir la newsletter

Apache Discussion :

"Unable to open logs" au démarrage d'Apache


Sujet :

Apache

  1. #1
    Membre régulier
    Profil pro
    Ingénieur intégration
    Inscrit en
    Août 2007
    Messages
    147
    Détails du profil
    Informations personnelles :
    Localisation : Suisse

    Informations professionnelles :
    Activité : Ingénieur intégration

    Informations forums :
    Inscription : Août 2007
    Messages : 147
    Points : 77
    Points
    77
    Par défaut "Unable to open logs" au démarrage d'Apache
    Bonjour à vous,

    Je tourne depuis quelques heures sur un problème sans en trouver la solution! Je suis presque certain que cela doit être tout con...

    En configurant le fichier listen.conf de cette manière je peux démarrer apache sans problème :
    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    3
    4
    5
    6
    7
    8
    9
    cat listen.conf
    Listen 80
    <IfDefine SSL>
     <IfDefine !NOSSL>
      <IfModule mod_ssl.c>
            Listen 443
      </IfModule>
     </IfDefine>
    </IfDefine>
    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    # service apache2 start
    Starting httpd2 (prefork)                                                             done
    Par contre en utilisant un virtualhost, cela ne fonctionne pas
    J'ai essayé de simplifier au maximum mon fichier pour trouver le problème...
    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    cat listen.conf
    NameVirtualHost *:80
    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
     # cat test.conf
    <VirtualHost *:80>
        ServerName schulung01.xxxx.net
        DocumentRoot /srv/www/htdocs/cacti
        ErrorLog /var/log/apache2/cacti-error_log
        CustomLog /var/log/apache2/cacti-access_log combined
        HostnameLookups Off
        UseCanonicalName Off
        ServerSignature On
     
        <Directory "/srv/www/htdocs/cacti">
            Options Indexes FollowSymLinks
            AllowOverride None
            Order allow,deny
            Allow from all
        </Directory>
    </VirtualHost>
    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    3
    4
    5
     # service apache2 start
    Starting httpd2 (prefork) no listening sockets available, shutting down
    Unable to open logs
    startproc:  exit status of parent of /usr/sbin/httpd2-prefork: 1
                                                                                          failed
    Où peut être le problème????? droit d'accès??? mais où????
    Et on voit bien qu'en générant cette erreur, apache n'écrit nulle part dans les logs!
    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    3
    4
    5
    6
    7
    8
    # ll /var/log/apache2/
    total 36
    -rw-r--r--+ 1 root root 17311 Dec  6 12:10 access_log
    -rw-r--r--+ 1 root root     0 Dec  5 16:46 cacti-access_log
    -rw-r--r--+ 1 root root     0 Dec  6 10:39 cacti-error_log
    -rw-r--r--+ 1 root root  1300 Dec  6 12:55 error_log
    -rw-r--r--  1 root root    10 Dec  6 12:55 rcapache2.out
    ...
    Quelqu'un a-t-il une piste? une idée?

  2. #2
    Invité
    Invité(e)
    Par défaut
    Salut,

    Il te faut obligatoirement une directive Listen dans ton fichier de configuration. Sinon ton serveur apache ne pourra pas démarrer.

    Exemple où j'ai mis mes directives Listen en commentaire:

    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
     
    root@vm-ubuntu8:~# cat /etc/apache2/ports.conf
    # If you just change the port or add more ports here, you will likely also
    # have to change the VirtualHost statement in
    # /etc/apache2/sites-enabled/000-default
    # This is also true if you have upgraded from before 2.2.9-3 (i.e. from
    # Debian etch). See /usr/share/doc/apache2.2-common/NEWS.Debian.gz and
    # README.Debian.gz
     
    NameVirtualHost *:80
    #Listen 80
     
    <IfModule mod_ssl.c>
        # If you add NameVirtualHost *:443 here, you will also have to change
        # the VirtualHost statement in /etc/apache2/sites-available/default-ssl
        # to <VirtualHost *:443>
        # Server Name Indication for SSL named virtual hosts is currently not
        # supported by MSIE on Windows XP.
    #    Listen 443
    </IfModule>
     
    <IfModule mod_gnutls.c>
    #    Listen 443
    </IfModule>
    root@vm-ubuntu8:~# /etc/init.d/apache2 start
    * Starting web server apache2 no listening sockets available, shutting down
    Unable to open logs

  3. #3
    Membre régulier
    Profil pro
    Ingénieur intégration
    Inscrit en
    Août 2007
    Messages
    147
    Détails du profil
    Informations personnelles :
    Localisation : Suisse

    Informations professionnelles :
    Activité : Ingénieur intégration

    Informations forums :
    Inscription : Août 2007
    Messages : 147
    Points : 77
    Points
    77
    Par défaut
    Ah! ben oui... évidemment! Il me semblait bien que j'étais prêt du but...

    Merci beaucoup pour ton aide

    Salutations

+ Répondre à la discussion
Cette discussion est résolue.

Discussions similaires

  1. Unable to open logs
    Par poxtra_102 dans le forum Apache
    Réponses: 2
    Dernier message: 26/03/2010, 15h49
  2. Unable to open file 'DSGNINTF.OBJ'
    Par chamamo dans le forum C++Builder
    Réponses: 2
    Dernier message: 19/06/2006, 09h35
  3. Warning : unable to open initiale console.
    Par troumad dans le forum Administration système
    Réponses: 2
    Dernier message: 23/07/2005, 21h36

Partager

Partager
  • Envoyer la discussion sur Viadeo
  • Envoyer la discussion sur Twitter
  • Envoyer la discussion sur Google
  • Envoyer la discussion sur Facebook
  • Envoyer la discussion sur Digg
  • Envoyer la discussion sur Delicious
  • Envoyer la discussion sur MySpace
  • Envoyer la discussion sur Yahoo