By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
437,949 Members | 1,855 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 437,949 IT Pros & Developers. It's quick & easy.

how to ssh or scp or sftp through PHP?

P: n/a

On the company's webserver we have two harddrives. Apache is aware of
one of those harddrives and serves websites from that harddrive. The
other harddrive is not reachable via the web. I've written some cron
jobs that make a backup of various MySql databases and saves a copy to
that second hard drive.

For added security, I'd love to have a cron job (on my home Ubuntu
machine) that runs each night and downloads all the backups to my home
machine. I thought I could write a bash shell script using scp to do
this, but I now find out that one has to jump through several hoops
(create private/public keys, etc) to do it.

I'm wondering if there is an easier way to download the files, using
PHP? Any thoughts on this?

Feb 10 '08 #1
Share this Question
Share on Google+
2 Replies


P: n/a
"lawrence k" <lk******@geocities.comwrote in message
news:5b**********************************@v67g2000 hse.googlegroups.com...
>
On the company's webserver we have two harddrives. Apache is aware of
one of those harddrives and serves websites from that harddrive. The
other harddrive is not reachable via the web. I've written some cron
jobs that make a backup of various MySql databases and saves a copy to
that second hard drive.

For added security, I'd love to have a cron job (on my home Ubuntu
machine) that runs each night and downloads all the backups to my home
machine. I thought I could write a bash shell script using scp to do
this, but I now find out that one has to jump through several hoops
(create private/public keys, etc) to do it.

I'm wondering if there is an easier way to download the files, using
PHP? Any thoughts on this?
What is your company's policy concerning corporate data security?
Feb 10 '08 #2

P: n/a
On Feb 9, 10:35 pm, "McKirahan" <N...@McKirahan.comwrote:
"lawrence k" <lkrub...@geocities.comwrote in message

news:5b**********************************@v67g2000 hse.googlegroups.com...
On the company's webserver we have two harddrives. Apache is aware of
one of those harddrives and serves websites from that harddrive. The
other harddrive is not reachable via the web. I've written some cron
jobs that make a backup of various MySql databases and saves a copy to
that second hard drive.
For added security, I'd love to have a cron job (on my home Ubuntu
machine) that runs each night and downloads all the backups to my home
machine. I thought I could write a bash shell script using scp to do
this, but I now find out that one has to jump through several hoops
(create private/public keys, etc) to do it.
I'm wondering if there is an easier way to download the files, using
PHP? Any thoughts on this?

What is your company's policy concerning corporate data security?

I'm allowed to download the files, if that is what you need. I'm one
of the owners of the firm, and I'm the one who does most of the
sysadmin stuff (though I'm not really a sysadmin, obviously). So I'm
allowed to do it, so long as I can figure out a secure way to do it.

Feb 16 '08 #3

This discussion thread is closed

Replies have been disabled for this discussion.