rakshasa / rtorrent

rTorrent BitTorrent client
https://github.com/rakshasa/rtorrent/wiki
GNU General Public License v2.0
4.07k stars 408 forks source link

Move completed torrent to an other location (same disk) #1057

Closed acantepie closed 3 years ago

acantepie commented 3 years ago

Hello,

I am trying to move completed torrent data to an other location but when my torrent was completed nothing happen. I have followed instructions from Wiki : https://github.com/rakshasa/rtorrent/wiki/Common-Tasks-in-rTorrent#move-completed-torrents-to-a-fixed-location

method.insert = d.get_finished_dir, simple, "cat=/mnt/plex/,$d.custom1="
method.insert = d.data_path, simple, "if=(d.is_multi_file), (cat,(d.directory),/), (cat,(d.directory),/,(d.name))"
method.insert = d.move_to_complete, simple, "d.directory.set=$argument.1=; execute=mkdir,-p,$argument.1=; execute=mv,-u$
method.set_key = event.download.finished,move_complete,"d.move_to_complete=$d.data_path=,$d.get_finished_dir="

#Try loging but nothing was logged ...
log.open_file = "rtorrent", /var/log/rtorrent/rtorrent.log
log.open_file = "tracker", /var/log/rtorrent/tracker.log
log.open_file = "storage", /var/log/rtorrent/storage.log

log.add_output = "critical", "rtorrent"
log.add_output = "error", "rtorrent"
log.add_output = "warn", "rtorrent"

log.add_output = "dht_critical", "tracker"
log.add_output = "dht_error", "tracker"
log.add_output = "dht_warn", "tracker"

log.add_output = "tracker_critical", "tracker"
log.add_output = "tracker_error", "tracker"
log.add_output = "tracker_warn", "tracker"

log.add_output = "storage_critical", "storage"
log.add_output = "storage_error", "storage"
log.add_output = "storage_warn", "storage"

Its not a permission problem and my both folder are on same disk : sudo -H -u rtorrent mv /mnt/torrent/downloads/<something> /mnt/plex

Config :

What's wrong with my config ?

pyroscope commented 3 years ago

What's wrong with my config?

You have no execute.log.

acantepie commented 3 years ago

Ok, i change my config. now it works. I have absolutly no idea why :

# Log
method.insert = cfg.logs,     private|const|string, (cat,"/var/log/rtorrent/")
method.insert = cfg.logfile,  private|const|string, (cat,(cfg.logs),"rtorrent-",(system.time),".log")

log.execute = (cat, (cfg.logs), "execute.log")

print = (cat, "Logging to ", (cfg.logfile))
log.open_file = "log", (cfg.logfile)
log.add_output = "info", "log"

# events
method.insert = d.get_finished_dir, simple, "cat=/mnt/plex/,$d.custom1="
method.insert = d.data_path, simple, "if=(d.is_multi_file), (cat,(d.directory),/), (cat,(d.directory),/,(d.name))"
method.insert = d.move_to_complete, simple, "d.directory.set=$argument.1=; execute=mkdir,-p,$argument.1=; execute=mv,-u$
method.set_key = event.download.finished,move_complete,"d.move_to_complete=$d.data_path=,$d.get_finished_dir="
pyroscope commented 3 years ago

What happened is most likely the restart you forgot before, to load new config. ;) Pls close!

acantepie commented 3 years ago

Oh .. ok, ty for help