XF 2.0 failed to open stream: Permission denied

FoxCom

Member
Hi, I'm seeing this error for a few days now and it has started to worry me a little since all the file health checks are set to pending and if I manually run it, I get into more errors. I'm 2.0.10

Here's 1

[LIST] [*]ErrorException: [E_WARNING] file_get_contents(/home2/x/public_html/src/vendor/league/flysystem/build/osx_install_composer.sh): failed to open stream: Permission denied [*]src/XF/Util/Hash.php:9 [/LIST]

[SIZE=5][B]Stack trace[/B][/SIZE] #0 [internal function]: XF::handlePhpError(2, 'file_get_conten...', '/home2/x/p...', 9, Array) #1 src/XF/Util/Hash.php(9): file_get_contents('/home2/x/p...') #2 src/XF/Job/FileCheck.php(169): XF\Util\Hash::hashTextFile('/home2/x/p...', 'sha256') #3 src/XF/Job/Manager.php(241): XF\Job\FileCheck->run(7.9999980926514) #4 src/XF/Job/Manager.php(187): XF\Job\Manager->runJobInternal(Array, 7.9999980926514) #5 src/XF/Job/Manager.php(76): XF\Job\Manager->runJobEntry(Array, 7.9999980926514) #6 src/XF/Admin/Controller/Tools.php(139): XF\Job\Manager->runQueue(true, 8) #7 src/XF/Mvc/Dispatcher.php(249): XF\Admin\Controller\Tools->actionRunJob(Object(XF\Mvc\ParameterBag)) #8 src/XF/Mvc/Dispatcher.php(89): XF\Mvc\Dispatcher->dispatchClass('XF:Tools', 'run-job', 'html', Object(XF\Mvc\ParameterBag), 'tools', Object(EWR\Member\Admin\Controller\Tools), NULL) #9 src/XF/Mvc/Dispatcher.php(41): XF\Mvc\Dispatcher->dispatchLoop(Object(XF\Mvc\RouteMatch)) #10 src/XF/App.php(1931): XF\Mvc\Dispatcher->run() #11 src/XF.php(329): XF\App->run() #12 admin.php(13): XF::runApp('XF\\Admin\\App') #13 {main}

Here's another

[LIST] [*]ErrorException: Job XF:FileCheck: [E_WARNING] file_get_contents(/home2/x/public_html/src/vendor/league/flysystem/build/osx_install_composer.sh): failed to open stream: Permission denied [*]src/XF/Util/Hash.php:9 [/LIST]

[SIZE=5][B]Stack trace[/B][/SIZE] #0 [internal function]: XF::handlePhpError(2, 'file_get_conten...', '/home2/x/p...', 9, Array) #1 src/XF/Util/Hash.php(9): file_get_contents('/home2/x/p...') #2 src/XF/Job/FileCheck.php(169): XF\Util\Hash::hashTextFile('/home2/x/p...', 'sha256') #3 src/XF/Job/Manager.php(241): XF\Job\FileCheck->run(7.9999990463257) #4 src/XF/Job/Manager.php(187): XF\Job\Manager->runJobInternal(Array, 7.9999990463257) #5 src/XF/Job/Manager.php(76): XF\Job\Manager->runJobEntry(Array, 7.9999990463257) #6 job.php(14): XF\Job\Manager->runQueue(false, 8) #7 {main}


My PHP got automatically shifted to 5.6 somehow and after changing it back to 7.0 or 7.2 I get presented with an error 500
 
The original issue is related to file permissions.

You may need to chmod/chown files and directories, as required.

SELinux could also be involved.
 
Hey @Brogan

Thanks for the reply. Yes, I have already done that. I fixed the permissions and they were set to 000, I changed it to 644.
but now when I goto file check under tools, I get can start the check but after it starts it redirects me to a 404 page not found
 
Back
Top Bottom