Clients Chart Not Loading (Spinning Wheel)

Expected Behaviour:

Pihole admin dashboard display clients chart correctly

Actual Behaviour:

Pihole admin dashboard does not display clients chart correctly. It also appears that domains blocked is off (maybe doubled).

I am on the FTLDNS branch for core and web.

*** [ DIAGNOSING ]: contents of /var/log/lighttpd

-rw-r--r-- 1 www-data www-data 131713388 Mar 28 19:11 /var/log/lighttpd/error.log
   2018-03-26 06:25:05: (server.c.1534) logfiles cycled UID = 0 PID = 7266 
   2018-03-26 16:18:10: (mod_fastcgi.c.2543) FastCGI-stderr: PHP Fatal error:  Uncaught ArgumentCountError: Too few arguments to function resolveHostname(), 1 passed in /var/www/html/admin/api_FTL.php on line 308 and exactly 2 expected in /var/www/html/admin/scripts/pi-hole/php/FTL.php:143
   2018-03-26 16:18:10: (mod_fastcgi.c.2543) FastCGI-stderr: Stack trace:
   2018-03-26 16:18:10: (mod_fastcgi.c.2543) FastCGI-stderr: 
   2018-03-26 16:18:10: (mod_fastcgi.c.2543) FastCGI-stderr: 
   2018-03-26 16:18:10: (mod_fastcgi.c.2543) FastCGI-stderr: 
   2018-03-26 16:18:10: (mod_fastcgi.c.2543) FastCGI-stderr:   thrown in /var/www/html/admin/scripts/pi-hole/php/FTL.php on line 143
   2018-03-26 16:19:11: (mod_fastcgi.c.2543) FastCGI-stderr: PHP Fatal error:  Uncaught ArgumentCountError: Too few arguments to function resolveHostname(), 1 passed in /var/www/html/admin/api_FTL.php on line 308 and exactly 2 expected in /var/www/html/admin/scripts/pi-hole/php/FTL.php:143
   2018-03-26 16:19:11: (mod_fastcgi.c.2543) FastCGI-stderr: Stack trace:
   2018-03-26 16:19:11: (mod_fastcgi.c.2543) FastCGI-stderr: 
   2018-03-26 16:19:11: (mod_fastcgi.c.2543) FastCGI-stderr: 
   2018-03-26 16:19:11: (mod_fastcgi.c.2543) FastCGI-stderr: 
   2018-03-26 16:19:11: (mod_fastcgi.c.2543) FastCGI-stderr:   thrown in /var/www/html/admin/scripts/pi-hole/php/FTL.php on line 143
   2018-03-26 16:20:12: (mod_fastcgi.c.2543) FastCGI-stderr: PHP Fatal error:  Uncaught ArgumentCountError: Too few arguments to function resolveHostname(), 1 passed in /var/www/html/admin/api_FTL.php on line 308 and exactly 2 expected in /var/www/html/admin/scripts/pi-hole/php/FTL.php:143
   2018-03-26 16:20:12: (mod_fastcgi.c.2543) FastCGI-stderr: Stack trace:
   2018-03-26 16:20:12: (mod_fastcgi.c.2543) FastCGI-stderr: 
   2018-03-26 16:20:12: (mod_fastcgi.c.2543) FastCGI-stderr: 
   2018-03-26 16:20:12: (mod_fastcgi.c.2543) FastCGI-stderr: 
   2018-03-26 16:20:12: (mod_fastcgi.c.2543) FastCGI-stderr:   thrown in /var/www/html/admin/scripts/pi-hole/php/FTL.php on line 143
   2018-03-26 16:21:29: (mod_fastcgi.c.2543) FastCGI-stderr: PHP Fatal error:  Uncaught ArgumentCountError: Too few arguments to function resolveHostname(), 1 passed in /var/www/html/admin/api_FTL.php on line 308 and exactly 2 expected in /var/www/html/admin/scripts/pi-hole/php/FTL.php:143
   2018-03-26 16:21:29: (mod_fastcgi.c.2543) FastCGI-stderr: Stack trace:
   2018-03-26 16:21:29: (mod_fastcgi.c.2543) FastCGI-stderr: 
   2018-03-26 16:21:29: (mod_fastcgi.c.2543) FastCGI-stderr: 
   2018-03-26 16:21:29: (mod_fastcgi.c.2543) FastCGI-stderr: 
   2018-03-26 16:21:29: (mod_fastcgi.c.2543) FastCGI-stderr:   thrown in /var/www/html/admin/scripts/pi-hole/php/FTL.php on line 143

Please let me know if you need anything else to debug.

Thank you,
David

The full debug log would be best

pihole -d

or do it through the Web interface:

Here you go: n3psfn6x88

I have somewhere of an odd setup as I am forwarding request to the "stubby" daemon which uses dns over tls. I wouldn't think that would really affect the pihole web interface though.

Hi Jacob,

Edited

I have tried different browsers WITHOUT success. I have also tried some other solutions in other threads (like completely removing the WWW dir and doing a fresh git.

I'm definitely not a php guy, but looking in the stack trace and at the file mentioned (api_FTL.php), it does appear the wrong amount of parameters are being passed. I'm assuming that is why I'm getting a 500 error when the admin site calls to get the client info

Let me know what you think.

Thank you,
David

Had the same errors. Found the fix.

in /var/www/html/admin/api_FTL.php
change line 308 from
$forward_dest[resolveHostname($tmp[2])] = floatval($tmp[1]);

to

$forward_dest[resolveHostname($tmp[2],true)] = floatval($tmp[1]);

Chart works great now!!

It works if you use true or false…just seems to need a second parameter.

Maybe one of the dev's will see this and add the fix into the branch they are working on.

3 Likes

Pinging @DL6ER or @Mcat12 for their opinions.

PRs are also welcome if you want to contribute your fix. It would help the fix get in place faster.

As @zeit0dn1 mentioned, the proposed change does fix the issue.

(I opened a separate issue regarding the doubling of domains blocked.)

It did work here: Cant see my graphs - #4 by nero355

Sorry, I apparently missed that, discourse emails are somehow still now very reliable for me (I anyhow get pinged way too often :smile: ). I'm in the train without a laptop near me, but I try to remember to look at this. Feel free to ping me again if I forget again...

It is now fixed

1 Like

Solid. There's a few other threads I will post this in.

1 Like

This topic was automatically closed 21 days after the last reply. New replies are no longer allowed.