I'm unable to log incoming (LAN) traffic on port 32400 (Plex)

Hi,

I am trying to log every connection attempt to port 32400 so that I can run a bash script that will send a Wake Up Lan packet to my Plex server if somebody attempt to connect to it.

I'm based my work on this guy :https://www.reddit.com/r/PleX/comments/3f7d0u/plex_wol_my_setup/

I've adapted my script and that part is alright

However, I can't for the life of me understand why iptables is not logging anything... Here's my rule.

iptables -I FORWARD -i br-lan -p tcp --dport 32400 -m conntrack --ctstate NEW -j LOG --log-prefix "PLEX LAN Connection "

I've also tried those ones :
#iptables -I FORWARD -p tcp --dport 32400 -m conntrack --ctstate NEW -j LOG --log-prefix "PLEX LAN Connection "
#iptables -I INPUT -p tcp -m tcp --dport 32400 -m conntrack --ctstate NEW -j LOG --log-level 1 --log-prefix "PLEX LAN Connection "

Nothing coming up in "logread".

I thought maybe it was iptables that wasn't logging there so I added this rule :
iptables -I INPUT 1 -j LOG

The logread is loaded so it really is logging at that place. I notice however that there's only packet to/from the outside world there and nothing from my LAN.

Is there a LEDE or iptables genius here that can help me?

Regards,

Anybody can help log incoming plex traffic?

Your iptables command is different from the one in the article...

Article -

iptables -I FORWARD -i br0 -p tcp --dport 32400 -m state --state NEW -j LOG --log-prefix "PLEX LAN Connection "

Yours -

iptables -I FORWARD -i br-lan -p tcp --dport 32400 -m conntrack --ctstate NEW -j LOG --log-prefix "PLEX LAN Connection "

That's because in the new version of iptable « -m state » is being replaced with «-m conntrack --ctstate» (According to https://github.com/nodogsplash/nodogsplash/issues/180)

Here's what I get from the original script.
root@LEDE:~# iptables -I FORWARD -i br0 -p tcp --dport 32400 -m state --state NEW -j LOG --log-prefix "PLEX LAN Connection "
iptables v1.6.1: Couldn't load match `state':No such file or directory

Thanks for your help.

Regards,

See this github article...

Yes, I actually linked to this post in my previous reply.

I didn't click on your link...just did a search on the error message.