NextCloud出现500内部服务器错误-打开settings/admin/serverinfo就提示500错误

731 浏览技术资料
0

NextCloud一进入到“系统”页面就出现500内部服务器错误,查看日志提示:

Exception: Call to undefined function OCA\ServerInfo\OperatingSystems\shell_exec() in file '/data/wwwroot/xx.wzfou.net/apps/serverinfo/lib/OperatingSystems/DefaultOs.php' line 248
/data/wwwroot/yun.wzfou.net/lib/private/AppFramework/App.php - line 172:
 OC\AppFramework\Http\Dispatcher->dispatch()
 /data/wwwroot/xxx.wzfou.net/lib/private/Route/Router.php - line 298:
 OC\AppFramework\App::main()
 /data/wwwroot/xxx.wzfou.net/lib/base.php - line 1047:
 OC\Route\Router->match()
 /data/wwwroot/xxx.wzfou.net/index.php - line 36:
 OC::handleRequest()

原来是php默认禁用shell_exec,将shell_exec这个函数解封即可:

打开php.ini,搜索disable_functions

把shell_exec删除即可,保存。

重启PHP。


分享到:
Qi 问的问题 2023年1月12日
添加评论
写下您的答案。

Login

Welcome! Login in to your account

Remember me Lost your password?

Don't have account. Register

Lost Password

Register