h5ai icon indicating copy to clipboard operation
h5ai copied to clipboard

h5ai stops working if a folder is mounted on web server

Open ahmadby100 opened this issue 4 years ago • 5 comments

I have mounted a cloud drive on my web server's (nginx) root folder using rclone. When the folder is mounted and i access the page, it will just keep on loading before finally timing out. As soon as I remove the mount, everything works and is back to normal.

I have tested this out with apache as well and it causes the same issue. Thanks

ahmadby100 avatar Aug 20 '20 09:08 ahmadby100

Seeing this issue right now as well.

vercas avatar Feb 01 '21 02:02 vercas

yes i got the same

My all h5ai crashed when a mounted

gamersalpha avatar Feb 01 '21 16:02 gamersalpha

Same issue here. I tried debugging with nginx but the log file(even on the highest log level, debug) doesn't contain any useful information about which php file produces the crash.
~~I have nearly zero experience with php, but I found a logger class here: https://github.com/lrsjng/h5ai/blob/master/src/_h5ai/private/php/core/class-logger.php Is there a way to get meaningful logs out of h5ai itself?~~
running rclone mount -vv gdrive:/ /mnt/gdrive I was able to see what rclone is doing while the page loads. It turns out that h5ai recursively walks though the entire mounted folder. The website runs into a timeout before h5ai is able to complete the recursive dir lookup.

After searching for existing issues, I found Issue #629 which describes problems with very large directories, basically the same issue we are having here. I'm not promising anything, but I am planning on forking h5ai and adding the changes @lapsio made to the class-item.php file. I will check if that solution is a good idea and submit a pull request, if it is.

Morpheus0x avatar Jun 21 '21 12:06 Morpheus0x

@Toby4213 I believe I may have fixed the issue in merge request #771 already. It's already merged in my fork. You could also give it a try (there is a release too).

glubsy avatar Jun 21 '21 15:06 glubsy

@glubsy Yes I found your PR and compiled your fork. I disabled the foldersize plugin and it seems to work.

Morpheus0x avatar Jun 21 '21 20:06 Morpheus0x