原创作品,允许转载,转载时请务必以超链接形式标明文章 原始出处 、作者信息和本声明。否则将追究法律责任。http://myunix.blog.51cto.com/191254/1704088

网站访问报

Database error
Error connecting to database: No such file or directory

2中解决办法:

1、ln -s /var/lib/mysql/mysql.sock /tmp/

2、vim /usr/local/php/etc/php.ini

mysqli.default_socket = /var/lib/mysql/mysql.sock

/etc/init.d/php-fpm restart

本文出自 “freeterman” 博客,请务必保留此出处http://myunix.blog.51cto.com/191254/1704088

Error connecting to database: No such file or directory的更多相关文章

  1. Windows下使用ssh-add报错 Error connecting to agent: No such file or directory

    Windows下使用ssh-add报错 Error connecting to agent: No such file or directory 环境信息 操作系统:windows 10 终端:Win ...

  2. nodejs:注册登录session出错以及连接Mongodb数据库时Error connecting to database解决方案

    (1)nodejs:注册登录session出错 解决办法: 在app.js 中将var MongoStore =  require(connect-mongo')改为var MongoStore =  ...

  3. fatal error: openssl/sha.h: No such file or directory 解决方案

    出现这个或者fatal error: openssl/名单.h: No such file or directory.都是没有安装libssl-dev- libssl-dev包含libraries, ...

  4. 误mlogc.c:32:23: error: curl/curl.h: No such file or directory

    出现以下错误: mlogc.c:32:23: error: curl/curl.h: No such file or directory mlogc.c:1091: error: expected ' ...

  5. lua.c:80:31: fatal error: readline/readline.h: No such file or directory

    make linuxcd src && make linuxmake[1]: Entering directory `/root/lua/lua-5.3.2/src'make all ...

  6. 编译内核时出现drivers/mfd/mxc-hdmi-core.c:36:24: fatal error: mach/clock.h: No such file or directory

    在学习恩智浦IMX6D开发板时,编译内核出现 drivers/mfd/mxc-hdmi-core.c::: fatal error: mach/clock.h: No such file or dir ...

  7. ubuntu16.04 编译出错:fatal error: SDL/SDL.h: No such file or directory

    在ubuntu 16.04编译神经网络代码时候,遇到了这样一种错误? fatal error: SDL/SDL.h: No such file or directory 原因是SDL库没有安装,根据你 ...

  8. 【Redis】编译错误zmalloc.h:50:31: fatal error: jemalloc/jemalloc.h: No such file or directory

    [Redis]编译错误zmalloc.h:50:31: fatal error: jemalloc/jemalloc.h: No such file or directory 在安装redis进行编译 ...

  9. Error launching remote program: No such file or directory

    iPhone真机调试报如下错误时,关掉Xcode,重新启动就可以了,注意是关掉Xcode,彻底关掉.Error launching remote program: No such file or di ...

随机推荐

  1. Tree CodeForces -932D

    错误记录:如下注释语句 #include<cstdio> #include<algorithm> using namespace std; typedef long long ...

  2. Java_JDBC连接数据库_使用读取配置文件的方式

    package com.homewoek3_4.dao; import java.io.IOException; import java.io.InputStream; import java.sql ...

  3. Windows远程桌面连接复制文件失败或非常慢

    环境搭建过程中经常会遇到需要将文件从本机传到云服务器或者企业内部服务器上的场景,此时如果文件过大的话要传个半天或者直接告诉你复制失败,让人好生无奈 ~ ~.   windows环境下,可以将本地磁盘映 ...

  4. mvc的生命周期

    尽管每次都是从msdn里复制粘贴,但是还是有必要的,加深对mvc的理解和官方的表述. 了解 MVC 应用程序执行过程 发送给基于 ASP.NET MVC 的 Web 应用程序的请求首先通过 UrlRo ...

  5. 开发小Tips

    Kotlin语言篇: 1.抽象类的定义 abstract class Person(var name : String, var age : Int) : Any() { abstract var a ...

  6. 掌握Spark机器学习库-07-最小二乘法

    1)最小化残差平方和 2)原理,推导过程 3)例子

  7. EasyUI edatagrid插件使用小计

    html片段 <table id="menuview" style="width:100%"> <thead> <tr> & ...

  8. restful api的简单理解

    百度百科的描述:一种软件架构风格,设计风格而不是标准,只是提供了一组设计原则和约束条件.它主要用于客户端和服务器交互类的软件.基于这个风格设计的软件可以更简洁,更有层次,更易于实现缓存等机制. RES ...

  9. ie11 突然不能加载外部css 很神奇 头部改为 <!DOCTYPE> <html>

    <!DOCTYPE html> <html> 改为 <!DOCTYPE> <html>   OK了

  10. php基础排序算法

    1.冒泡排序 $arr = array(12,34,57,42,165.4,73,51); function bubbling_sort($array) { $cou = count($array); ...