Answer on Question - I am facing error with my internet connection
Above is the link to a fix to help with a loss of connection after power saving mode. It says "open with sudo..." How does one do that if one is a complete novice and knows nothing?
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It only takes a minute to sign up.
Sign up to join this communityAnswer on Question - I am facing error with my internet connection
Above is the link to a fix to help with a loss of connection after power saving mode. It says "open with sudo..." How does one do that if one is a complete novice and knows nothing?
The answer you provided in the link wants you to open a file with root privileges, which can be achieved using these two commands
sudo nano /path/to/your/file.foo
in the command above you are opening file.foo
in a command based text editing tool called nano, In your particular case this command should work.
sudo nano /etc/NetworkManager/NetworkManager.conf
gksu gedit /path/to/your/file.foo
In this command you're opening the same file with a GUI based text editor called Gedit (default on Ubuntu and Ubuntu GNOME), In your particular case, this command should work
gksu gedit /etc/NetworkManager/NetworkManager.conf
Note
Use sudo
for command line programs (like nano
), but use gksu
or gksudo
for GUI programs, which often use configuration files in the home directory. If you use plain sudo, the root user can take ownership or your user ID's configuration files and the program used that way will stop working (unless you continue using sudo
). An alternative to gksu
and gksudo
is sudo -H
An explanation for commenting out is to add a hash #
sign in front of the line, in the example you gave, the line
dns=dnsmasq
should become
#dns=dnsmasq
sudo -H gedit
- because Wayland has stricter security policies and won't allow root to own a window in a non-root session. A workaround is to log out, then log in using the non-Wayland option.
sudo
for command line programs (like nano
), but use gksu
or gksudo
for GUI programs, which often use configuration files in the home directory. If you use plain sudo
, the root user can take ownership or your user ID's configuration files and the program used that way will stop working (unless you continue using sudo). An alternative to gksu
and gksudo
is sudo -H
That means open that file with say the text editor nano but ensure you use root powers to edit it or it won't save. How, do:
sudo nano /etc/NetworkManager/NetworkManager.conf
This is necessary because that file can only be edited by one with root privilege. You will be asked for your password which you have to give so the file will open in nano editor
.
After editing it to save it:
nano
but ensure you useroot powers
to edit it or it won't save. How, do:sudo nano /etc/NetworkManager/NetworkManager.conf
. This is necessary because that file can only be edited by one withroot power