首页 > 编程知识 正文

低版本jdbc连接高版本oracle,数据库路径怎么改

时间:2023-05-04 11:32:17 阅读:170044 作者:3273

ihaveinstalledmysqlthroughbinaryinstallationandfollowedbelowsteps

3358 dev.MySQL.com/doc/ref man/5.0/en/binary-installation.html

rightnowsockfilesarecraetedon/tmp/MySQL.sockwhenmysqlserviceisstarted。

iwanttoknowwhichconfigurationfilesneedtobeeditedtochangethepathofmysql.sock

itriedthefollowingstepstochangemysql.sockpathfrom/tmp/MySQL.sockto/var/lib/MySQL/MySQL.sock

1.itriedtoentersocketpathin/etc/my.cn f

socket=/var/lib/MySQL/MySQL.sock

2./etc/init.d/mysql

basedir=/var/lib/mysql

datadir=/var/lib/mysql/data

socket=/var/lib/MySQL/MySQL.sock

Can anybody help me to fix this issue。

解决方案

settingthesevariablesinmy.cnfshouldworkjustfine (tested locally,Ubuntu 10.10 )。

datadir=/var/lib/mysql

socket=/var/lib/MySQL/MySQL.sock

justmakesureyou ' rerestartingmysqlservice?

Below is what I did,thisisonfedora (since you ' reusingrhelthisshouldmoremimicyoursetup ) :

ibdata1IB _ log file0IB _ log file1mysqlmysql.sock

mysqld.pid

stopping mysqld : [确定]

starting mysqld : [确定]

ibdata1IB _ log file0IB _ log file1MySQL

mysqld.pid mysql.sock

theonlythingthatichangedwassocket=this time,and restarting still worked fine。

areyousurethatyou ' renoteditingsocketwithinthe [ client ] section ofmy.cn f? itmustbeunderthe [ mysqld ] section。

版权声明:该文观点仅代表作者本人。处理文章:请发送邮件至 三1五14八八95#扣扣.com 举报,一经查实,本站将立刻删除。