iptables v1.6.0: can't initialize iptables -F: Permission denied (you must be root)

0 votes

Hi Guys,

I am trying to run iptables program inside docker container, but it shows me the below error.

iptables v1.6.0: can't initialize iptables -F: Permission denied (you must be root)

How can I solve this error?

May 12 in Docker by akhtar
• 11,270 points
44 views

1 answer to this question.

0 votes

Hi@akhtar,

You may get this error, if you didn't give permissions to your container at the time of launching. You can use the below tag at the time of docker run.

$ docker run -it --privileged centos

Hope this will help.

answered May 12 by MD
• 24,500 points

Related Questions In Docker

0 votes
1 answer

Error saying "E: This command can only be used by root." while installing docker

Try executing the following command: sudo su and ...READ MORE

answered Aug 6, 2019 in Docker by Ahmad
1,160 views
0 votes
1 answer

E: Could not open lock file /var/lib/dpkg/lock-frontend - open (13: Permission denied)

Hi@akhtar, To install any software using non root ...READ MORE

answered 1 day ago in Docker by MD
• 24,500 points
20 views
0 votes
2 answers

Can't access apache karaf docker container

To access karaf shell directly you can ...READ MORE

answered Aug 6, 2018 in Docker by Nilesh
• 6,960 points
443 views
0 votes
1 answer
0 votes
1 answer

Deploy Docker Containers from Docker Cloud

To solve this problem, I followed advice ...READ MORE

answered Sep 3, 2018 in AWS by Priyaj
• 57,530 points
542 views
0 votes
1 answer

-su: cd: /root/: Permission denied

Hi@akhtar, You are trying to run your command ...READ MORE

answered 1 day ago in Docker by MD
• 24,500 points
15 views
0 votes
1 answer

error: permission denied in docker ?

Hi@akhtar, This is because of docker permission for ...READ MORE

answered Mar 23 in Docker by MD
• 24,500 points
176 views