XUbuntu: Can't edit text files: Permission denied

18,761

If you want to edit configuration files which require root privileges, you have to open application with root privileges. I opened Mousepad with root privileges by typing in terminal:

gksudo mousepad
Share:
18,761

Related videos on Youtube

Uplink10
Author by

Uplink10

Updated on September 18, 2022

Comments

  • Uplink10
    Uplink10 almost 2 years

    I am new to Linux, but I was under the impression that you can use GUI to edit text files I mean that is why GUI exists. I opened xrdp.ini and tried to edit it with Mousepad. When I try to save it I get Failed to save document. Permission denied.. I already used this method (How do I grant sudo privileges to an existing user?) to assign myself sudo permissions but I still can't edit this text file using GUI.

    • aastefanov
      aastefanov over 9 years
      Do you start the text editor with root privileges ( using sudo -s or starting it with sudo at the beginning of the command )?
    • Uplink10
      Uplink10 over 9 years
      I start it using Whisker Menu or Applications Menu, that is through GUI.
    • aastefanov
      aastefanov over 9 years
      Are you sure it's running with root permissions?
    • Uplink10
      Uplink10 over 9 years
      I am new to Ubuntu, so I really do not know.
    • aastefanov
      aastefanov over 9 years
      Well, it shows that mousepad isn't starting with root privileges when opening it from Whisker.
  • Damian Yerrick
    Damian Yerrick about 4 years
    gksudo is being removed from Ubuntu because Wayland has no close counterpart. For workarounds, see pkexec recipe and opening `admin:///etc/...' in apps using gvfs.