Difference between revisions of "Connecting Directly To The Development Database"

From Warwick Student Cinema
Jump to: navigation, search
Line 24: Line 24:
 
If something goes wrong, make sure that you have properly filled out all of the mentioned fields in PuTTY. If you miss anyone of them, plink will fail to launch properly. Make sure that your private key is not protected by a password.
 
If something goes wrong, make sure that you have properly filled out all of the mentioned fields in PuTTY. If you miss anyone of them, plink will fail to launch properly. Make sure that your private key is not protected by a password.
   
[[Website Version 3]]
+
[[Category:Website Version 3]]

Revision as of 05:07, 20 November 2009

Here are some quick instructions for allowing your local machine to query the filmsoc database server through an SSH tunnel on Windows.

  1. Run PuTTY
  2. Enter the hostname as filmsoc.warwick.ac.uk
  3. Select Connection->Data
    1. Input your username in the "Auto-login username" field
  4. Select Connection->Auth
    1. Under "Private key file for authentication:", select a private key that the server will recognise (ie. one of the one's you use in pageant)
  5. Select Connection->SSH->Tunnels
    1. Under "Add new forwarded port:", type 3306 into "Source port"
    2. In the "Destination" field, type: database.filmsoc.warwick.ac.uk:3306
    3. Click "Add"
  6. Select Session
    1. Under "Saved Sessions" type "database" into the field and click "Save"
  7. Click "Cancel" to close PuTTY
  8. Now, open your favourite text editor and put the following on one line:
    1. "C:\Program Files\PuTTY\plink" database
      1. Note: Change the path to wherever PuTTY is installed!)
    2. Save the file as database.bat (or similar) and put it somewhere convenient (best in the PuTTY program directory)
  9. Create a shortcut to the batch file and place it in your start menu/quick launch/ desktop, wherever is convenient.
  10. Now, whenever you want to run the website locally, start up the batch script by activating the shortcut, and the website code should be able to access filmsoc's database server remotely.
  11. Be sure to close the Command Prompt once you are done, or type "quit" or "logout" at the SSH prompt

If something goes wrong, make sure that you have properly filled out all of the mentioned fields in PuTTY. If you miss anyone of them, plink will fail to launch properly. Make sure that your private key is not protected by a password.