Think this might not be a raspbian issue as such. iptables-save is run with 
privileges but the redirection to the file is run by your existing shell 
which does not (necessarily) have sufficient privileges. Try using the same 
command and redirecting to /var/tmp/iptables.ipv4.nat (or some other widely 
writable directory), it will work just fine. Solution remains the same, run 
it as root with su.

Gary

On Saturday, 5 January 2019 13:28:38 UTC+10, Scott Grayban wrote:
>
> sudo won't work correctly for some reason for certain commands in raspbian.
>
> On Friday, January 4, 2019 at 7:21:17 PM UTC-8, Zsolt Máté wrote:
>>
>> Thanks, I was running it with sudo.
>>
>> On Saturday, January 5, 2019 at 4:17:32 PM UTC+13, Scott Grayban wrote:
>>>
>>> Run that as root
>>> On Jan 4, 2019, at 7:15 PM, "Zsolt Máté" <[email protected]> wrote:
>>>>
>>>> I can't execute sudo iptables-save > /etc/iptables.ipv4.nat
>>>> It returns:  -bash: /etc/iptables.ipv4.nat: Permission denied
>>>>
>>>>

-- 
You received this message because you are subscribed to the Google Groups 
"weewx-user" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to