Linux Netfilter discussions
 help / color / mirror / Atom feed
* (no subject)
@ 2024-07-25  0:10 Tom Isaacson
  2024-07-25  0:34 ` Unknown option "--to-ports" Tom Isaacson
  0 siblings, 1 reply; 7+ messages in thread
From: Tom Isaacson @ 2024-07-25  0:10 UTC (permalink / raw)
  To: netfilter

Apologies if this is a stupid question but I'm stuck. We have an
embedded Linux ARM device built with Yocto Kirkstone. It has an LTE
modem (connected via USB) and Wifi. These are both working fine but I
wanted to setup a Wifi access point that shares the internet access
from LTE. A colleague suggested https://github.com/oblique/create_ap
but when I run it I get:
    # create_ap -w 2 wlan0 wwan0 APTest 12345678
    Config dir: /tmp/create_ap.wlan0.conf.XX59Vdf8
    PID: 537195
    Network Manager found, set wlan0 as unmanaged device...
[46988.754925] ieee80211 phy1:         DONE
    Sharing Internet using method: nat
    iptables v1.8.7 (legacy): unknown option "--to-ports"
    Try `iptables -h' or 'iptables --help' for more information.
    Doing cleanup.. done

The offending iptables commands are:
            iptables -w -t nat -D PREROUTING -s ${GATEWAY%.*}.0/24 -d
${GATEWAY} \
                -p tcp -m tcp --dport 53 -j REDIRECT --to-ports $DNS_PORT
            iptables -w -t nat -D PREROUTING -s ${GATEWAY%.*}.0/24 -d
${GATEWAY} \
                -p udp -m udp --dport 53 -j REDIRECT --to-ports $DNS_PORT

I searched around for a solution and found
https://community.unix.com/t/iptables-v1-8-7-nf-tables-unknown-option-to-ports/385377/3
but this command also fails:
    # iptables -A OUTPUT -m owner --uid 0
    iptables v1.8.7 (legacy): Couldn't load match `owner':No such file
or directory

iptables links to xtables-legacy-multi but it seems to have all of the
necessary files present. This
https://github.com/istio/istio/issues/23279#issuecomment-620776006
said iptables had been fixed in 1.8.4, but we have 1.8.7 so I don't
think we need to upgrade. Is there a kernel configuration we're
missing?

Thanks for any help.

Tom Isaacson

-- 


*For more information on how and why we collect your personal 
information, please visit our Privacy Policy 
<https://www.motorolasolutions.com/en_us/about/privacy-policy.html?elqTrackId=8980d888905940e39a2613a7a3dcb0a7&elqaid=2786&elqat=2#privacystatement>.*

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2024-07-29  7:23 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-07-25  0:10 Tom Isaacson
2024-07-25  0:34 ` Unknown option "--to-ports" Tom Isaacson
2024-07-25  2:19   ` Florian Westphal
2024-07-25  2:29     ` Tom Isaacson
2024-07-28 16:58       ` Reindl Harald
2024-07-29  5:44         ` Tom Isaacson
2024-07-29  7:23           ` Reindl Harald

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox