try using an elevated privilege like this

sudo service NetworkManager restart

I tried this and it worked for me