DSM-G600, DNS-3xx and NSA-220 Hack Forum

Unfortunately no one can be told what fun_plug is - you have to see it for yourself.

You are not logged in.

Announcement

#476 2011-03-10 21:53:32

notsee
Member
Registered: 2011-03-09
Posts: 9

Re: [REL] Automatic for funplug-0.5

Just a few requests about the capacity
in automatic.conf

Code:

feedfile = <path to feeds file>
filterfile = <path to filters file>

to edit the settings with the rights of non-root user or possible webUI

And:

Code:

feed = {
url => ""
cookies => ""
label => ""
}

Code:

filter = {
pattern => ""
folder => ""
download-limit => ""
upload-limit => ""
ratio-limit => ""
feed-label => "<To search only for a specific feed (s)> "

just for appearance:
prowl-template = <regexp template for prowl text>
}

Last edited by notsee (2011-03-10 22:01:15)

Offline

 

#477 2011-03-10 21:59:00

notsee
Member
Registered: 2011-03-09
Posts: 9

Re: [REL] Automatic for funplug-0.5

notsee wrote:

download-limit => ""
upload-limit => ""
}

This speed limits

Offline

 

#478 2011-03-10 23:21:25

StealthOne
Member
Registered: 2011-03-10
Posts: 11

Re: [REL] Automatic for funplug-0.5

Can someone help me with my filter regex?

I want to match all TV episodes, but exclude high-def (720 or 1080) and seasons.

I can match the episode syntax:

Code:

filter = { pattern => "^([a-zA-Z0-9\.]+)\.S?(\d+)E?x?(\d+)\.(.*)$"
           folder => ""
         }

How do add some excludes in there?

Offline

 

#479 2011-03-10 23:43:26

KyleK
Member
From: Dresden, Germany
Registered: 2007-12-05
Posts: 1178

Re: [REL] Automatic for funplug-0.5

Check the very first post, update v0.3, INFO 2. It explains how to do excludes with regular expressions.

Offline

 

#480 2011-03-11 00:06:24

StealthOne
Member
Registered: 2011-03-10
Posts: 11

Re: [REL] Automatic for funplug-0.5

Yes, I saw that, and I hate to sound stupid but I'm not sure how to combine my positive match with the negative exclusions.  Do I just add a separate filter expression for the negatives?

filter = { pattern => "^([a-zA-Z0-9\.]+)\.S?(\d+)E?x?(\d+)\.(.*)$" }
filter = { pattern => "(?!.*720p)*." }
filter = { pattern => "(?!.*1080i)*." }

Or is there a way to combine everything into one regex expression.

Offline

 

#481 2011-03-11 00:16:50

KyleK
Member
From: Dresden, Germany
Registered: 2007-12-05
Posts: 1178

Re: [REL] Automatic for funplug-0.5

No, you just put the exclusion at the very front:

Code:

filter = { pattern => "^(?!.*720p)(?!.*1080p)([a-zA-Z0-9\.]+)\.S?(\d+)E?x?(\d+)\.(.*)$" }

For stuff like this, http://weitz.de/regex-coach/ is your friend smile

Last edited by KyleK (2011-03-11 00:17:37)

Offline

 

#482 2011-03-11 00:19:57

StealthOne
Member
Registered: 2011-03-10
Posts: 11

Re: [REL] Automatic for funplug-0.5

Excellent, thanks KyleK.

Offline

 

#483 2011-03-23 14:32:04

ckarv
Member
Registered: 2011-02-07
Posts: 13

Re: [REL] Automatic for funplug-0.5

Is it possible to filter torrents to folders according to the tracker?

Offline

 

#484 2011-03-23 16:10:58

KyleK
Member
From: Dresden, Germany
Registered: 2007-12-05
Posts: 1178

Re: [REL] Automatic for funplug-0.5

I'm afraid not. Automatic doesn't know anything about the trackers of a torrent.
How would this work if there are multiple trackers in a torrent (the normal case for public torrents, I would say)?

You can currently specify a download folder per pattern or filter, and separate folders per feed is on the to-do list.

Offline

 

#485 2011-03-23 18:27:21

FunFiler
Member
Registered: 2010-05-23
Posts: 577

Re: [REL] Automatic for funplug-0.5

You can run multiple configuration files and have different feeds/filters/file paths in each.

I haven't tried running separate (multiple) installs yet, but in theory, that too should be possible, but I do run different configuration files at different times of the day/night.

This may not completely address your issue, but it may help you sort things at least by feed.

Last edited by FunFiler (2011-03-23 18:28:39)


3 * (DNS-323 with 2 * 2TB) = 12TB Running FW v1.08 & FFP v0.5
Useful Links: Transmission, Transmission Remote, Automatic

Offline

 

#486 2011-03-24 12:05:48

ckarv
Member
Registered: 2011-02-07
Posts: 13

Re: [REL] Automatic for funplug-0.5

Thanks for the answers, I'll see what I can do with them smile

Offline

 

#487 2011-03-26 02:10:25

clueo8
Member
Registered: 2011-03-26
Posts: 5

Re: [REL] Automatic for funplug-0.5

Question: Will the interval in automatic's config mess with any of the HARD DRIVE HIBERNATION SETTINGS when it's checking feeds?  Is it going to keep my DNS-321 from saving energy?

Offline

 

#488 2011-03-26 02:25:41

FunFiler
Member
Registered: 2010-05-23
Posts: 577

Re: [REL] Automatic for funplug-0.5

Anything that accesses the disk will cause it to spin up (or not spin down). You can mitigate the effects if you aren't seeding, write logs to a USB flash drive, etc


3 * (DNS-323 with 2 * 2TB) = 12TB Running FW v1.08 & FFP v0.5
Useful Links: Transmission, Transmission Remote, Automatic

Offline

 

#489 2011-03-26 17:07:37

clueo8
Member
Registered: 2011-03-26
Posts: 5

Re: [REL] Automatic for funplug-0.5

I can't figure out why my crontab isn't kicking off automatic correctly, I get this (in my /ffp/var/logs/automatic.log) when trying to start it:

Code:

/ffp/start/automatic.sh: line 13: tr: not found
Starting /ffp/bin/automatic 
Error parsing config file: Cannot find file '/etc/automatic.conf'
[11/03/26 11:02:02] ../src/automatic.c, 133: Shutting down daemon

crontab entry is:

Code:

02 11 * * * /ffp/start/automatic.sh start >> /ffp/var/logs/automatic.log 2>&1

automatic.sh is:

Code:

#!/ffp/bin/sh

# PROVIDE: Automatic
# REQUIRE: Transmission

. /ffp/etc/ffp.subr

name="automatic"
command="/ffp/bin/$name"
required_files="/ffp/etc/automatic.conf"
automatic_flags="-o -a -c /ffp/etc/automatic.conf -l /mnt/HD_a2/.transmission-daemon/automatic.log"

run_rc_command "$1"

I'm trying to get automatic to just run once off my crontab...

Offline

 

#490 2011-03-26 22:34:41

FunFiler
Member
Registered: 2010-05-23
Posts: 577

Re: [REL] Automatic for funplug-0.5

When things run in a cron job, the environment is not the same.

If I recall correctly, I had to modify /ffp/etc/ffp.subr to include the full path to "tr"

Code:

eval _flags=\$$(echo $_cmd | /ffp/bin/tr '.-' '_')_flags

3 * (DNS-323 with 2 * 2TB) = 12TB Running FW v1.08 & FFP v0.5
Useful Links: Transmission, Transmission Remote, Automatic

Offline

 

#491 2011-03-27 17:58:55

clueo8
Member
Registered: 2011-03-26
Posts: 5

Re: [REL] Automatic for funplug-0.5

That worked!  Thanks!

One other thing I'm noticing is that the time (unix date command) in the command prompt does not reflect the time shown in the Dlink web-admin Tools > Time.  The NTP server is off by 1 hour in web-admin, then off 4 hours in command prompt... When I set it to my computer time, it looks right in web-admin, but off by 5 hours in command prompt.  Sometimes I could trick it by changing the time-zone, but the next day it goes back to the wrong time in the command prompt (but it worked after a reboot for some reason?)... Is there a correct way to set the time correct so my crontabs can execute when I expect them to?

Offline

 

#492 2011-03-27 19:35:13

FunFiler
Member
Registered: 2010-05-23
Posts: 577

Re: [REL] Automatic for funplug-0.5

There is a whole thread on correcting the time. But if you get rid of all the time update (rtc & settime) commands then you can resolve the time issues by setting the correct TZ value for your location. Example for Eastern Time:

Code:

echo "EST5EDT,M3.2.0,M11.1.0" > /etc/TZ

3 * (DNS-323 with 2 * 2TB) = 12TB Running FW v1.08 & FFP v0.5
Useful Links: Transmission, Transmission Remote, Automatic

Offline

 

#493 2011-03-28 01:38:16

clueo8
Member
Registered: 2011-03-26
Posts: 5

Re: [REL] Automatic for funplug-0.5

In my fun_plug.local, I have:

Code:

# This removes firmware cronjobs that interfere with ntpd.
crontab -l | grep -vw '/usr/sbin/stime' | grep -vw '/usr/sbin/rtc' | crontab -

# USA/EST
echo "EST5EDT,M3.2.0,M11.1.0" > /etc/TZ

But it still appears my time is 1 hour off...

I saw in another article that you can set a cron to keep the time, but I don't want that to have to keep running every hour...  Is there anything I'm missing?

My current crontab only has these entries after the removal above:

Code:

*/10  *  *  *  * ddns-start&
*/60  *  *  *  * /usr/sbin/getdhcp&

Offline

 

#494 2011-04-01 11:12:07

Shades
Member
Registered: 2009-02-23
Posts: 14

Re: [REL] Automatic for funplug-0.5

I'm wondering if it's possible to do an action on the file that gets downloaded from the rss. All my files gets named blabla.nzb;

I'm using automatic to fetch nzb files. For the nzbprog to add the nzb to the queue, it needs to be called nzb without the semicolon.

So, I'm wondering if it's possible to an automatic rename after download. Also, I don't really know why it gets called .nzb; I think when I download a file with a regular webbrowser, the semicolon isn't there. Is there something fishy with automatic?

Offline

 

#495 2011-04-01 13:41:40

FunFiler
Member
Registered: 2010-05-23
Posts: 577

Re: [REL] Automatic for funplug-0.5

Automatic just passes the torrent to Transmission. Transmission can perform an action (like a script to parse and rename files) after a download completes. If there is an issue, then you need to look at Transmission, not Automatic.


3 * (DNS-323 with 2 * 2TB) = 12TB Running FW v1.08 & FFP v0.5
Useful Links: Transmission, Transmission Remote, Automatic

Offline

 

#496 2011-04-01 13:52:46

Shades
Member
Registered: 2009-02-23
Posts: 14

Re: [REL] Automatic for funplug-0.5

I use automatic to put the downloaded file, in this case a .nzb file in a directory. Nzbget then gets the file by checking for new .nzb files in that directory. But since automatic names the file .nzb; it will not download the file.

So it doesn't help me if transmission can do stuff with the file, since it's not a torrent file.

Offline

 

#497 2011-04-09 13:35:39

KyleK
Member
From: Dresden, Germany
Registered: 2007-12-05
Posts: 1178

Re: [REL] Automatic for funplug-0.5

@Shades: I don't understand. Automatic should load .nzb files from a RSS feed just fine. If the files have the extension .nzb in the feed XML, Automatic should save the files with that extension as well. So your NZB client shouldn't have any problems recognizing the file.

What exactly does not work in your case?

Offline

 

#498 2011-04-19 12:25:52

scarcow
Member
From: Hungary
Registered: 2008-10-10
Posts: 16

Re: [REL] Automatic for funplug-0.5

Can you please help me? http://redirect.karmorra.info/8f5dd3b8d … 36.torrent in automatic reports as invalid or corrupted torrent file, but if i download it with wget, and transmission-remote -a, then it works ok. What can be the problem?

-sc

edit: here is the rss feed from where i get it: http://showrss.karmorra.info/rss.php?us … roper=null

Last edited by scarcow (2011-04-19 12:28:14)

Offline

 

#499 2011-04-19 13:44:56

FunFiler
Member
Registered: 2010-05-23
Posts: 577

Re: [REL] Automatic for funplug-0.5

The easiest way to figure out what is going on is usually to increase the verbosity of the debug log file and see what it says. Try level 2 or 3.


3 * (DNS-323 with 2 * 2TB) = 12TB Running FW v1.08 & FFP v0.5
Useful Links: Transmission, Transmission Remote, Automatic

Offline

 

#500 2011-04-19 22:47:23

KyleK
Member
From: Dresden, Germany
Registered: 2007-12-05
Posts: 1178

Re: [REL] Automatic for funplug-0.5

I found the cause of the problem you're experiencing and will put up a bugfix tomorrow.

Offline

 

Board footer

Powered by PunBB
© Copyright 2002–2010 PunBB