Jul-16-2021, 10:31 PM
I don't know how to do this with Python, but I use rsync to back up everything important on my computer to my older laptop.
A command like this is a bash shell does a great job! You need the user's password for the remote machine.
rsync -av -e "ssh" --progress /home/pedro/myPython [email protected]:/home/pedro/
You can use rsync the other way around, get files from a remote machine to your localhost. I haven't tried that, no need.
rsync uses ssh by default now I believe, so actually no need to specify ssh.
On Linux, you need to install openssh.
You need the ip of the remote machine. I don't know how you would get that from your local machine.
In Linux you can find your ip with ifconfig. There is probably a way to find all machines on your local network. Never tried that.
rsync only copies files which have been changed since last time you did this, or new files.
So, if you copy a CD, the next time, rsync won't copy it again, because it hasn't changed. That saves a lot of time!
rsync can accept batch files. Personally, I think rsync is great!
Here's a link for rsync.
A command like this is a bash shell does a great job! You need the user's password for the remote machine.
rsync -av -e "ssh" --progress /home/pedro/myPython [email protected]:/home/pedro/
You can use rsync the other way around, get files from a remote machine to your localhost. I haven't tried that, no need.
rsync uses ssh by default now I believe, so actually no need to specify ssh.
On Linux, you need to install openssh.
You need the ip of the remote machine. I don't know how you would get that from your local machine.
In Linux you can find your ip with ifconfig. There is probably a way to find all machines on your local network. Never tried that.
rsync only copies files which have been changed since last time you did this, or new files.
So, if you copy a CD, the next time, rsync won't copy it again, because it hasn't changed. That saves a lot of time!
rsync can accept batch files. Personally, I think rsync is great!
Here's a link for rsync.