Media sync - delete source data after sync (dietpi-sync vs. rsync) Topic is solved

Have some feedback, questions, suggestions, or just fancy a chat? Pop it in here.
Post Reply
cyanogenic
Posts: 2
Joined: Tue May 26, 2020 10:33 am

Media sync - delete source data after sync (dietpi-sync vs. rsync)

Post by cyanogenic »

To set the scene:
On my dietpi installation, I have radarr, sonarr and transmission, and the Pi has a 500GB external hard drive installed. This will be on 24/7.
I have a main PC where my Plex server is currently installed. It's my gaming PC so I only turn it on when I want to watch something.

What i want to do is for the files to be downloaded by the Pi and stored on the external hard drive (got this bit working :D), and then when my Plex server comes online (i.e. my main PC), I want the media files to be transferred over to my main PC, and delete them from the RPi.

I did some research and saw that with rsync it's possible to do this with "rsync --remove-source-files folder/ folder1/" type of command.

I tried to see if this was possible in the dietpi-sync but I don't think it can do that. It seems to use rsync protocol so maybe it's a possibility?

Can anyone confirm? is there a custom option that i can add to enable the removal?

Followup: can I install and use rsync alongside a dietpi installation?

User avatar
Joulinar
Posts: 1752
Joined: Sat Nov 16, 2019 12:49 am

Re: Media sync - delete source data after sync (dietpi-sync vs. rsync)

Post by Joulinar »

Hi,

many thanks for your request. Currently there is no option inside dietpi-sync to remove files that have been successfully duplicated on the receiving side. Anyway you can use rsync on your own. Because there is just one rsync executable existing. dietpi-sync is using the standard rsync and did not implement anything special. There will be no conflict using it yourself.
Pls let us know if a solution is working. This could help others if they hit by similar situation. Your DietPi Team

cyanogenic
Posts: 2
Joined: Tue May 26, 2020 10:33 am

Re: Media sync - delete source data after sync (dietpi-sync vs. rsync)

Post by cyanogenic »

Thanks. Will set up some rsync scripts then :)

P.s. DietPi rocks

Post Reply