My notepad

Chris' IT notes…
← Back

Ping on WSL

Do we really need to be root to simply to a ping from your WSL on Windows?
Apparently yes.
You have probably faced the following error:

text
ping: socktype: SOCK_RAW
ping: socket: Operation not permitted
ping: => missing cap_net_raw+p capability or setuid?

Wanna fix it?

sh
sudo setcap cap_net_raw+ep /bin/ping

Run this command once, and the command ping will be "usable" again ;)

Happy ping'ing! ;-)