Re: transfer data from one machine to another

2007-03-04 Thread Rikishi 42
On Sunday 04 March 2007 13:56, bahoo wrote:

> I have ssh access to two linux machines (both WITHOUT root account),
> and I'd like to copy data from one to another.
> Since the directory structure is different, I want to specify in a
> script (ideally in python, because that's what I want to learn) what
> to copy over like this:
> 
> source: /home/john/folderA
> destination: /home/smith/folderB
> 
> I'm a newbie on linux and ssh networking and python, so your
> suggestions are welcome! A small working example would be appreciated!

Try rsync, if you need a second run, it will only copy what has been
modified in the source.

rsync -var -e ssh /home/john/folderA [EMAIL PROTECTED]:/home/smith/folderB

Should be enough.
Remove 'v' for less verbose operation.

-- 
Research is what I'm doing, when I don't know what I'm doing.
(von Braun)

-- 
http://mail.python.org/mailman/listinfo/python-list


Re: transfer data from one machine to another

2007-03-04 Thread Bjoern Schliessmann
bahoo wrote:

> I have ssh access to two linux machines (both WITHOUT root
> account), and I'd like to copy data from one to another.
> Since the directory structure is different, I want to specify in a
> script (ideally in python, because that's what I want to learn)
> what to copy over like this:
> 
> source: /home/john/folderA
> destination: /home/smith/folderB
> 
> I'm a newbie on linux and ssh networking and python, so your
> suggestions are welcome! A small working example would be
> appreciated!

On example machine 10.0.0.1, logged in as john:

scp -r ~/folderA [EMAIL PROTECTED]:~/folderB

It's IMHO simpler and quicker than developing the same functionality
in Python. Or is there a simple module I overlooked?

Regards,


Björn

Fup2 comp.lang.python

P.S.: Please don't crosspost over hierarchies without setting
followup.

-- 
BOFH excuse #53:

Little hamster in running wheel had coronary; waiting for
replacement to be Fedexed from Wyoming

-- 
http://mail.python.org/mailman/listinfo/python-list


transfer data from one machine to another

2007-03-04 Thread bahoo
Hi,

I have ssh access to two linux machines (both WITHOUT root account),
and I'd like to copy data from one to another.
Since the directory structure is different, I want to specify in a
script (ideally in python, because that's what I want to learn) what
to copy over like this:

source: /home/john/folderA
destination: /home/smith/folderB

I'm a newbie on linux and ssh networking and python, so your
suggestions are welcome! A small working example would be appreciated!

bahoo

-- 
http://mail.python.org/mailman/listinfo/python-list