Problem with Beta 5.0:
When updating gravity with pihole -g
(and other methods), the last update date you see in the web interface when mousing over the "Domains on Blocklist" icon on the web interface doesn't change.
I've updated gravity several times in the past 8 days.
Debug Token:
https://tricorder.pi-hole.net/jsq1jjat58
I concur, am seeing the same thing on two pis with latest version in Chrome, after Ctrl-F5.
I see 12 days since last gravity update when mousing over the "Domain Block List"
I tried:
Update Gravity from GUI
The command > pihole updateGravity
The command pihole -g
Each time the command stat /etc/pihole/.gravity.list shows:
File: /etc/pihole/gravity.list
Size: 2743593 Blocks: 5360 IO Block: 4096 regular file
Device: b302h/45826d Inode: 130518 Links: 1
Access: (0644/-rw-r--r--) Uid: ( 0/ root) Gid: ( 0/ root)
Access: 2020-01-26 20:13:53.512987087 +0000
Modify: 2020-01-26 20:13:53.522987058 +0000
Change: 2020-01-26 20:13:53.532987028 +0000
Birth: -
Not sure why 'Birth:' should show '-'
The 12 days mentioned in the popup is the 2020-26-01
Steen
Mine says 16 days ago, but I've definitely seen the number change, so I think it's just a cosmetic issue.
DL6ER
February 12, 2020, 6:30pm
6
This bug will be fixed by
pi-hole:release/v5.0
← pi-hole:fix/gravity_updated_timestamp
opened 06:29PM - 12 Feb 20 UTC
**By submitting this pull request, I confirm the following:**
- [X] I have r… ead and understood the [contributors guide](https://github.com/pi-hole/pi-hole/blob/master/CONTRIBUTING.md), as well as this entire template.
- [X] I have made only one major change in my proposed changes.
- [X] I have commented my proposed changes within the code.
- [X] I have tested my proposed changes, and have included unit tests where possible.
- [X] I am willing to help maintain this change if there are issues with it later.
- [X] I give this submission freely and claim no ownership.
- [X] It is compatible with the [EUPL 1.2 license](https://opensource.org/licenses/EUPL-1.1)
- [X] I have squashed any insignificant commits. ([`git rebase`](http://gitready.com/advanced/2009/02/10/squashing-commits-with-rebase.html))
---
**What does this PR aim to accomplish?:**
Fix bug described on [Discourse](https://discourse.pi-hole.net/t/last-update-date-for-gravity-doesnt-change/28026).
**How does this PR accomplish the above?:**
We updated the timestamp in the new database, however, the swapping of the databases overwrote this update, effectively keeping the timestamp stored in the old database (this is why it never advanced).
We overwrite the timestamp now **after** database swapping.
**What documentation changes (if any) are needed to support this PR?:**
None
Thanks for reporting this issue!
2 Likes
seh2000
February 16, 2020, 4:58pm
7
Hi
I still see it is not being updated, I have done pihole -up and pihole -g and pihole -v (result below)
Steen
pi@hanlopdns:/etc/pihole $ stat gravity.list
File: gravity.list
Size: 2743593 Blocks: 5360 IO Block: 4096 regular file
Device: b302h/45826d Inode: 130518 Links: 1
Access: (0644/-rw-r--r--) Uid: ( 0/ root) Gid: ( 0/ root)
Access: 2020-01-26 20:13:53.512987087 +0000
Modify: 2020-01-26 20:13:53.522987058 +0000
Change: 2020-01-26 20:13:53.532987028 +0000
Birth: -
pi@hanlopdns:/etc/pihole $ pihole -v
Pi-hole version is v4.3.2-401-g082cfb2 (Latest: v4.3.2)
AdminLTE version is v4.3.2-412-g1dc359d (Latest: v4.3.2)
FTL version is vDev-ff840d0 (Latest: v4.3.1)
DL6ER
February 17, 2020, 5:07am
10
Merged. Please update your Pi-hole.
2 Likes
seh2000
February 17, 2020, 7:09pm
11
Hi,
It looks like this is now working.
Will do a few more tests as I am not 110% sure...
30 min after update gravity, then when hovering over 'Domains on Blocklist' the time is not updating...
The command "stat gravity.list" still shows the 26 of January as previous posting.
File: gravity.list
Size: 2743593 Blocks: 5360 IO Block: 4096 regular file
Device: b302h/45826d Inode: 130518 Links: 1
Access: (0644/-rw-r--r--) Uid: ( 0/ root) Gid: ( 0/ root)
Access: 2020-01-26 20:13:53.512987087 +0000
Modify: 2020-01-26 20:13:53.522987058 +0000
Change: 2020-01-26 20:13:53.532987028 +0000
Birth: -
So I think this is not working 100%
Steen
DL6ER
February 17, 2020, 8:23pm
12
seh2000:
stat gravity.list
This is the wrong file. Check /etc/pihole/gravity.db
.
seh2000
February 17, 2020, 8:35pm
13
Sorry - here the right stat
stat gravity.db
File: gravity.db
Size: 9502720 Blocks: 18560 IO Block: 4096 regular file
Device: b302h/45826d Inode: 134340 Links: 1
Access: (0664/-rw-rw-r--) Uid: ( 999/ pihole) Gid: ( 995/ pihole)
Access: 2020-02-17 19:03:25.582319635 +0000
Modify: 2020-02-17 19:03:34.712455549 +0000
Change: 2020-02-17 19:09:39.319999998 +0000
Birth: -
and
Thanks the fix
Steen