GoAccess log error from ns slave

Discussion in 'ISPConfig 3 Priority Support' started by atle, Mar 8, 2021.

  1. atle

    atle Member HowtoForge Supporter

    I have got an error message from the ns slave server that makes no sense
    Code:
    Stats couldn't be generated. The GoAccess binary couldn't be found. Make sure that GoAccess is installed and that it is in $PATH
    The server role is "DNS server" only, and mirrored to the master server.
    The NS server has been created with the auto install script.
    [​IMG]
     
  2. Th0m

    Th0m ISPConfig Developer Staff Member ISPConfig Developer

    What command did you use to install?

    Which services are enabled for both of your nameservers?
     
  3. atle

    atle Member HowtoForge Supporter

    Code:
    curl https://get.ispconfig.org | sh -s --  --interactive --no-web --no-mail --no-quota --no-firewall --use-php=system  2>&1 | tee autoinstall.log
    [​IMG]
     
  4. Th0m

    Th0m ISPConfig Developer Staff Member ISPConfig Developer

    And ic.etableraweb.com is your main nameserver?

    When mirroring that server, I think it will also try to mirror the websites, as you currently can't mirror per service. Not 100% sure though.
     
  5. till

    till Super Moderator Staff Member ISPConfig Developer

    As far as I can see, you installed a DNS only server. I guess goAccess is only installed when you install a web server, so the ISPConfig cron plugin which creates the goaccess logs should not throw an error at all in your case. I guess we should change the error priority from error to debug?
     
  6. atle

    atle Member HowtoForge Supporter

    GoAccess seems a bit random, dont you think? There are other services that belongs to a web server, and these do not through any error messages.
     
  7. till

    till Super Moderator Staff Member ISPConfig Developer

    That's exactly why I said that goAccess plugin should not throw it as an error.
     
  8. Th0m

    Th0m ISPConfig Developer Staff Member ISPConfig Developer

    Setting it to debug would cause issues as users might fail to see GoAccess is not installed (correctly)... Might be that the problem is elsewhere, as it shouldn't try to use the GoAccess plugin anyway?
     
    atle likes this.
  9. till

    till Super Moderator Staff Member ISPConfig Developer

    I had a look at the code of that plugin and it tests already if there are websites on that server that have goAccess enabled. Please run the following query in the dbispconfig database on the ns2 node and post the result. Replace ? at the end of the query with the server_id if the ns2 node:

    Code:
    SELECT domain_id, sys_groupid, domain, document_root, web_folder, type, system_user, system_group, parent_domain_id FROM web_domain WHERE (type = 'vhost' or type = 'vhostsubdomain' or type = 'vhostalias') and stats_type = 'goaccess' AND server_id = ?
     
  10. atle

    atle Member HowtoForge Supporter

    I removed the server_id and statement:

    Code:
    root@ns2:~# mysql -p dbispconfig
    Enter password:
    Reading table information for completion of table and column names
    You can turn off this feature to get a quicker startup with -A
    
    Welcome to the MariaDB monitor.  Commands end with ; or \g.
    Your MariaDB connection id is 17744
    Server version: 10.3.27-MariaDB-0+deb10u1 Debian 10
    
    Copyright (c) 2000, 2018, Oracle, MariaDB Corporation Ab and others.
    
    Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.
    
    MariaDB [dbispconfig]> SELECT domain_id, sys_groupid, domain, document_root, web_folder, type, system_user, system_group, parent_domain_id FROM web_domain WHERE (type = 'vhost' or type = 'vhostsubdomain' or type = 'vhostalias') and stats_type = 'goaccess';
    +-----------+-------------+-------------+-------------------------------+------------+-------+-------------+--------------+------------------+
    | domain_id | sys_groupid | domain      | document_root                 | web_folder | type  | system_user | system_group | parent_domain_id |
    +-----------+-------------+-------------+-------------------------------+------------+-------+-------------+--------------+------------------+
    |         6 |           7 | blogg.click | /var/www/clients/client6/web6 |            | vhost | web6        | client6      |                0 |
    +-----------+-------------+-------------+-------------------------------+------------+-------+-------------+--------------+------------------+
    1 row in set (0.000 sec)
     
  11. atle

    atle Member HowtoForge Supporter

    And this
    gives this

    Code:
    domain_id    sys_groupid    domain    document_root    web_folder    type    system_user    system_group    parent_domain_id    stats_type
    6    7    blogg.click    /var/www/clients/client6/web6        vhost    web6    client6    0    goaccess
    7    8    webbmotell.se    /var/www/clients/client7/web7        vhost    web7    client7    0    awstats
    Hence, one site is using awstats and there are no error messages from that.
     
  12. atle

    atle Member HowtoForge Supporter

    Missed you instruction of replacing ? for server_id, here I included server_id in select part.
    Code:
    domain_id    sys_groupid    domain    document_root    web_folder    type    system_user    system_group    parent_domain_id    stats_type    server_id
    6    7    blogg.click    /var/www/clients/client6/web6        vhost    web6    client6    0    goaccess    2
    7    8    webbmotell.se    /var/www/clients/client7/web7        vhost    web7    client7    0    awstats    2
     
  13. till

    till Super Moderator Staff Member ISPConfig Developer

    Ok, so if I interpret this correctly: you installed the ns2 server as name server only without web services using autoinstaller. But instead running name services only, you then added apache or nginx and websites on this server. You configured these websites to use goAccess, but due to your inital choice to run DNS only without web services, goAccess is not installed on the system by the autoinstaller, which then results in an error that reminds you to install goAccess.
     
  14. atle

    atle Member HowtoForge Supporter

    yes

    No, I cant see where I did say this. Dont understand what you mean.

    Here is some output of the install
    Code:
    ISPConfig mysql database username [ispconfig]:
    ISPConfig mysql database password [************************]:
    Shall this server join an existing ISPConfig multiserver setup (y,n) [n]: y
    MySQL master server hostname []:
    MySQL master server port []:
    MySQL master server root username [root]:
    MySQL master server root password []:
    MySQL master server database name [dbispconfig]:
    Adding ISPConfig server record to database.
    
    Configure Mail (y,n) [y]: n
    [WARN] autodetect for Jailkit failed
    Force configure Jailkit (y,n) [n]:
    Skipping Jailkit
    
    [WARN] autodetect for pureftpd failed
    Force configure pureftpd (y,n) [n]:
    Skipping pureftpd
    
    Configure DNS Server (y,n) [y]:
    Configuring BIND
    The Web Server option has to be enabled when you want run a web server or when this node shall host the ISPConfig interface.
    Configure Web Server (y,n) [y]: n
    [WARN] autodetect for OpenVZ failed
    Force configure OpenVZ (y,n) [n]:
    Skipping OpenVZ
    
    Configure Firewall Server (y,n) [y]: n
    [WARN] autodetect for Metronome XMPP Server failed
    Force configure Metronome XMPP Server (y,n) [n]:
    Skipping Metronome XMPP Server
    
    Configuring Fail2ban
    PHP Warning:  symlink(): No such file or directory in /tmp/ispconfig3_install/install/lib/installer_base.lib.php on line 2820
    Install ISPConfig Web Interface (y,n) [n]:
    Do you want to create SSL certs for your server? (y,n) [y]: n
    Configuring DBServer
    Installing ISPConfig crontab
    Detect IP addresses
    Restarting services ...
    Failed to restart apache2.service: Unit apache2.service not found.
    Installation completed.
    [INFO] Checking all services are running.
    [INFO] mysql: OK
    [INFO] clamav-daemon: OK
    [INFO] postfix: OK
    [INFO] bind9: OK
    [INFO] Installation ready.
    [INFO] Your MySQL root password is: ************************************
    [INFO] Warning: Please delete the log files in /tmp/ispconfig-ai/var/log/setup-* once you don't need them anymore because they contain your passwords!
     
  15. Th0m

    Th0m ISPConfig Developer Staff Member ISPConfig Developer

    Could you share a screenshots of the page on System -> Server services?
     
  16. till

    till Super Moderator Staff Member ISPConfig Developer

    You did not say that but the SQL query result that you posted shows that you have added 2 websites on the name server which have goAccess enabled. The sites are blogg.click and webbmotell.se. It might be that you did not install a web server, but the sites have been added on the nameserver, at least if you did not mixed up server ID's.
     
  17. atle

    atle Member HowtoForge Supporter

    I believe I did above, or do you mean something else?
     
  18. Th0m

    Th0m ISPConfig Developer Staff Member ISPConfig Developer

    My bad, yes, you did.

    Does blogg.click exist on the main server?
     
  19. atle

    atle Member HowtoForge Supporter

    The web sites are added on the IC master server.
    The NS server is mirrored to the master server, to make sure the zones are transferred, and in accordance with the instruction Till has given in the forum, for setting up a NS slave server.
    Both sited have ic.etableraweb.com as their webserver. It is not even possible in the gui to assign a ns as a webserver.
     
  20. atle

    atle Member HowtoForge Supporter

    Yes, the only web server there is now, is the master server.
     

Share This Page