Idea: Dynamic priority process
|
12th Aug, 2013, 04:02 PM
Post: #18
|
|||
|
|||
RE: Dynamic priority process
(26th Jul, 2013 11:17 PM)belese Wrote: ps : belese, as always too late, but still maybe you use in future. with standard netfilter it's easy as: Code: root@media:/var/log# iptables -L -n -v normally those chains are meant for firewalling / routing, but we can downsize it's function to just count packets / bytes. so if you want to monitor for instance port 22 (ssh), add a rule to ACCEPT Code: iptables -I INPUT -j ACCEPT -p tcp --dport 22 with result Code: root@media:/var/log# iptables -L -n -v you can poll this numbers with grep or let it send to a file descriptor (opened by variant of your python script which listens to the xbmc events). from this point of view, it;s the same. you just use LOG policy instead of accept. and to get rid of calculations in the bridge script, you can directly define priority targets directly in netfilter, what means according to current bandwidth (not only absolute pkt/bytes numbers) to MARK and then LOG. so at the end you would have in input chain four rules, with target MARK, described not by port number but RATE, followed by one rule to LOG, which would on some transfer send a human readable text line MARKed already according your priority split. so the bridge daemon would be just a loop with case and initctl emit. Please read rules and do a search before you post! . FAQs . How to post log file? . Looking for answers? Please start here |
|||
« Next Oldest | Next Newest »
|
Messages In This Thread |
Dynamic priority process - belese - 13th Jul, 2013, 12:25 AM
RE: Dynamic priority process - Fred - 13th Jul, 2013, 01:00 AM
RE: Dynamic priority process - belese - 13th Jul, 2013, 01:11 AM
RE: Dynamic priority process - mk01 - 18th Jul, 2013, 05:10 AM
Re: Dynamic priority process - f1vefour - 13th Jul, 2013, 07:44 AM
RE: Dynamic priority process - Fred - 13th Jul, 2013, 07:57 AM
RE: Dynamic priority process - belese - 13th Jul, 2013, 07:09 PM
RE: Dynamic priority process - Fred - 13th Jul, 2013, 08:57 PM
RE: Dynamic priority process - mk01 - 17th Jul, 2013, 05:52 AM
RE: Dynamic priority process - belese - 17th Jul, 2013, 07:33 PM
RE: Dynamic priority process - belese - 18th Jul, 2013, 09:32 AM
RE: Dynamic priority process - mk01 - 19th Jul, 2013, 06:42 AM
RE: Dynamic priority process - belese - 18th Jul, 2013, 10:40 PM
RE: Dynamic priority process - belese - 25th Jul, 2013, 05:58 AM
RE: Dynamic priority process - CurlyMo - 25th Jul, 2013, 08:25 AM
RE: Dynamic priority process - belese - 25th Jul, 2013, 06:32 PM
RE: Dynamic priority process - belese - 26th Jul, 2013, 11:17 PM
RE: Dynamic priority process - mk01 - 12th Aug, 2013 04:02 PM
RE: Dynamic priority process - belese - 13th Aug, 2013, 01:35 AM
RE: Dynamic priority process - mk01 - 13th Aug, 2013, 02:36 AM
RE: Dynamic priority process - belese - 14th Aug, 2013, 02:47 AM
RE: Dynamic priority process - mk01 - 14th Aug, 2013, 03:37 AM
RE: Dynamic priority process - belese - 14th Aug, 2013, 05:19 AM
|