Get data of MySQL database from remote PC without SSH

Issues related to applications and software problems
Post Reply
Maximus
Posts: 4
Joined: 2017/07/08 06:16:52

Get data of MySQL database from remote PC without SSH

Post by Maximus » 2017/07/08 07:10:17

Hello,
My company has a CentOS 6.8 VPS which running PHP, MySQL and Apache. The VPS is hosted in the data center.
The VPS is hosting a Magento website ver 1.8.1.
My company want to get data of purchase orders from the website and store in a remote server.
I have Googled and I found some results seems to look similar, but I am just a newbie of CentOS, so I go here to ask.
A friend told me I have to open a new port but he also warned about the security risks.
So I want to ask you guys about a workaround to solve my problem. Could anyone help me?

scottro
Forum Moderator
Posts: 2556
Joined: 2007/09/03 21:18:09
Location: NYC
Contact:

Re: Get data of MySQL database from remote PC without SSH

Post by scottro » 2017/07/08 11:17:36

It might be useful to put in what looks, as you say, almost similar.

User john at host myhost, wanting to get database called magento at myhost.mydomain.com

mysqldump -ujohn -p -h myhost.mydomain.com magento > magento.sql
would make a dump of the database on the local machine, assuming that user john from that host has access.

mysql -u john -p -h myhost.mydomain.com -e "some mysql command" magento will work, or just the mysql -u john -p -h myhost.mydomain.com will put you at the mysql prompt on the remote host.
New users should check the FAQ and Read Me First pages

User avatar
TrevorH
Site Admin
Posts: 33219
Joined: 2009/09/24 10:40:56
Location: Brighton, UK

Re: Get data of MySQL database from remote PC without SSH

Post by TrevorH » 2017/07/08 12:35:03

My company want to get data of purchase orders from the website and store in a remote server.
How often? Once a day? Once a week? Immediately any order is placed? Sometime this year?
The future appears to be RHEL or Debian. I think I'm going Debian.
Info for USB installs on http://wiki.centos.org/HowTos/InstallFromUSBkey
CentOS 5 and 6 are deadest, do not use them.
Use the FAQ Luke

Whoever
Posts: 1361
Joined: 2013/09/06 03:12:10

Re: Get data of MySQL database from remote PC without SSH

Post by Whoever » 2017/07/08 16:07:54

Maximus wrote:Hello,
My company has a CentOS 6.8 VPS which running PHP, MySQL and Apache. The VPS is hosted in the data center.
The VPS is hosting a Magento website ver 1.8.1.
My company want to get data of purchase orders from the website and store in a remote server.
I have Googled and I found some results seems to look similar, but I am just a newbie of CentOS, so I go here to ask.
A friend told me I have to open a new port but he also warned about the security risks.
So I want to ask you guys about a workaround to solve my problem. Could anyone help me?
You are a newbie working with mission-critical data stored on a mission-critical server? That is a recipe for disaster.

You should find a reliable consultant to help you with this.

Maximus
Posts: 4
Joined: 2017/07/08 06:16:52

Re: Get data of MySQL database from remote PC without SSH

Post by Maximus » 2017/07/10 02:48:59

TrevorH wrote:
My company want to get data of purchase orders from the website and store in a remote server.
How often? Once a day? Once a week? Immediately any order is placed? Sometime this year?
Hello TrevorH,

It will be "Immediately any order is placed".

Our sales department uses a kind of ERP software. We want that after customers place order on the website, then ERP software can get the data of the order.

I talked with the software developer (who will code this function) and he suggested me to open port on the server and give him the connection string.

Maximus
Posts: 4
Joined: 2017/07/08 06:16:52

Re: Get data of MySQL database from remote PC without SSH

Post by Maximus » 2017/07/10 02:58:05

Whoever wrote:
Maximus wrote:Hello,
My company has a CentOS 6.8 VPS which running PHP, MySQL and Apache. The VPS is hosted in the data center.
The VPS is hosting a Magento website ver 1.8.1.
My company want to get data of purchase orders from the website and store in a remote server.
I have Googled and I found some results seems to look similar, but I am just a newbie of CentOS, so I go here to ask.
A friend told me I have to open a new port but he also warned about the security risks.
So I want to ask you guys about a workaround to solve my problem. Could anyone help me?
You are a newbie working with mission-critical data stored on a mission-critical server? That is a recipe for disaster.

You should find a reliable consultant to help you with this.
Hello Whoever,

I could consult the supporters from the hosting company. But I am worry about whether their change will pose security risks that I can not check.

I do not know whether the solution will be simple or complicated.

I am looking for a general idea about what steps I should do.

Maximus
Posts: 4
Joined: 2017/07/08 06:16:52

Re: Get data of MySQL database from remote PC without SSH

Post by Maximus » 2017/07/10 03:06:36

scottro wrote:It might be useful to put in what looks, as you say, almost similar.

User john at host myhost, wanting to get database called magento at myhost.mydomain.com

mysqldump -ujohn -p -h myhost.mydomain.com magento > magento.sql
would make a dump of the database on the local machine, assuming that user john from that host has access.

mysql -u john -p -h myhost.mydomain.com -e "some mysql command" magento will work, or just the mysql -u john -p -h myhost.mydomain.com will put you at the mysql prompt on the remote host.
Hello Scottro,

I did not mention that the remote server is Windows Server 2008. So, do these commands still work?

Sorry because I did not include adequate information.

Post Reply