SOLVED: Greyhole Disk Utilisation App problem

steveblakemore
Posts: 38
Joined: Tue Jan 19, 2010 11:41 am
Location: Spain

SOLVED: Greyhole Disk Utilisation App problem

Postby steveblakemore » Mon Jun 26, 2017 1:39 pm

Technically I'm probably in the wrong forum since this is an App problem. Greyhole appears to be working fine. I intalled the Greyhole Disk Utilization app and it's not working. When I click on the app link from the homepage of my HDA (v10) I se a blank page with "SQL Error:"
At the same time, 2 lines are written to the Amahi Greyhole Log, like so -
Jun 26 20:41:07 WARN initialize: PHP Warning [8]: Undefined property: stdClass::$error in /usr/share/greyhole/web-app/index.php on line 691; BT: index.php[L1] include(/usr/share/greyhole/web-app/index.php) => index.php[L2314] error()
Jun 26 20:41:07 ERROR initialize: PHP Fatal Error: Undefined index: warning; BT: index.php[L962]

I tried uninstalling and reinstalling the app without success.

Any help gratefully received!

Kind regards
Steve

User avatar
bigfoot65
Project Manager
Posts: 11924
Joined: Mon May 25, 2009 4:31 pm

Re: Greyhole Disk Utilisation App problem

Postby bigfoot65 » Mon Jun 26, 2017 2:03 pm

Please provide the URL for:

Code: Select all

apaste --sysinfo
Also check /var/log/amahi-app-installer.log for errors with this app. Please only post relevant lines.

Did you read the special instructions after install in the dashboard?
Stats are gathered once a weekly (usually Sunday mornings). To refresh the data, do the following:
sudo greyhole --fsck --email-report --dont-walk-metadata-store --disk-usage-report
ßîgƒσστ65
Applications Manager

My HDA: Intel(R) Core(TM) i5-3570K CPU @ 3.40GHz on MSI board, 16GB RAM, 1TBx1+2TBx2+4TBx2

steveblakemore
Posts: 38
Joined: Tue Jan 19, 2010 11:41 am
Location: Spain

Re: Greyhole Disk Utilisation App problem

Postby steveblakemore » Tue Jun 27, 2017 1:11 pm

Hi Bigfoot,

Here's your apaste url:
https://da.gd/72oQ

Here are the log entries from the amahi-app-installer log which relate to the Utilization app:
======= app install begin @ 2017-06-12 12:02:54 +0100 ==========
Installing app id ptgxru62zo under /var/hda/platform/html/script/.. ENV=production
Your HDA services have been restarted.
Your HDA services have been restarted.
App: Greyhole Disk Utilization installed
======= app install end @ 2017-06-12 12:02:55 +0100 ==========
======= app uninstall begin @ 2017-06-26 20:33:16 +0100 ==========
Uninstalling app id ptgxru62zo under /var/hda/platform/html/script/.. ENV=production
Your HDA services have been restarted.
App: Greyhole Disk Utilization uninstalled
======= app uninstall end @ 2017-06-26 20:33:17 +0100 ==========
======= app install begin @ 2017-06-26 20:35:38 +0100 ==========
Installing app id ptgxru62zo under /var/hda/platform/html/script/.. ENV=production
Your HDA services have been restarted.
Your HDA services have been restarted.
App: Greyhole Disk Utilization installed
======= app install end @ 2017-06-26 20:35:39 +0100 ==========

I had read the special instructions after installing, and when I didn't see any results, I thought that it would automatically work after a Sunday morning. I let two Sundays go by and still nothing, that's why I contacted the forum.

OK, so now after doing all that above I ran the command:
sudo greyhole --fsck --email-report --dont-walk-metadata-store --disk-usage-report
And now I can see the visualization! :)
So - do I have to run that command every time I want to use the App? Or will it run automatically now after the first run? I actually thought that the app would work automatically without running the command.

Steve

User avatar
bigfoot65
Project Manager
Posts: 11924
Joined: Mon May 25, 2009 4:31 pm

Re: Greyhole Disk Utilisation App problem

Postby bigfoot65 » Tue Jun 27, 2017 1:29 pm

Thanks for the URL info.
So - do I have to run that command every time I want to use the App? Or will it run automatically now after the first run? I actually thought that the app would work automatically without running the command.
It should run automatically each Sunday or whenever the fsck is scheduled for your shares. That is our expectation. This is a Greyhole app, so we're dependent on how it's coded to work. It did work on my HDA.

Post the contents of /etc/cron.weekly/greyhole.

BTW there's a bug with the web app in this Greyhole release. If you drill down to the file level in a folder, it will produce a SQL error.

It has been identified and corrected by the author in the latest version (0.10.10). We have not updated the #Amahi version yet though. It will automatically update once we do, so no action on your part needed.

Hope to have it done soon.

Can we mark this one as solved?
ßîgƒσστ65
Applications Manager

My HDA: Intel(R) Core(TM) i5-3570K CPU @ 3.40GHz on MSI board, 16GB RAM, 1TBx1+2TBx2+4TBx2

steveblakemore
Posts: 38
Joined: Tue Jan 19, 2010 11:41 am
Location: Spain

Re: Greyhole Disk Utilisation App problem

Postby steveblakemore » Wed Jun 28, 2017 5:06 am

Hi Bigfoot,

The contents of /etc/cron.weekly/greyhole:

#!/bin/sh

# Weekly fsck
if [ -f /usr/share/greyhole/gh-disk-usage.log ]; then rm /usr/share/greyhole/gh-disk-usage.log; fi
/usr/bin/greyhole --fsck --email-report --dont-walk-metadata-store --disk-usage-report > /dev/null

# This calls home to report anonymous data about Greyhole usage.
# It sends the output of 'greyhole --stats' to the greyhole.net server.
# Please leave this here... We use it to get usage stats for Greyhole.
echo "s=`/usr/bin/greyhole --getuid`&d=`/usr/bin/greyhole --stats --json`" | curl -s --data @- https://api.amahi.org/api2/greyhole > /dev/null


I'm no expert but that script looks OK to me. I don't know why it has only just started working, but I'm happy for you to mark this as solved.
Thanks for your help again. :)

Kind regards
Steve

User avatar
bigfoot65
Project Manager
Posts: 11924
Joined: Mon May 25, 2009 4:31 pm

Re: Greyhole Disk Utilisation App problem

Postby bigfoot65 » Wed Jun 28, 2017 5:24 am

The file looks as it should.

I tested the latest version of Greyhole (0.10.10) last night, so it should be pushed to HDAs soon.

Happy to assist and thanks for identifying the issue. It also exposed a problem with Greyhole which was quickly fixed.
ßîgƒσστ65
Applications Manager

My HDA: Intel(R) Core(TM) i5-3570K CPU @ 3.40GHz on MSI board, 16GB RAM, 1TBx1+2TBx2+4TBx2

User avatar
bigfoot65
Project Manager
Posts: 11924
Joined: Mon May 25, 2009 4:31 pm

Re: SOLVED: Greyhole Disk Utilisation App problem

Postby bigfoot65 » Thu Jun 29, 2017 6:49 am

Greyhole 0.10.10 was released yesterday.

Recommend you uninstall/reinstall the greyhole-disk-utilization App.
ßîgƒσστ65
Applications Manager

My HDA: Intel(R) Core(TM) i5-3570K CPU @ 3.40GHz on MSI board, 16GB RAM, 1TBx1+2TBx2+4TBx2

Who is online

Users browsing this forum: No registered users and 19 guests