MySQL Server Connection

Discussion in 'Web Design and Development' started by aceiswild, Jun 29, 2012.

  1. aceiswild macrumors newbie

    Joined:
    Nov 15, 2011
    Location:
    Canada
    #1
    Hey guys,
    So i recently installed MySQL on my Mac. I am also told that I need to install OpenSSH for server connection purposes. I cannot find way to install openSSH on my Mac. Has anybody done this before? Only references i can find are for Linux/Ubuntu. Also I am trying to connect to my GoDaddy Server though Terminal. I have SSH enabled on my account and have all my server info.
    This is what i am trying into Terminal to connect to my database: mysql -h 'hostname' -u 'username' -p 'prompt for password'.
    It for some reason won't allow me to connect. I get this error: ERROR 2003 (HY000): Can't connect to MySQL server on 'stevenmayerwebdesigns.ca' (60)

    Any suggestions appreciated :)
    Cheers,
    Steve
     
  2. aarond12 macrumors 65816

    aarond12

    Joined:
    May 20, 2002
    Location:
    Dallas, TX USA
    #2
    An "nmap" scan of stevenmayerwebdesigns.ca shows that the following ports are open:

    Code:
    PORT      STATE  SERVICE      VERSION
    21/tcp    open   ftp          PureFTPd
    22/tcp    open   ssh          OpenSSH 5.1 (protocol 2.0)
    |_ssh-hostkey: 1024 62:5e:b9:fd:3a:70:eb:37:99:e9:12:e3:d9:3f:4e:6c (DSA)
    80/tcp    open   http         Apache httpd
    |_html-title: Steven Mayer Web Designs
    139/tcp   closed netbios-ssn
    443/tcp   open   http         Apache httpd
    |_html-title: 403 Forbidden
    445/tcp   closed microsoft-ds
    554/tcp   open   rtsp?
    7070/tcp  open   realserver?
    50000/tcp closed iiimsf
    50001/tcp closed unknown
    50003/tcp closed unknown
    50500/tcp closed unknown
    
    What they probably want you to do is to SSH from the Terminal window to the remote server. I verified that the server prompts for login information from SSH. You probably won't get mysql to connect directly from your computer to the remote server -- which is a good thing!
     
  3. nuxx macrumors member

    nuxx

    Joined:
    Jun 5, 2007
    Location:
    Tokyo
    #3
    Take a look at the freeware Sequel Pro. I use this on my Mac to manage my GoDaddy databases via both SSH and direct MySQL connections.
     
  4. aceiswild thread starter macrumors newbie

    Joined:
    Nov 15, 2011
    Location:
    Canada
    #4
    Hey thanks to both, guys. Very helpful. I well give both a thuro investigation!
     
  5. aceiswild, Jun 30, 2012
    Last edited: Jun 30, 2012

    aceiswild thread starter macrumors newbie

    Joined:
    Nov 15, 2011
    Location:
    Canada
    #5
    Ok so for whatever reason i am getting a connection error using Sequal Pro.
    Like mentioned before i have SSH enabled in my GoDaddy.
    I am typing in exactly everything as shown and have tried all my passwords to be sure. Here are my screen shots:

    click to enlarge
    [​IMG]

    click to enlarge
    [​IMG]

    click to enlarge
    [IMG=http://img829.imageshack.us/img829/6060/mysql3.png][/IMG]

    I have configured my router to allow it.
    I do realize that GoDaddy uses Port 22 but default should work.

    Thanks :)
     
  6. nuxx macrumors member

    nuxx

    Joined:
    Jun 5, 2007
    Location:
    Tokyo
    #6
    @aceiswild

    Are you aware that to access GoDaddy databases remotely you need to enable direct database access?

    Not all of their hosting accounts allow this. You can check if yours does by trying to create a new database. You should see an option to allow direct database access.
     

    Attached Files:

  7. aceiswild thread starter macrumors newbie

    Joined:
    Nov 15, 2011
    Location:
    Canada
    #7
    Thanks for the help all. Very useful. Now i know what ports are open to which I will be doing next. Thank you Nuxx. You mentioning worked!! It was my fault for not allowing access. I must have skimmed through when i created my database and missed that option. And I don't think it says anywhere else if Accessing is enabled after you create your Database. But it works now! Time to get back to work.

    Cheers!
     

Share This Page