gpt4 book ai didi

linux - 在 CentOS 6 (Linux) 上移动 Laravel 5.4 项目 - 权限被拒绝问题

转载 作者:太空宇宙 更新时间:2023-11-04 12:26:31 25 4
gpt4 key购买 nike

我之前将 laravel 项目转移到共享主机上,但没有转移到大学 CentOS 服务器上。

我已经将 laravel 公共(public)文件夹文件放在 public_html 中,并将所有其他 laravel 项目文件放在 blog 文件夹下。

Root
-blog
-entire project files
-public_html
-all the public files

我在 index.php 中更改了 2 行

require __DIR__.'/../blog/bootstrap/autoload.php';
$app = require_once __DIR__.'/../blog/bootstrap/app.php';

如你所见,我添加了/blog

我可以访问 SSH shell,下面是错误列表:

PHP Warning:  include(/home/cs/username/blog/vendor/composer/../../app/Http/Kernel.php): failed to open stream: Permission denied in /home/cs/username/blog/vendor/composer/ClassLoader.php on line 444
[Thu Jun 08 10:43:58 2017] [error] [client 137.195.14.30] PHP Warning: include(): Failed opening '/home/cs/username/blog/vendor/composer/../../app/Http/Kernel.php' for inclusion (include_path='.:/usr/share/pear:/usr/share/php') in /home/cs/username/blog/vendor/composer/ClassLoader.php on line 444
[Thu Jun 08 10:43:58 2017] [error] [client 137.195.14.30] PHP Fatal error: Uncaught exception 'ReflectionException' with message 'Class App\\Http\\Kernel does not exist' in /home/cs/username/blog/vendor/laravel/framework/src/Illuminate/Container/Container.php:729\nStack trace:\n#0 /home/cs/username/blog/vendor/laravel/framework/src/Illuminate/Container/Container.php(729): ReflectionClass->__construct('App\\\\Http\\\\Kernel')\n#1 /home/cs/username/blog/vendor/laravel/framework/src/Illuminate/Container/Container.php(608): Illuminate\\Container\\Container->build('App\\\\Http\\\\Kernel')\n#2 /home/cs/username/blog/vendor/laravel/framework/src/Illuminate/Container/Container.php(564): Illuminate\\Container\\Container->resolve('App\\\\Http\\\\Kernel', Array)\n#3 /home/cs/username/blog/vendor/laravel/framework/src/Illuminate/Foundation/Application.php(709): Illuminate\\Container\\Container->makeWith('App\\\\Http\\\\Kernel', Array)\n#4 /home/cs/username/blog/vendor/laravel/framework/src/Illuminate/Container/Container.php(248): Illuminate\\Foundation\\Application->makeWith('App\\\\Http\\\\Kernel', Array)\n#5 /home/cs/username/blog/vendor/lara in /home/cs/username/blog/vendor/laravel/framework/src/Illuminate/Container/Container.php on line 729
[Thu Jun 08 11:54:48 2017] [error] [client 92.98.49.227] PHP Warning: include(/home/cs/username/blog/vendor/composer/../../app/Http/Kernel.php): failed to open stream: Permission denied in /home/cs/username/blog/vendor/composer/ClassLoader.php on line 444
[Thu Jun 08 11:54:48 2017] [error] [client 92.98.49.227] PHP Warning: include(): Failed opening '/home/cs/username/blog/vendor/composer/../../app/Http/Kernel.php' for inclusion (include_path='.:/usr/share/pear:/usr/share/php') in /home/cs/username/blog/vendor/composer/ClassLoader.php on line 444
[Thu Jun 08 11:54:48 2017] [error] [client 92.98.49.227] PHP Fatal error: Uncaught exception 'ReflectionException' with message 'Class App\\Http\\Kernel does not exist' in /home/cs/username/blog/vendor/laravel/framework/src/Illuminate/Container/Container.php:729\nStack trace:\n#0 /home/cs/username/blog/vendor/laravel/framework/src/Illuminate/Container/Container.php(729): ReflectionClass->__construct('App\\\\Http\\\\Kernel')\n#1 /home/cs/username/blog/vendor/laravel/framework/src/Illuminate/Container/Container.php(608): Illuminate\\Container\\Container->build('App\\\\Http\\\\Kernel')\n#2 /home/cs/username/blog/vendor/laravel/framework/src/Illuminate/Container/Container.php(564): Illuminate\\Container\\Container->resolve('App\\\\Http\\\\Kernel', Array)\n#3 /home/cs/username/blog/vendor/laravel/framework/src/Illuminate/Foundation/Application.php(709): Illuminate\\Container\\Container->makeWith('App\\\\Http\\\\Kernel', Array)\n#4 /home/cs/username/blog/vendor/laravel/framework/src/Illuminate/Container/Container.php(248): Illuminate\\Foundation\\Application->makeWith('App\\\\Http\\\\Kernel', Array)\n#5 /home/cs/username/blog/vendor/lara in /home/cs/username/blog/vendor/laravel/framework/src/Illuminate/Container/Container.php on line 729
[Thu Jun 08 11:58:06 2017] [error] [client 92.98.49.227] PHP Warning: require(/home/cs/username/public_html/../bootstrap/autoload.php): failed to open stream: No such file or directory in /home/cs/username/public_html/index.php on line 22
[Thu Jun 08 11:58:06 2017] [error] [client 92.98.49.227] PHP Fatal error: require(): Failed opening required '/home/cs/username/public_html/../bootstrap/autoload.php' (include_path='.:/usr/share/pear:/usr/share/php') in /home/cs/username/public_html/index.php on line 22
[Thu Jun 08 11:58:09 2017] [error] [client 92.98.49.227] PHP Warning: require(/home/cs/username/public_html/../bootstrap/autoload.php): failed to open stream: No such file or directory in /home/cs/username/public_html/index.php on line 22
[Thu Jun 08 11:58:09 2017] [error] [client 92.98.49.227] PHP Fatal error: require(): Failed opening required '/home/cs/username/public_html/../bootstrap/autoload.php' (include_path='.:/usr/share/pear:/usr/share/php') in /home/cs/username/public_html/index.php on line 22
[Thu Jun 08 11:58:12 2017] [error] [client 92.98.49.227] PHP Warning: require(/home/cs/username/public_html/../bootstrap/autoload.php): failed to open stream: No such file or directory in /home/cs/username/public_html/index.php on line 22
[Thu Jun 08 11:58:12 2017] [error] [client 92.98.49.227] PHP Fatal error: require(): Failed opening required '/home/cs/username/public_html/../bootstrap/autoload.php' (include_path='.:/usr/share/pear:/usr/share/php') in /home/cs/username/public_html/index.php on line 22
[Thu Jun 08 11:58:14 2017] [error] [client 92.98.49.227] PHP Warning: require(/home/cs/username/public_html/../bootstrap/autoload.php): failed to open stream: No such file or directory in /home/cs/username/public_html/index.php on line 22
[Thu Jun 08 11:58:14 2017] [error] [client 92.98.49.227] PHP Fatal error: require(): Failed opening required '/home/cs/username/public_html/../bootstrap/autoload.php' (include_path='.:/usr/share/pear:/usr/share/php') in /home/cs/username/public_html/index.php on line 22
[Thu Jun 08 12:05:35 2017] [error] [client 92.98.49.227] PHP Warning: include(/home/cs/username/public_html/vendor/composer/../../app/Http/Kernel.php): failed to open stream: Permission denied in /home/cs/username/public_html/vendor/composer/ClassLoader.php on line 444
[Thu Jun 08 12:05:35 2017] [error] [client 92.98.49.227] PHP Warning: include(): Failed opening '/home/cs/username/public_html/vendor/composer/../../app/Http/Kernel.php' for inclusion (include_path='.:/usr/share/pear:/usr/share/php') in /home/cs/username/public_html/vendor/composer/ClassLoader.php on line 444
[Thu Jun 08 12:05:35 2017] [error] [client 92.98.49.227] PHP Fatal error: Uncaught exception 'ReflectionException' with message 'Class App\\Http\\Kernel does not exist' in /home/cs/username/public_html/vendor/laravel/framework/src/Illuminate/Container/Container.php:729\nStack trace:\n#0 /home/cs/username/public_html/vendor/laravel/framework/src/Illuminate/Container/Container.php(729): ReflectionClass->__construct('App\\\\Http\\\\Kernel')\n#1 /home/cs/username/public_html/vendor/laravel/framework/src/Illuminate/Container/Container.php(608): Illuminate\\Container\\Container->build('App\\\\Http\\\\Kernel')\n#2 /home/cs/username/public_html/vendor/laravel/framework/src/Illuminate/Container/Container.php(564): Illuminate\\Container\\Container->resolve('App\\\\Http\\\\Kernel', Array)\n#3 /home/cs/username/public_html/vendor/laravel/framework/src/Illuminate/Foundation/Application.php(709): Illuminate\\Container\\Container->makeWith('App\\\\Http\\\\Kernel', Array)\n#4 /home/cs/username/public_html/vendor/laravel/framework/src/Illuminate/Container/Container.php(248): Illuminate\\Foundation\\Application->makeWith('App\\\\Http\\\\Kernel', in /home/cs/username/public_html/vendor/laravel/framework/src/Illuminate/Container/Container.php on line 729
[Thu Jun 08 12:05:38 2017] [error] [client 92.98.49.227] PHP Warning: include(/home/cs/username/public_html/vendor/composer/../../app/Http/Kernel.php): failed to open stream: Permission denied in /home/cs/username/public_html/vendor/composer/ClassLoader.php on line 444
[Thu Jun 08 12:05:38 2017] [error] [client 92.98.49.227] PHP Warning: include(): Failed opening '/home/cs/username/public_html/vendor/composer/../../app/Http/Kernel.php' for inclusion (include_path='.:/usr/share/pear:/usr/share/php') in /home/cs/username/public_html/vendor/composer/ClassLoader.php on line 444
[Thu Jun 08 12:05:38 2017] [error] [client 92.98.49.227] PHP Fatal error: Uncaught exception 'ReflectionException' with message 'Class App\\Http\\Kernel does not exist' in /home/cs/username/public_html/vendor/laravel/framework/src/Illuminate/Container/Container.php:729\nStack trace:\n#0 /home/cs/username/public_html/vendor/laravel/framework/src/Illuminate/Container/Container.php(729): ReflectionClass->__construct('App\\\\Http\\\\Kernel')\n#1 /home/cs/username/public_html/vendor/laravel/framework/src/Illuminate/Container/Container.php(608): Illuminate\\Container\\Container->build('App\\\\Http\\\\Kernel')\n#2 /home/cs/username/public_html/vendor/laravel/framework/src/Illuminate/Container/Container.php(564): Illuminate\\Container\\Container->resolve('App\\\\Http\\\\Kernel', Array)\n#3 /home/cs/username/public_html/vendor/laravel/framework/src/Illuminate/Foundation/Application.php(709): Illuminate\\Container\\Container->makeWith('App\\\\Http\\\\Kernel', Array)\n#4 /home/cs/username/public_html/vendor/laravel/framework/src/Illuminate/Container/Container.php(248): Illuminate\\Foundation\\Application->makeWith('App\\\\Http\\\\Kernel', in /home/cs/username/public_html/vendor/laravel/framework/src/Illuminate/Container/Container.php on line 729
[Thu Jun 08 12:05:46 2017] [error] [client 92.98.49.227] PHP Warning: include(/home/cs/username/public_html/vendor/composer/../../app/Http/Kernel.php): failed to open stream: Permission denied in /home/cs/username/public_html/vendor/composer/ClassLoader.php on line 444, referer: http://www2.macs.hw.ac.uk/~mf156/
[Thu Jun 08 12:05:46 2017] [error] [client 92.98.49.227] PHP Warning: include(): Failed opening '/home/cs/username/public_html/vendor/composer/../../app/Http/Kernel.php' for inclusion (include_path='.:/usr/share/pear:/usr/share/php') in /home/cs/username/public_html/vendor/composer/ClassLoader.php on line 444, referer: http://www2.macs.hw.ac.uk/~mf156/
[Thu Jun 08 12:05:46 2017] [error] [client 92.98.49.227] PHP Fatal error: Uncaught exception 'ReflectionException' with message 'Class App\\Http\\Kernel does not exist' in /home/cs/username/public_html/vendor/laravel/framework/src/Illuminate/Container/Container.php:729\nStack trace:\n#0 /home/cs/username/public_html/vendor/laravel/framework/src/Illuminate/Container/Container.php(729): ReflectionClass->__construct('App\\\\Http\\\\Kernel')\n#1 /home/cs/username/public_html/vendor/laravel/framework/src/Illuminate/Container/Container.php(608): Illuminate\\Container\\Container->build('App\\\\Http\\\\Kernel')\n#2 /home/cs/username/public_html/vendor/laravel/framework/src/Illuminate/Container/Container.php(564): Illuminate\\Container\\Container->resolve('App\\\\Http\\\\Kernel', Array)\n#3 /home/cs/username/public_html/vendor/laravel/framework/src/Illuminate/Foundation/Application.php(709): Illuminate\\Container\\Container->makeWith('App\\\\Http\\\\Kernel', Array)\n#4 /home/cs/username/public_html/vendor/laravel/framework/src/Illuminate/Container/Container.php(248): Illuminate\\Foundation\\Application->makeWith('App\\\\Http\\\\Kernel', in /home/cs/username/public_html/vendor/laravel/framework/src/Illuminate/Container/Container.php on line 729, referer: http://www2.macs.hw.ac.uk/~mf156/
[Thu Jun 08 12:07:33 2017] [error] [client 92.98.49.227] PHP Warning: include(/home/cs/username/public_html/vendor/composer/../../app/Http/Kernel.php): failed to open stream: Permission denied in /home/cs/username/public_html/vendor/composer/ClassLoader.php on line 444
[Thu Jun 08 12:07:33 2017] [error] [client 92.98.49.227] PHP Warning: include(): Failed opening '/home/cs/username/public_html/vendor/composer/../../app/Http/Kernel.php' for inclusion (include_path='.:/usr/share/pear:/usr/share/php') in /home/cs/username/public_html/vendor/composer/ClassLoader.php on line 444
[Thu Jun 08 12:07:33 2017] [error] [client 92.98.49.227] PHP Fatal error: Uncaught exception 'ReflectionException' with message 'Class App\\Http\\Kernel does not exist' in /home/cs/username/public_html/vendor/laravel/framework/src/Illuminate/Container/Container.php:729\nStack trace:\n#0 /home/cs/username/public_html/vendor/laravel/framework/src/Illuminate/Container/Container.php(729): ReflectionClass->__construct('App\\\\Http\\\\Kernel')\n#1 /home/cs/username/public_html/vendor/laravel/framework/src/Illuminate/Container/Container.php(608): Illuminate\\Container\\Container->build('App\\\\Http\\\\Kernel')\n#2 /home/cs/username/public_html/vendor/laravel/framework/src/Illuminate/Container/Container.php(564): Illuminate\\Container\\Container->resolve('App\\\\Http\\\\Kernel', Array)\n#3 /home/cs/username/public_html/vendor/laravel/framework/src/Illuminate/Foundation/Application.php(709): Illuminate\\Container\\Container->makeWith('App\\\\Http\\\\Kernel', Array)\n#4 /home/cs/username/public_html/vendor/laravel/framework/src/Illuminate/Container/Container.php(248): Illuminate\\Foundation\\Application->makeWith('App\\\\Http\\\\Kernel', in /home/cs/username/public_html/vendor/laravel/framework/src/Illuminate/Container/Container.php on line 729
[Thu Jun 08 12:55:51 2017] [error] [client 92.98.49.227] PHP Warning: include(/home/cs/username/public_html/vendor/composer/../../app/Http/Kernel.php): failed to open stream: Permission denied in /home/cs/username/public_html/vendor/composer/ClassLoader.php on line 444
[Thu Jun 08 12:55:51 2017] [error] [client 92.98.49.227] PHP Warning: include(): Failed opening '/home/cs/username/public_html/vendor/composer/../../app/Http/Kernel.php' for inclusion (include_path='.:/usr/share/pear:/usr/share/php') in /home/cs/username/public_html/vendor/composer/ClassLoader.php on line 444
[Thu Jun 08 12:55:51 2017] [error] [client 92.98.49.227] PHP Fatal error: Uncaught exception 'ReflectionException' with message 'Class App\\Http\\Kernel does not exist' in /home/cs/username/public_html/vendor/laravel/framework/src/Illuminate/Container/Container.php:729\nStack trace:\n#0 /home/cs/username/public_html/vendor/laravel/framework/src/Illuminate/Container/Container.php(729): ReflectionClass->__construct('App\\\\Http\\\\Kernel')\n#1 /home/cs/username/public_html/vendor/laravel/framework/src/Illuminate/Container/Container.php(608): Illuminate\\Container\\Container->build('App\\\\Http\\\\Kernel')\n#2 /home/cs/username/public_html/vendor/laravel/framework/src/Illuminate/Container/Container.php(564): Illuminate\\Container\\Container->resolve('App\\\\Http\\\\Kernel', Array)\n#3 /home/cs/username/public_html/vendor/laravel/framework/src/Illuminate/Foundation/Application.php(709): Illuminate\\Container\\Container->makeWith('App\\\\Http\\\\Kernel', Array)\n#4 /home/cs/username/public_html/vendor/laravel/framework/src/Illuminate/Container/Container.php(248): Illuminate\\Foundation\\Application->makeWith('App\\\\Http\\\\Kernel', in /home/cs/username/public_html/vendor/laravel/framework/src/Illuminate/Container/Container.php on line 729
[Thu Jun 08 12:56:05 2017] [error] [client 92.98.49.227] PHP Warning: include(/home/cs/username/public_html/vendor/composer/../../app/Http/Kernel.php): failed to open stream: Permission denied in /home/cs/username/public_html/vendor/composer/ClassLoader.php on line 444, referer: http://www2.macs.hw.ac.uk/~mf156/
[Thu Jun 08 12:56:05 2017] [error] [client 92.98.49.227] PHP Warning: include(): Failed opening '/home/cs/username/public_html/vendor/composer/../../app/Http/Kernel.php' for inclusion (include_path='.:/usr/share/pear:/usr/share/php') in /home/cs/username/public_html/vendor/composer/ClassLoader.php on line 444, referer: http://www2.macs.hw.ac.uk/~mf156/
[Thu Jun 08 12:56:05 2017] [error] [client 92.98.49.227] PHP Fatal error: Uncaught exception 'ReflectionException' with message 'Class App\\Http\\Kernel does not exist' in /home/cs/username/public_html/vendor/laravel/framework/src/Illuminate/Container/Container.php:729\nStack trace:\n#0 /home/cs/username/public_html/vendor/laravel/framework/src/Illuminate/Container/Container.php(729): ReflectionClass->__construct('App\\\\Http\\\\Kernel')\n#1 /home/cs/username/public_html/vendor/laravel/framework/src/Illuminate/Container/Container.php(608): Illuminate\\Container\\Container->build('App\\\\Http\\\\Kernel')\n#2 /home/cs/username/public_html/vendor/laravel/framework/src/Illuminate/Container/Container.php(564): Illuminate\\Container\\Container->resolve('App\\\\Http\\\\Kernel', Array)\n#3 /home/cs/username/public_html/vendor/laravel/framework/src/Illuminate/Foundation/Application.php(709): Illuminate\\Container\\Container->makeWith('App\\\\Http\\\\Kernel', Array)\n#4 /home/cs/username/public_html/vendor/laravel/framework/src/Illuminate/Container/Container.php(248): Illuminate\\Foundation\\Application->makeWith('App\\\\Http\\\\Kernel', in /home/cs/username/public_html/vendor/laravel/framework/src/Illuminate/Container/Container.php on line 729, referer: http://www2.macs.hw.ac.uk/~mf156/
[Thu Jun 08 12:56:11 2017] [crit] [client 92.98.49.227] (13)Permission denied: /home/cs/username/public_html/app/Http/.htaccess pcfg_openfile: unable to check htaccess file, ensure it is readable, referer: http://www2.macs.hw.ac.uk/~mf156/
[Thu Jun 08 13:13:58 2017] [alert] [client 92.98.49.227] /home/cs/username/public_html/public/.htaccess: Options not allowed here
[Thu Jun 08 13:14:09 2017] [alert] [client 92.98.49.227] /home/cs/username/public_html/public/.htaccess: Options not allowed here
[Thu Jun 08 13:14:14 2017] [alert] [client 92.98.49.227] /home/cs/username/public_html/public/.htaccess: Options not allowed here
[Thu Jun 08 13:21:42 2017] [alert] [client 92.98.49.227] /home/cs/username/public_html/public/.htaccess: Options not allowed here
[Thu Jun 08 13:21:52 2017] [alert] [client 92.98.49.227] /home/cs/username/public_html/public/.htaccess: Options not allowed here
[Thu Jun 08 13:21:54 2017] [alert] [client 92.98.49.227] /home/cs/username/public_html/public/.htaccess: Options not allowed here
[Thu Jun 08 13:21:55 2017] [alert] [client 92.98.49.227] /home/cs/username/public_html/public/.htaccess: Options not allowed here
[Thu Jun 08 13:21:58 2017] [alert] [client 92.98.49.227] /home/cs/username/public_html/public/.htaccess: Options not allowed here
[Thu Jun 08 13:22:01 2017] [alert] [client 92.98.49.227] /home/cs/username/public_html/public/.htaccess: Options not allowed here
[Thu Jun 08 13:22:20 2017] [error] [client 92.98.49.227] PHP Warning: include(/home/cs/username/public_html/vendor/composer/../../app/Http/Kernel.php): failed to open stream: Permission denied in /home/cs/username/public_html/vendor/composer/ClassLoader.php on line 444
[Thu Jun 08 13:22:20 2017] [error] [client 92.98.49.227] PHP Warning: include(): Failed opening '/home/cs/username/public_html/vendor/composer/../../app/Http/Kernel.php' for inclusion (include_path='.:/usr/share/pear:/usr/share/php') in /home/cs/username/public_html/vendor/composer/ClassLoader.php on line 444
[Thu Jun 08 13:22:20 2017] [error] [client 92.98.49.227] PHP Fatal error: Uncaught exception 'ReflectionException' with message 'Class App\\Http\\Kernel does not exist' in /home/cs/username/public_html/vendor/laravel/framework/src/Illuminate/Container/Container.php:729\nStack trace:\n#0 /home/cs/username/public_html/vendor/laravel/framework/src/Illuminate/Container/Container.php(729): ReflectionClass->__construct('App\\\\Http\\\\Kernel')\n#1 /home/cs/username/public_html/vendor/laravel/framework/src/Illuminate/Container/Container.php(608): Illuminate\\Container\\Container->build('App\\\\Http\\\\Kernel')\n#2 /home/cs/username/public_html/vendor/laravel/framework/src/Illuminate/Container/Container.php(564): Illuminate\\Container\\Container->resolve('App\\\\Http\\\\Kernel', Array)\n#3 /home/cs/username/public_html/vendor/laravel/framework/src/Illuminate/Foundation/Application.php(709): Illuminate\\Container\\Container->makeWith('App\\\\Http\\\\Kernel', Array)\n#4 /home/cs/username/public_html/vendor/laravel/framework/src/Illuminate/Container/Container.php(248): Illuminate\\Foundation\\Application->makeWith('App\\\\Http\\\\Kernel', in /home/cs/username/public_html/vendor/laravel/framework/src/Illuminate/Container/Container.php on line 729
[Thu Jun 08 13:29:56 2017] [error] [client 92.98.49.227] PHP Fatal error: Uncaught exception 'ReflectionException' with message 'Class App\\Http\\Kernel does not exist' in /home/cs/username/public_html/vendor/laravel/framework/src/Illuminate/Container/Container.php:729\nStack trace:\n#0 /home/cs/username/public_html/vendor/laravel/framework/src/Illuminate/Container/Container.php(729): ReflectionClass->__construct('App\\\\Http\\\\Kernel')\n#1 /home/cs/username/public_html/vendor/laravel/framework/src/Illuminate/Container/Container.php(608): Illuminate\\Container\\Container->build('App\\\\Http\\\\Kernel')\n#2 /home/cs/username/public_html/vendor/laravel/framework/src/Illuminate/Container/Container.php(564): Illuminate\\Container\\Container->resolve('App\\\\Http\\\\Kernel', Array)\n#3 /home/cs/username/public_html/vendor/laravel/framework/src/Illuminate/Foundation/Application.php(709): Illuminate\\Container\\Container->makeWith('App\\\\Http\\\\Kernel', Array)\n#4 /home/cs/username/public_html/vendor/laravel/framework/src/Illuminate/Container/Container.php(248): Illuminate\\Foundation\\Application->makeWith('App\\\\Http\\\\Kernel', in /home/cs/username/public_html/vendor/laravel/framework/src/Illuminate/Container/Container.php on line 729, referer: http://www2.macs.hw.ac.uk/~mf156/
[Thu Jun 08 13:35:34 2017] [error] [client 92.98.49.227] PHP Warning: include(/home/cs/username/blog/vendor/composer/../../app/Http/Kernel.php): failed to open stream: Permission denied in /home/cs/username/blog/vendor/composer/ClassLoader.php on line 444
[Thu Jun 08 13:35:34 2017] [error] [client 92.98.49.227] PHP Warning: include(): Failed opening '/home/cs/username/blog/vendor/composer/../../app/Http/Kernel.php' for inclusion (include_path='.:/usr/share/pear:/usr/share/php') in /home/cs/username/blog/vendor/composer/ClassLoader.php on line 444
[Thu Jun 08 13:35:34 2017] [error] [client 92.98.49.227] PHP Fatal error: Uncaught exception 'ReflectionException' with message 'Class App\\Http\\Kernel does not exist' in /home/cs/username/blog/vendor/laravel/framework/src/Illuminate/Container/Container.php:729\nStack trace:\n#0 /home/cs/username/blog/vendor/laravel/framework/src/Illuminate/Container/Container.php(729): ReflectionClass->__construct('App\\\\Http\\\\Kernel')\n#1 /home/cs/username/blog/vendor/laravel/framework/src/Illuminate/Container/Container.php(608): Illuminate\\Container\\Container->build('App\\\\Http\\\\Kernel')\n#2 /home/cs/username/blog/vendor/laravel/framework/src/Illuminate/Container/Container.php(564): Illuminate\\Container\\Container->resolve('App\\\\Http\\\\Kernel', Array)\n#3 /home/cs/username/blog/vendor/laravel/framework/src/Illuminate/Foundation/Application.php(709): Illuminate\\Container\\Container->makeWith('App\\\\Http\\\\Kernel', Array)\n#4 /home/cs/username/blog/vendor/laravel/framework/src/Illuminate/Container/Container.php(248): Illuminate\\Foundation\\Application->makeWith('App\\\\Http\\\\Kernel', Array)\n#5 /home/cs/username/blog/vendor/lara in /home/cs/username/blog/vendor/laravel/framework/src/Illuminate/Container/Container.php on line 729
[Thu Jun 08 13:35:40 2017] [error] [client 92.98.49.227] File does not exist: /home/cs/username/public_html/public
[Thu Jun 08 13:35:45 2017] [error] [client 92.98.49.227] PHP Warning: include(/home/cs/username/blog/vendor/composer/../../app/Http/Kernel.php): failed to open stream: Permission denied in /home/cs/username/blog/vendor/composer/ClassLoader.php on line 444
[Thu Jun 08 13:35:45 2017] [error] [client 92.98.49.227] PHP Warning: include(): Failed opening '/home/cs/username/blog/vendor/composer/../../app/Http/Kernel.php' for inclusion (include_path='.:/usr/share/pear:/usr/share/php') in /home/cs/username/blog/vendor/composer/ClassLoader.php on line 444
[Thu Jun 08 13:35:45 2017] [error] [client 92.98.49.227] PHP Fatal error: Uncaught exception 'ReflectionException' with message 'Class App\\Http\\Kernel does not exist' in /home/cs/username/blog/vendor/laravel/framework/src/Illuminate/Container/Container.php:729\nStack trace:\n#0 /home/cs/username/blog/vendor/laravel/framework/src/Illuminate/Container/Container.php(729): ReflectionClass->__construct('App\\\\Http\\\\Kernel')\n#1 /home/cs/username/blog/vendor/laravel/framework/src/Illuminate/Container/Container.php(608): Illuminate\\Container\\Container->build('App\\\\Http\\\\Kernel')\n#2 /home/cs/username/blog/vendor/laravel/framework/src/Illuminate/Container/Container.php(564): Illuminate\\Container\\Container->resolve('App\\\\Http\\\\Kernel', Array)\n#3 /home/cs/username/blog/vendor/laravel/framework/src/Illuminate/Foundation/Application.php(709): Illuminate\\Container\\Container->makeWith('App\\\\Http\\\\Kernel', Array)\n#4 /home/cs/username/blog/vendor/laravel/framework/src/Illuminate/Container/Container.php(248): Illuminate\\Foundation\\Application->makeWith('App\\\\Http\\\\Kernel', Array)\n#5 /home/cs/username/blog/vendor/lara in /home/cs/username/blog/vendor/laravel/framework/src/Illuminate/Container/Container.php on line 729
[Thu Jun 08 13:36:48 2017] [error] [client 92.98.49.227] PHP Warning: include(/home/cs/username/blog/vendor/composer/../../app/Http/Kernel.php): failed to open stream: Permission denied in /home/cs/username/blog/vendor/composer/ClassLoader.php on line 444
[Thu Jun 08 13:36:48 2017] [error] [client 92.98.49.227] PHP Warning: include(): Failed opening '/home/cs/username/blog/vendor/composer/../../app/Http/Kernel.php' for inclusion (include_path='.:/usr/share/pear:/usr/share/php') in /home/cs/username/blog/vendor/composer/ClassLoader.php on line 444
[Thu Jun 08 13:36:48 2017] [error] [client 92.98.49.227] PHP Fatal error: Uncaught exception 'ReflectionException' with message 'Class App\\Http\\Kernel does not exist' in /home/cs/username/blog/vendor/laravel/framework/src/Illuminate/Container/Container.php:729\nStack trace:\n#0 /home/cs/username/blog/vendor/laravel/framework/src/Illuminate/Container/Container.php(729): ReflectionClass->__construct('App\\\\Http\\\\Kernel')\n#1 /home/cs/username/blog/vendor/laravel/framework/src/Illuminate/Container/Container.php(608): Illuminate\\Container\\Container->build('App\\\\Http\\\\Kernel')\n#2 /home/cs/username/blog/vendor/laravel/framework/src/Illuminate/Container/Container.php(564): Illuminate\\Container\\Container->resolve('App\\\\Http\\\\Kernel', Array)\n#3 /home/cs/username/blog/vendor/laravel/framework/src/Illuminate/Foundation/Application.php(709): Illuminate\\Container\\Container->makeWith('App\\\\Http\\\\Kernel', Array)\n#4 /home/cs/username/blog/vendor/laravel/framework/src/Illuminate/Container/Container.php(248): Illuminate\\Foundation\\Application->makeWith('App\\\\Http\\\\Kernel', Array)\n#5 /home/cs/username/blog/vendor/lara in /home/cs/username/blog/vendor/laravel/framework/src/Illuminate/Container/Container.php on line 729

最佳答案

如果 public_html/是您的网络根目录,那么您可能希望将所有 Laravel 文件放在网络根目录中。 Laravel 应该知道如何使用它自己的公用文件夹。您不必更改自动加载路径。

对于其他重要的 Laravel 目录的权限,请阅读:

"目录权限

在安装 Laravel 之后,你可能需要配置一些权限。 storage 和 bootstrap/cache 目录中的目录应该可以被你的 web 服务器写入,否则 Laravel 将不会运行。如果您使用的是 Homestead 虚拟机,则应该已经设置了这些权限。”

关于linux - 在 CentOS 6 (Linux) 上移动 Laravel 5.4 项目 - 权限被拒绝问题,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/44436459/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com