HI Ratha, You can check weather MySQL server is accessible from you machine using telnet. Most probably you won't be able to when having a look at the issue you have mentioned. If the the server is running in the remote machine but still you can not connect most probably server is bind to localhost as Niroda mentioned. You can check bind address by
netstat -tulpn | grep mysql tcp 0 0 127.0.0.1:3306 *127.0.0.1* LISTEN 1105/mysqld If so change bind address to 0.0.0.0, so server will be bind to all network interfaces. tcp 0 0 127.0.0.1:3306 *0.0.0.0:** LISTEN 1105/mysqld On Wed, Feb 11, 2015 at 10:57 AM, Nirodha Pramod <[email protected]> wrote: > Hi Ratha, > > This is either the user does not have enough privileges or you haven't > given remote access permission for clients to connect remotely. If you can > connect from a client from within the server machine then the root cause is > the latter one. To overcome that you have to set the bind-address value to > the ip instead of 127.0.0.1 to give remote access, which is in my.cnf file. > In linux systems it is usually there in /etc/mysql/my.cnf. Please refer > [2] and [3] for more info. > > [2] > http://stackoverflow.com/questions/2482234/how-to-know-mysql-my-cnf-location > [3] > http://www.cyberciti.biz/faq/unix-linux-mysqld-server-bind-to-more-than-one-ip-address/ > > > -Nirodha > > On Wed, Feb 11, 2015 at 9:57 AM, Anuruddha Liyanarachchi < > [email protected]> wrote: > >> Hi Vijayaratha, >> >> Have you checked this answer[1] at stackoverflow. >> You could try adding a new administrator account: >> >> [1] >> http://stackoverflow.com/questions/1559955/host-xxx-xx-xxx-xxx-is-not-allowed-to-connect-to-this-mysql-server >> >> >> On Wed, Feb 11, 2015 at 9:47 AM, Vijayaratha Vijayasingam < >> [email protected]> wrote: >> >>> I checked that option too. My setting is right..Attached screenshot >>> >>> On 11 February 2015 at 12:11, Bhathiya Jayasekara <[email protected]> >>> wrote: >>> >>>> Hi Ratha, >>>> >>>> In MySQL server, *skip-networking* setting must have been enabled. You >>>> have to disable it to allow remote connections. More infor here [1]. >>>> >>>> [1] >>>> http://www.cyberciti.biz/tips/how-do-i-enable-remote-access-to-mysql-database-server.html >>>> >>>> Thanks, >>>> Bhathiya >>>> >>>> On Wed, Feb 11, 2015 at 9:35 AM, Vijayaratha Vijayasingam < >>>> [email protected]> wrote: >>>> >>>>> Hi all; >>>>> Trying to connect remote mysql server which in windows box. But >>>>> getting[1]; >>>>> >>>>> I can ping to that machine and firewall is off. Root user has all >>>>> privileges. >>>>> >>>>> Anyone knows the cause, what type of security settings i need to do in >>>>> mysql? >>>>> >>>>> [1]Caused by: >>>>> com.mysql.jdbc.exceptions.jdbc4.MySQLNonTransientConnectionException: >>>>> Could >>>>> not create connection to database server. Attempted reconnect 3 times. >>>>> Giving up. >>>>> >>>>> at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native >>>>> Method) >>>>> >>>>> at >>>>> sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57) >>>>> >>>>> at >>>>> sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45) >>>>> >>>>> at java.lang.reflect.Constructor.newInstance(Constructor.java:526) >>>>> >>>>> at com.mysql.jdbc.Util.handleNewInstance(Util.java:377) >>>>> >>>>> at com.mysql.jdbc.Util.getInstance(Util.java:360) >>>>> >>>>> at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:956) >>>>> >>>>> at com.mysql.jdbc. >>>>> >>>>> Caused by: java.sql.SQLException: null, message from server: "Host >>>>> '192.168.50.62' is not allowed to connect to this MySQL server" >>>>> >>>>> at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:996) >>>>> >>>>> at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:935) >>>>> >>>>> at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:924) >>>>> >>>>> at com.mysql.jdbc.MysqlIO.doHandshake(MysqlIO.java:1037) >>>>> >>>>> >>>>> thanks >>>>> -- >>>>> -Ratha >>>>> >>>>> _______________________________________________ >>>>> Dev mailing list >>>>> [email protected] >>>>> http://wso2.org/cgi-bin/mailman/listinfo/dev >>>>> >>>>> >>>> >>>> >>>> -- >>>> *Bhathiya Jayasekara* >>>> *Software Engineer,* >>>> *WSO2 inc., http://wso2.com <http://wso2.com>* >>>> >>>> *Phone: +94715478185 <%2B94715478185>* >>>> *LinkedIn: http://www.linkedin.com/in/bhathiyaj >>>> <http://www.linkedin.com/in/bhathiyaj>* >>>> *Twitter: https://twitter.com/bhathiyax <https://twitter.com/bhathiyax>* >>>> *Blog: http://movingaheadblog.blogspot.com >>>> <http://movingaheadblog.blogspot.com/>* >>>> >>> >>> >>> >>> -- >>> -Ratha >>> >>> _______________________________________________ >>> Dev mailing list >>> [email protected] >>> http://wso2.org/cgi-bin/mailman/listinfo/dev >>> >>> >> >> >> -- >> *Thanks and Regards,* >> Anuruddha Lanka Liyanarachchi >> Software Engineer - WSO2 >> Mobile : +94 (0) 712762611 >> Tel : +94 112 145 345 >> a <[email protected]>[email protected] >> >> _______________________________________________ >> Dev mailing list >> [email protected] >> http://wso2.org/cgi-bin/mailman/listinfo/dev >> >> > > > -- > > *Nirodha Gallage* > Senior Software Engineer, QA. > WSO2 Inc.: http://wso2.com/ > Mobile: +94716429078 > > _______________________________________________ > Dev mailing list > [email protected] > http://wso2.org/cgi-bin/mailman/listinfo/dev > > -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897
_______________________________________________ Dev mailing list [email protected] http://wso2.org/cgi-bin/mailman/listinfo/dev
