>  기사  >  데이터 베이스  >  mysql报ERROR 2003错误的解决_MySQL

mysql报ERROR 2003错误的解决_MySQL

WBOY
WBOY원래의
2016-06-01 13:08:542891검색

在创建opensips数据库时,mysql报下列错误

root@opensips.clvn.com.cn:/usr/local/opensips/sbin# ./opensipsdbctl create
MySQL password for root:
INFO: test server charset
ERROR 2003 (HY000): Can't connect to MySQL server on '192.168.0.18' (111)
ERROR 2003 (HY000): Can't connect to MySQL server on '192.168.0.18' (111)
WARNING: Failed to get the available and used character sets

 

解决方法

 

root@opensips.clvn.com.cn# vim /etc/mysql/my.cnf


#bind-address           = 127.0.0.1
重新启动mysql

root@opensips.clvn.com.cn# service mysql restart
mysql stop/waiting
mysql start/running, process 24719

再次执行

root@opensips.clvn.com.cn:/usr/local/opensips/sbin# ./opensipsdbctl create
MySQL password for root:
INFO: test server charset
INFO: creating database opensips ...
INFO: Core OpenSIPS tables succesfully created.
Install presence related tables? (y/n): y 
INFO: creating presence tables into opensips ...
INFO: Presence tables succesfully created.
Install tables for imc cpl siptrace domainpolicy carrierroute userblacklist b2b registrant call_center? (y/n): y
INFO: creating extra tables into opensips ...
INFO: Extra tables succesfully created.

 

问题解决

성명:
본 글의 내용은 네티즌들의 자발적인 기여로 작성되었으며, 저작권은 원저작자에게 있습니다. 본 사이트는 이에 상응하는 법적 책임을 지지 않습니다. 표절이나 침해가 의심되는 콘텐츠를 발견한 경우 admin@php.cn으로 문의하세요.