Ubuntu+django+apache下配置网页错误OperationalError: Unable to Open Database File 的解决方法
2018-05-17 23:08
821 查看
原因:你的django项目中没有对数据库的访问权限。 在Ubuntu下www-data是默认运行web服务的的用户/组,搭建web服务的文件夹/文件要设置成www-data的。
解决方法: cd .../my-app chgrp www-data databasedir chgrp www-data databasedir/mydb.db chmod g+w databasedir chmod g+w databasedir/mydb.db
解决方法: cd .../my-app chgrp www-data databasedir chgrp www-data databasedir/mydb.db chmod g+w databasedir chmod g+w databasedir/mydb.db
相关文章推荐
- 手把手教你:Ubuntu+django+apache下配置网页错误OperationalError: Unable to Open Database File 的解决方法
- Flask sqlite3.OperationalError: unable to open database file解决方法
- PHP PDO sqlite ,Unable to Open database file的解决方法
- android学习历程——“Unable to open log device '/dev/log/main': No such file or directory”错误解决方法
- 解决sqllite的'unable to open database file'错误
- Apache启动错误Permission denied: httpd: could not open error log file解决方法
- ERROR: Unable to open class file Permission denied错误修改方法
- Django-想说爱你真不容易--解决“Unable to open database file”(原创)
- Error:Failed to open zip file错误的解决方法
- Mysql启动错误:“InnoDB: Error: unable to create temporary file”的解决方法
- Android Studio更新出现错误:Error:Failed to open zip file解决方法
- sqlite3.OperationalError: unable to open database file 解决办法
- bitbake错误:sqlite3.OperationalError: unable to open database file
- 从C调用Python脚本unableto load the file system codec ImportError错误解决方法
- ubuntu 下git commit error insufficient permission for adding an object to repository database .git/objects错误 解决方法
- CLR has been unable to transition from COM context … for 60 seconds’ error. 此错误的解决方法
- 解决:Unable to open the physical file "…….ldf". Operating system error 5: "5(拒绝访问。)".
- 在win7 64上用npm安装phantomjs时出现Error: UNABLE_TO_VERIFY_LEAF_SIGNATURE错误的解决方法。
- Ubuntu 配置VNC时,出现“perl: warning: Falling back to the standard locale ("C").”等提示错误解决方法
- Django Ubuntu:Database returned an invalid value in QuerySet.dates(). 错误的解决方法