bangms
Jun 20 2008, 09:57 PM
| | Is it possible to directly access my local database from my website?
For example, if somebody submits info on my website, the info they submitted would be transferred to my local database directly. Is that possible? And if so, how do I set that up?
The reason I don't want to upload my database to my subdomain is because it would be difficult to keep the website database and my local database in sync . . . or is there a way to do that?
Thanks for any replies. |
Comment/Reply (w/o sign-up)
bangms
Jun 21 2008, 07:37 AM
OK, I did some looking up about remote accessing and I found out I could use SSH/Shell . . . something like that. If I'm not mistaken, the admins disabled this feature on free accounts due to hacking attempts, right? So what are my alternatives to accessing my local database from my site?
Comment/Reply (w/o sign-up)
rvalkass
Jun 21 2008, 09:08 AM
You can't access your Trap17 database from elsewhere, but I don't think there is anything stopping your Trap17 account from updating your local database. You would need a PHP script that would go through your entire database, create a SQL command to copy it all, and then run that SQL on your local machine. To do that, you need to change one thing in the standard code to connect to the database. To connect to your database, change the server 'localhost' to 'your_ip:port'. Obviously you will need to find out your IP address, and what port your MySQL server is running on. You should then be able to run commands on your local database from your hosting account. However, copying the entire database would be very slow and server intensive. What would be better would be to copy only changed rows. I have no idea what your database structure is, so I can't offer more advice apart from adding a new field to every table that stores the time the row was last updated. Then, only copy rows updated in the last day or whatever.
Comment/Reply (w/o sign-up)
bangms
Jun 21 2008, 05:51 PM
QUOTE(rvalkass @ Jun 21 2008, 02:08 AM)  To connect to your database, change the server 'localhost' to 'your_ip:port'. Obviously you will need to find out your IP address, and what port your MySQL server is running on. You should then be able to run commands on your local database from your hosting account.
However, copying the entire database would be very slow and server intensive. What would be better would be to copy only changed rows. I have no idea what your database structure is, so I can't offer more advice apart from adding a new field to every table that stores the time the row was last updated. Then, only copy rows updated in the last day or whatever. Hm. That sounds like a good idea but it sounds like a lot of advanced scripting. Do you think it would just be easier to directly connect to my local database by the way you suggested - using 'my_ip:port'? It wouldn't be too hard to change the scripts I already have and that way, I wouldn't have to keep two databases in sync. Would that be an option?
Comment/Reply (w/o sign-up)
Galahad
Jun 21 2008, 06:24 PM
Yes, you can change all your scripts to point to your local MySQL server, and that way all the information would be immediately stored on your computer and in your local MySQL database... You only need to make sure your computer is always accessible, if you have a firewall, open one port for MySQL server to listen to... Also, a good idea would be to subscribe to some free dynamic DNS service, like DynDNS, so you don't have to change your scripts whenever your IP changes... Don't know your bandwidth, but if you're on 512K ADSL, your MySQL server could serve possibly around 10 requests at once, with some lagging, depending on how much data is being trasnfered...
Comment/Reply (w/o sign-up)
hitmanblood
Jun 23 2008, 07:24 PM
I would suggest that you simply use trap17 base and then use your personal computer and database for the backup or something similar. And one more thing it is not that hard to write such script. You need some basci knowledge of SQL more or less and some basci knowledge of PHP in coordination with databases. best regards
Comment/Reply (w/o sign-up)
bangms
Jun 23 2008, 11:02 PM
So I should upload my database and just direct all my php scripts to the database on trap17? But then do I have to make my own script to back up the files on my computer? The trap17 database and my local database have to be in immediate sync - meaning they have to be updated right away - not manually. Would I have to script that myself or could I find one somewhere else?
Comment/Reply (w/o sign-up)
rvalkass
Jun 24 2008, 08:57 AM
It depends on exactly what you want. Why do you need a perfect replica of the database on your local machine? If it is as a backup, then I suggest getting hold of a PHP script to make automatic backups for you every so often. If it is to work on the database, then it doesn't need to be up-to-the-minute. If it is to run queries on the data or something, then why can't you use one database on Trap17?
Comment/Reply (w/o sign-up)
bangms
Jun 24 2008, 09:37 AM
The reason I need the database on my local machine is because I'm running a private game server. The server uses the database stored on my local computer, unless I could direct it to access a database on Trap17 - which would slow the server down. I want the user to be able to play the game as soon as they register, but I guess it is not necessary that they play immediately. I'm thinking that directly linking my PHP scripts to my local database would be easiest as Galahad suggested. I already have a static IP and I already have an open port for MySQL. So is directly linking to my database the way to go (and safest)?
Comment/Reply (w/o sign-up)
Similar Topics
Keywords : remote, access, mysql
- I Can't Access My Site
(7)
Mccodes With Mysql! [resolved]
I need help with this topic (6) Hey all, I was trying to install my McCodes game I bought recently, but every time I try to install
it, I get this error: QUOTE Write Config... Config written. Attempting DB connection
Warning : require(class/class_db_mysql.php) : failed to open stream: No such file or directory in
/home/lwadmin/public_html/installer.php on line 457 Warning :
require(class/class_db_mysql.php) : failed to open stream: No such file or directory in
/home/lwadmin/public_html/installer.php on line 457 Fatal error : require() : Failed
opening required 'class....
Mysql Server Down
(10) mysql (5.0.51a-community) failed What is happening? And btw, sometimes I get a message: could not
connect with mysql server. I use joomla 1.5 . but now, the server is down as shown on Server
status... please help....
I Can't Seem To Access My Site.
(8) I try to go to my hosted site http://saitunes.trap17.com and it just thinks, then it says the
operation timed out. Can anyone else access my site?....
My Site Is Crippled.
I can't access anything (10) Hey guys please help. I haven't been able to access my cPanel for a long time now. I think the
problem started when most members had those password problems. I think that's when I made too
many unsuccessful login attempts. Now I can't access my cPanel and any site hosted here. Someone
told me my IP is blocked but I don't know who to tell to have the problem resolved.
BuffaloHelp(sorry if it wasn't u Buff) stated in one post that he could reset password if nayone
would write a post with the line "Please reset my password". I did that but still there is....
Mysql Database Not Working
(3) well i'm getting an error message(a databass connection warning) for all of the parts of my site
that connects to a mysql database i check my database users pertmissions and i try to do the repair
database thing and it's still not woeking. am i the only person having this or is it an overall
trap17 issue and how do i fix it.....
It Went Well For A While
MySQL problem back in all its glory. (5) Some time ago I had a stubborn problem when trying to access one of the interactive pages on my
website and getting the following error: QUOTE Warning: fopen() : open_basedir restriction in
effect. File(include/errors.xml) is not within the allowed path(s):
(/home/mrdee:/usr/lib/php:/usr/local/lib/php:/tmp) in
/home/mrdee/public_html/admin/include/commonfunctions.php on line 682 Warning:
fopen(include/errors.xml) : failed to open stream: Operation not permitted in
/home/mrdee/public_html/admin/include/commonfunctions.php on line 682 Cannot open XML data file:
incl....
Hosting Problem [resolved]
403 Forbidden Error occurs whenever I try to access my site (22) First off, let me say that I have spent considerable effort and time going through the forums
seeking solutions for this problem. I have even gone as far as to seek help from the Xisto Live
support team (they suggested I wait 2 hours and then get back to them. Well I did that, and there
has been no change, and live support is now down). I've also tried changing permissions on both
files and folders via Cpanel, but to no avail. I still end up with the same error: QUOTE
Forbidden You don't have permission to access /index.php on this server. Additionally, a 4....
No Site Access
(4) It was working the day before yesterday and then it started giving me error messages about not being
able to access the site. I can't access cpanel either. Neither page ever loads. I don't
have this problem with any other internet pages, just my site stuff on Trap17. My site's at
www.jzambrano.trap17.com btw. This is one of the few times I'll need it up for sure so I'd
appreciate if the issue can get fixed in the near future. ....
Can't Access My Site An Cpanel
already did some sugested things (6) I still can't get to my website and cpanel, Tings I did: requested xisto to unblock my ip
cleaned my cache/cookies Did this with both IE and FF When I am @ my dads house he can acces my
website. So I guess it is still an ip problem. I did read some posts but couldn't find a
solution. Thx in advance,....
Can't Access My Site....weird Issue
(5) Okay, so last night everything worked fine. I loaded up cpanel, fixed issues with the site after the
database move, etc. Today I'm unable to load up the site. It just keeps giving me ping
timeouts. With what I'm being told by others it is only me having this issue with my site, and
yet there have been 0 changes to my pc between it working and not. I have tried multiple times
during the day with no luck. Along with this, if I load my website using a proxy service then I do
not have any issues. The only time it will not allow me to access it is if I am "using" my....
Almost There, However.... [resolved]
Cannot access webmail yet. (7) After all the troubles over the past week, I have everything set up, my access to MySQL databases
restored, however, I cannot access my webmail yet. I log in on the screen before you get the choice
which webmail to use (Squirrel, Horde or Roundcube), and when clicking on Horde I get "Login failed
because your username or password are incorrect", with Squirrel mail i get; "ERROR: Connection
dropped by IMAP server." and Roundcube (probably as the name implies) keeps going round in circles.
According to the opening screen of cpanel, I have 3 email accounts (as it should be)....
How Do I Find My Mysql Password? [resolved]
Cannot access my MySQL (5) After all the recent problems, my account has been restored. I have setup my parked domain agin, and
that works fine. However, I can no longer access my MySQL databases (I can from PHPMyAdmin, but
that's all). I had to create a new user for my databases, and created the user with exactly the
same username and password I had before, but some of my web pages do not let me access the pages I
have associated with my databases. Where could i find out what my DB password is? (Although I am as
good as sure I am using the right one). I have tried my old password, the new c....
Official: Can't Access My Cpanel - Supports From Admins
(71) Scroll down to Post #8 for Admin Support Ok I've read stuff here and there in the support
forum and shoutbox about the recent trap17 server problem. I'm extremely confused. Some people
say that their websites are working fine. Some people are experiencing different issues from mine,
had their website reset or something. I can access my website on the gamma server, so I assume that
if I unpark and park my domain again, I can get it to work like the last time. I accessed my cpanel
at bishoujo.trap17.com/cpanel because the 'Access CPanel' link on the fo....
I Cant Access The Server!
(1) i can not establish a connection AT ALL!! my ftp program (Core FTP LE) cannot connect, neither can
my online ftp..... also, i cannot log in to my cpanel!! in short, i cant do ANYTHING!!! can
anyone help me?? better question, is the server down? and im not aware of it? /mad.gif"
style="vertical-align:middle" emoid=":angry:" border="0" alt="mad.gif" />....
Anonymous Ftp Access?
(2) Hi, my subdomain here is tf2maps.trap17.com, and I was wondering, how do you enable anonymous ftp
access for the public_ftp folder? I cant seem to find the option in Cpanel. And every time I try to
access http://tf2maps.trap17.com/public_ftp/tf/ it gives me a 404 error? Is there any way of
seeing my folders in the browser? Thank you! /biggrin.gif" style="vertical-align:middle" emoid=":D"
border="0" alt="biggrin.gif" />....
Server Issues? Web Site Down? Cpanel Access?
Server Migration issues to report. (48) I tried downloading my email from website this morning and Thunderbird said it couldn't access
it the server. Then I tried loading my website - to no avail. Does anyone have any idea what's
going on? Is anyone else experiencing this? Seems like this is the second time this spring this has
happened. Is an upgrade going on, or something? Thanks in advance for your help! ....
Sub Domain Problem : Urgent
Cannot access my sub domains (10) Hi, I am having some serious problems with my sub domains. I registered a site with trap17 named
http://zoebelkin.co.cc . Then I made 2 sub domains for the site. One is for the forums section
and the other is for the gallery section. 1> forums.zoebelkin.co.cc 2> gallery.zoebelkin.co.cc
Whenever I type these in the browser adress bar the browser gives an output that it cannot find the
web sites. But they are complete and should show something. Also using www. in front of the sub
domains didn't help. Is www. needed in front of the sub domains. Could you just....
Cannot Access Cpanel...
(3) hey guys, its starting to irritate me how my computer is somewhat dumb...I don't know if its
something I did or what, but maybe somebody can help. I go to my cpanel, from any link I try it says
internet explorer cannot find page or whatever the heck it says...but wait....i go to my
laptop...and what happens? perfect, however i hate my laptop to death cuz it does not have nearly
anything and im not supposed to use it for anything but work, and its connection SUCKS...so ya, does
anybody think they know how to fix it? im trying to download firefox and or opera right no....
Unable To Access Cpanel
(7) I'm not able to access the cPanel for my hosting account, I get the following error, CODE
The connection has timed out The server is taking too long to respond. I tried accessing the
cPanel from http://gamma.xisto.com/cpanel ....
Problems With Ftp Access
(1) Well topic title says its all I have problem with ftp access to my account here on trap17 so if
anyone has experienced similar issues lately. The problem is when I try to log on it disconnects me
from the server. I am using filezilla however I have tried to access trough file manager and it
works fine though it is not the same protocol. I must admit I have deleted some folders recently
however I am quite certain that it is all connected to the joomla installation and not some system
files but if there is some specified folder for ftp could you plese write down so I cou....
I Cannot Access My Site. [resolved]
Am I blocked by Firewall? (13) Hi, is there a server problem? All of a sudden I cannot get through to
http://www.vlaanderen-flanders.org.uk anymore, nor can I FTP. Could someone check this out,
please?....
Can't Access My Email Account [resolved]
(4) I couldn't access my email account for 3 days ago .. I use the Horde .. the problem is when I
click on Login the page loads itself and don't change!!!!.......
Is It Possible To Access The Mysql Remotely?
(10) I like to experiment with a lot of things and I was thinking of making a sort of instant messenger
in Python, but I want to let people have actual accounts so I need to be able to access the mySQL
remotely. If that's not possible, are we allowed to run Python scripts on the server?....
Installing Apache, Mysql, Phpmyadmin Locally
Solving the "php_mbstring.dll missing" (5) Since Trap17's CP provide the individual site's owner with goodies like MySql and
PhpMyAdmin, chances are some will want to make use of them. Well, it's fine enough to get that
on one's host (Gee! Thanks a lot, Trap17...) Knowing how the usual geek react, it might be
expected that most people considering to make use of a database on their site will want to do most
of the tedious job of developing and testing on their own local system before sending the wrapped-up
result on their domain/subdomain. This involves four basic steps (sorry for the compuwizs, ....
Help Moving Mysql Files To A New Host
IPB files (2) Well, my partners on my forum has decided to move our site to a newer host. A paid one to be exact.
And we did that already. Now all we need to do is move our forum over to the new host. We want to
do this without losing all of our posts and other data. I know it has something to do with the MySQL
files but I don't really understand it. Some help would be appreciated. We are running Invision
Power Board 1.3.1 final Also, we're thinking about upgrading our board to a newer version of
IPB because we heard that its better in more ways than one. But then again, it....
Setting Up A Remote Mysql Connection
Need help! (3) Okay... I'm hosted here on Trap17. I would like to connect to a remote MySQL database located on
another server... can someone walk me through what I need to do to set this up, or if it can even be
done? Thank you in advance!....
Mysql Database Setup : Setting Up Mysql Database
Guide to use MySQL database in your site (7) A SMALL INTRODUCTION TO DATABASE ============================= I have seen that many members have
problems with Database. Here is a small INFO which should give you the IDEA. mySQL is a DATABASE
server. You can access it using the link in Cpanel. Cpanel can be accessed by
"www.YOUR-SITE.com/Cpanel" There you have 4 Main Options :- 1> CREATE A DATABASE 2> CREATE A USER
3> ADD USER TO DATABASE 4> PHPMYADMIN CREATE : IT ALLOWS YOU TO CREATE A DATABASE CREATE USER
: IT ALLOWS YOU TO CREATE A USER. USING THIS, YOU CAN ACCESS THE DATABASE. A DATABASE CANNOT BE....
MYSQL Settings
(5) I am going to edit my mysql settings. Before i had freesql.org but that's slow. So now i
created one here. What is the host? What must i put in the server.....
Problems with PHPBB & my Access to files :S
(4) Ok another problem i'm having.. prolly my fault but ok.. i go to uploud my avatar on my forums
and it says this after i click submit Warning: copy(./images/avatars/486273215410e356f445f1.jpg):
failed to open stream: Permission denied in /home/zipmc/public_html/Forum/includes/usercp_avatar.php
on line 227 Warning: Cannot modify header information - headers already sent by (output started at
/home/zipmc/public_html/Forum/includes/usercp_avatar.php:227) in
/home/zipmc/public_html/Forum/includes/page_header.php on line 474 Warning: Cannot modify header
information - h....
Looking for remote, access, mysql
|
Searching Video's for remote, access, mysql
See Also,
|
advertisement
|
|