3

我在 godaddy 上安装了 cakephp 应用程序,但是出现了问题,我看到了这个错误,请任何人帮助我..脚本正常工作,但我无法使用用户控制器登录

   Warning (2): session_start() [function.session-start]: open(/var/chroot/home/content/37/7269737/tmp/sess_5fngsu7g8llj60a9075mkkgh07, O_RDWR) failed: No such file or directory (2) [ROOT/7269737/html/cake/libs/cake_session.php, line 587]

    Warning (2): session_start() [function.session-start]: Cannot send session cookie - headers already sent by (output started at /home/content/37/7269737/html/cake/libs/debugger.php:683) [ROOT/7269737/html/cake/libs/cake_session.php, line 587]

    Warning (2): session_start() [function.session-start]: Cannot send session cache limiter - headers already sent (output started at /home/content/37/7269737/html/cake/libs/debugger.php:683) [ROOT/7269737/html/cake/libs/cake_session.php, line 587]

    Warning (2): Cannot modify header information - headers already sent by (output started at /home/content/37/7269737/html/cake/libs/debugger.php:683) [ROOT/7269737/html/cake/libs/cake_session.php, line 588]


    Warning (2): Unknown: open(/var/chroot/home/content/37/7269737/tmp/sess_5fngsu7g8llj60a9075mkkgh07, O_RDWR) failed: No such file or directory (2) [Unknown, line ??]

    Warning (2): Unknown: Failed to write session data (files). Please verify that the current setting of session.
4

2 回答 2

4

您必须执行以下步骤

  1. 将写入权限设置为默认的 /tmp 文件夹
  2. 更改 php.ini 以指向您有权访问的目录而不是 /tmp
  3. 设置 Configure::write('Session.save', 'cake') 并将它们放在 cake app/tmp 中,您可以在其中明确管理权限。

为此,您必须更改config/core.php文件中的会话设置。有几种选择。默认是使用 php.ini 设置来保存会话。更多细节CakePHP 核心配置变量

于 2012-05-18T16:48:55.397 回答
1

这个错误的直接原因是您无法在目录中写入/var/chroot/home/content/37/7269737/tmp/

要么此文件夹不存在,请创建它。

或者它在那里,你需要给它0644权限级别。

希望这可以帮助!

于 2012-05-18T17:45:22.327 回答