• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Tim Cooke
  • Ron McLeod
  • paul wheaton
  • Jeanne Boyarsky
Sheriffs:
  • Paul Clapham
  • Devaka Cooray
Saloon Keepers:
  • Tim Holloway
  • Roland Mueller
  • Himai Minh
Bartenders:

NOt able to connect to actual database on the web server

 
Ranch Hand
Posts: 641
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
How to run MySql scripts to give priveliges for a pirticular Database.
when i try to connect locally to my MySql database with the following syntax
String url = "jdbc:mysql://10.15.0.2:3306/unistal?user=root&password=";
connection = DriverManager.getConnection(url);
it works fine but when i connect to the actual database on the web server with actual userID and Password , it fails to connect .
I,am sure that i,am wrigin the correct password and username because i,am runnning my PHP scripts through the same username and password.
What could be the reason that i,am not able to connect to the server ?
PLease guide me a bit .
Thanks in advance
 
Sheriff
Posts: 7023
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Are you sure that the request is making it to the machine with MySQL running?
Through trial and error and hair pulling, I just discovered that my ISP was blocking WAN access to port 80. (That's why the Beginner's Wiki is running on that strange port 4000 while it's developed in the initial stages.)
 
Raghav Mathur
Ranch Hand
Posts: 641
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Dirk
i,am sure that MySql is running on the web sever as my PHP scripts work fine . It is only when i try to make a connection from my local machine to the database( on the web server) , it doesn't let me ... does it have something to do with the rights which are to be granted to me .
Please guide me a bit
Thanks in advance
 
Dirk Schreckmann
Sheriff
Posts: 7023
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Are you sure that the request from outside of the network, or from outside of the machine with MySQL, is actually being received by the machine with MySQL running? Is it possible that a firewall is blocking access on that port?
 
Raghav Mathur
Ranch Hand
Posts: 641
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by Dirk Schreckmann:
Are you sure that the request from outside of the network, or from outside of the machine with MySQL, is actually being received by the machine with MySQL running? Is it possible that a firewall is blocking access on that port?


NO . I have tested my PHP scripts which run on the server . they work .
I haven't tested anything from outside the server.
There is no firewall as such .
Can it be a prob of granting some sort of Privileges.Maybe those grants have not been given to a connection which comes from a remote client .
Can this be a reason ?
 
reply
    Bookmark Topic Watch Topic
  • New Topic