Guest User!

You are not Sophos Staff.

This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Unable to solve "HINT: Please REINDEX it" problem

Hello,

I have gathered important logs I cannot afford to loose. However, I cannot read them in Sophos UTM either. 
In WebGUI logs: Bandwidth Usage, Firewall, Advanced Threat Protection, IPS error:  
Can't use string ("0") as a HASH ref while "strict refs" in use at /wfe/asg/modules/reporting.pm line 501.

Found discussions about log corruption like:
https://community.sophos.com/products/unified-threat-management/astaroorg/f/56/t/49416
Got results:

psql -Ureporting -c"reindex database reporting;" reporting

psql: FATAL:  index "pg_attribute_relid_attnum_index" contains unexpected zero page at block 0
HINT:  Please REINDEX it.
A:/root # psql -Ureporting -c"vacuum;" reporting
psql: FATAL:  index "pg_attribute_relid_attnum_index" contains unexpected zero page at block 0
HINT:  Please REINDEX it.
A:/root # psql -U reporting -c "REINDEX DATABASE reporting"
psql: FATAL:  index "pg_attribute_relid_attnum_index" contains unexpected zero page at block 0
HINT:  Please REINDEX it.
A:/root # psql -U reporting -c "REINDEX DATABASE reporting"
psql: FATAL:  index "pg_attribute_relid_attnum_index" contains unexpected zero page at block 0
HINT:  Please REINDEX it.
A:/root # psql -U reporting -c "REINDEX INDEX pg_attribute_relid_attnum_index"
psql: FATAL:  index "pg_attribute_relid_attnum_index" contains unexpected zero page at block 0
HINT:  Please REINDEX it.


After some Googling I've also tried:
reindexdb -U reporting -d reporting -i pg_attribute_relid_attnum_index

reindexdb: could not connect to database reporting: FATAL:  index "pg_attribute_relid_attnum_index" contains unexpected zero page at block 0
HINT:  Please REINDEX it.


Should I go into passing "ignore_system_indexes=true" and then trying to reindex? If so, what is the best way to do it?

Please, any advice would be very helpful.


This thread was automatically locked due to age.
Parents
  • Re-indexing or even rebuilding the database will fix reporting issues, but cannot fix corruption of the raw log files, but there is linkage between the two.

    You will lose historical reporting (not logs) by doing so, but you can rebuild the reporting databases by running /etc/init.d/postgresql92 rebuild  from the shell as root.
Reply
  • Re-indexing or even rebuilding the database will fix reporting issues, but cannot fix corruption of the raw log files, but there is linkage between the two.

    You will lose historical reporting (not logs) by doing so, but you can rebuild the reporting databases by running /etc/init.d/postgresql92 rebuild  from the shell as root.
Children
No Data