Jur*_*son 5 php session symfony vagrant php-7
虽然普通用户和www-data都可以访问路径/mnt/my-proj/app/../var/sessions/dev,但我收到以下消息:
Warning: session_write_close(): Failed to write session data (user). Please verify that the current setting of session.save_path is correct (/mnt/op-accounting2/app/../var/sessions/dev)
Run Code Online (Sandbox Code Playgroud)
我只在dev中得到上面的消息,但不是在prod中. /mnt/my-proj/app/../var/sessions/dev和/mnt/my-proj/app/../var/sessions/prod有相同的权限:777.
上面的路径安装如下:
# mount -t vboxsf -o uid=1000,gid=33,umask=000 my-proj /mnt/my-proj;
Run Code Online (Sandbox Code Playgroud)
我究竟做错了什么?
我已阅读以下帖子,但找不到我的解决方案:
https://github.com/NewEraCracker/suhosin-patches/issues/3
我在Vagrant上的Windows 8.1 Enterprice(64Bit)和ubuntu-xenial 16.04上使用Vagrant 1.8.1.提供者是VirtualBox 5.0.20.设置大多是默认设置.使用具有完全访问权限的VirtualBox GUI共享上面的路径.
亲切的问候,
尤里
解决了!:-)
环境
save_path: "/var/lib/php/sessions"
Run Code Online (Sandbox Code Playgroud)
在/mnt/my-proj/app/config/config.yml中解决了问题。不需要对/etc/php/7.0/中的 ini 文件进行任何调整(这些文件仍然只有默认值)。
但我想知道为什么我没有在产品中收到该错误消息?