I plan to move file from one system to another system. For this, I am using rsync command in linux terminal. It works fine. But I need to implement this command to python. I am very new in python, so I don't know the way of defining the rsync command. So please tell the steps to define it. This is my rsync command:
rsync -avrz /opt/data/filename root@ip:/opt/data/file
I need to implement this command in a python script.