fraenkiman wrote: Wed Mar 05, 2025 8:02 pm... Can you please copy the following file into the directory /admin/panels/maintain and test it again? ...
Hi fraenkiman,
Ok, it doesn't seem to be that easy.
Installed FlatPress Github 1908, clicked through a bit, rebuild index with one page works. Then copied 100 content pages to /fp-conent and rebuild index, all ok. Played a bit, content pages open in tab, rebuild works and rebuild does not work (see error)
Code: Select all
ENTERING LOWRES MODE
BACKUP INDEX to fp-content/index1741352260
Cannot backup old index. STOP.
Did you just purge the cache? If so, the index was in use to create a new cache. This is done now, please simply reload the current page.
Then tested with Purge theme and templates cache, rebuild works and rebuild does not work (see error).
Adding the new admin.maintain.php, Purge theme and templates cache, rebuild works and rebuild does not work. Now I tested with open pages and after the 3rd or 4th rebuild this error occurs:
Code: Select all
BACKUP INDEX to fp-content/index1741352814
<br />
<b>Warning</b>: rmdir(fp-content/index): Directory not empty in <b>../fpgit1908/admin/panels/maintain/admin.maintain.php</b> on line <b>298</b><br />
<br />
<b>Warning</b>: fopen(fp-content/index/index-0.dat): Failed to open stream: Permission denied in <b>../fpgit1908/fp-includes/core/core.entry.php</b> on line <b>68</b><br />
<br />
<b>Warning</b>: fopen(fp-content/index/index.strings.dat): Failed to open stream: Permission denied in <b>../fpgit1908/fp-includes/core/core.entry.php</b> on line <b>68</b><br />
<br />
<b>Fatal error</b>: Uncaught TypeError: fwrite(): Argument #1 ($stream) must be of type resource, false given in ../fpgit1908/fp-includes/core/core.bplustree.class.php:2613
Stack trace:
#0 ../fpgit1908/fp-includes/core/core.bplustree.class.php(2613): fwrite(false, 'BPTSTRINGS')
#1 ../fpgit1908/fp-includes/core/core.entry.php(73): SBPlusTree->startup()
#2 ../fpgit1908/fp-includes/core/core.entry.php(329): entry_index->__construct()
#3 ../fpgit1908/admin/panels/maintain/admin.maintain.php(43): entry_init()
#4 ../fpgit1908/admin/panels/maintain/admin.maintain.php(155): s_entry_crawler->__construct()
#5 ../fpgit1908/admin/includes/panels.prototypes.php(193): admin_maintain_default->dodo('rebuild')
#6 ../fpgit1908/admin/includes/panels.prototypes.php(129): AdminPanelAction->docommand('do', 'rebuild')
#7 ../fpgit1908/admin/main.php(91): AdminPanelAction->exec()
#8 ../fpgit1908/admin/main.php(210): main()
#9 ../fpgit1908/admin.php(5): require('../htdo...')
#10 {main}
thrown in <b>../fpgit1908/fp-includes/core/core.bplustree.class.php</b> on line <b>2613</b><br />
So, now the big question?
Permission denied or Argument #1 ($stream) must be of type resource, false given.
I will test again with more content pages, but unfortunately I have no idea what exactly is happening here
best regards