This is a static archive of our old Q&A Site. Please post any new questions and answers at ask.wireshark.org.

Wireshark setup Linux for nonroot user in Amazon Ec2

0

My goal is to capture packets with tshark in Amazon Linux AMI. While typing tshark in the command line there's an error: "tshark: There are no interfaces on which a capture can be done"

How to implement the solution :

> $ sudo apt-get install wireshark $
> sudo dpkg-reconfigure wireshark-common
> $ sudo usermod -a -G wireshark $USER $
> gnome-session-quit --logout --no-prompt

in Amazon Linux AMI (it's not Ubuntu)? Thanks.

asked 29 Oct '13, 08:52

warrior7089's gravatar image

warrior7089
1113
accept rate: 0%

edited 29 Oct '13, 08:53


One Answer:

1

How to implement the solution in Amazon Linux AMI (it's not Ubuntu)?

Amazon AMI is based on CentOS.

So, please do this:

yum install wireshark
yum install wireshark-gnome

or maybe for AMI

yum install wireshark-1.2.15

then set the capabilities for dumpcap

sudo setcap 'CAP_NET_RAW+eip CAP_NET_ADMIN+eip' /usr/bin/dumpcap

Then run the following command as non root user!

dumpcap -D -M

If you see interfaces: problem solved!

Regards
Kurt

answered 31 Oct '13, 04:24

Kurt%20Knochner's gravatar image

Kurt Knochner ♦
24.8k1039237
accept rate: 15%

edited 31 Oct '13, 04:25

Thanks. It works.

(31 Oct '13, 04:47) warrior7089

good.

Hint: If a supplied answer resolves your question can you please "accept" it by clicking the checkmark icon next to it. This highlights good answers for the benefit of subsequent users with the same or similar questions.

(31 Oct '13, 04:49) Kurt Knochner ♦