Code:
apt-get install wireshark
sudo apt-get install libcap2-bin
sudo dpkg-reconfigure wireshark-common
sudo gpasswd -a pi wireshark
sudo usermod -a -G wireshark pi
sudo chmod 750 /usr/bin/dumpcap
sudo setcap cap_net_raw,cap_net_admin=eip /usr/bin/dumpcap