wiki-v1 icon indicating copy to clipboard operation
wiki-v1 copied to clipboard

504 error after editing

Open paulhaem opened this issue 7 years ago • 3 comments

Hey there! Wiki.js is running on port 3001 behind an NGINX reverse proxy on Ubuntu 18.04. A few seconds (~10) after editing a page the wiki is not accessible anymore, returning a 504 timeout error. The error log is empty. The wiki works properly again after restarting via node wiki restart and the changes are getting pushed to the remote repository after that. It looks like the process is still running when using ps -ef.

Any ideas on how to fix this?

paulhaem avatar Oct 30 '18 10:10 paulhaem

Try again but without the nginx proxy and using the interactive mode: node server

You'll see in the console what's causing the process to crash.

NGPixel avatar Oct 31 '18 23:10 NGPixel

Sorry for the late answer. I disabled nginx as the reverse proxy and started the wiki using node server on port 80. The wiki still crashes after a few seconds after editing some content. The logs do not give any information about the issue, actually it is even continuing to run jobs successfully.

[SERVER] Wiki.js is initializing...
[SERVER] Checking data directories...
[SERVER] Data and Repository directories are OK.
[SERVER] Checking Git repository...
[SERVER] Starting HTTP/WS server on port 80...
[SERVER] HTTP/WS server started successfully! [RUNNING]
[SERVER] Search index flushed and ready.
[SERVER] Git repository is OK.
[AGENT] Background Agent is initializing...
[AGENT] Checking Git repository...
[AGENT] Running all jobs...
[AGENT] Performing pull from remote Git repository...
[AGENT] Git repository is OK.
[AGENT] Git Pull completed.
[AGENT] Git Push skipped. Repository is already in sync.
[AGENT] All jobs completed successfully! Going to sleep for now.
[AGENT] Running all jobs...
[AGENT] Performing pull from remote Git repository...
[AGENT] Git Pull completed.
[AGENT] Performing push to remote Git repository...
[AGENT] Git Push completed.
[AGENT] All jobs completed successfully! Going to sleep for now.

But instead of returning a 504 error the wiki won't stop loading after refreshing / opening the wiki in a new tab.

UPDATE: After visiting my monitoring I've seen that the node process took about 100% of my CPU until I shut down the server.

paulhaem avatar Nov 21 '18 18:11 paulhaem

@NGPixel you got any ideas on where to look for the issue? Kinda helpless without log output. :/

paulhaem avatar Dec 09 '18 10:12 paulhaem