gedit doesn't save, only starting it with a "sudo gedit" you have the ability to save.

Asked by Zeroc00l

Binary package hint: gedit

release: Ubuntu 8.04, Hardy Heron

version: gedit: Instaled: 2.22.1-0ubuntu1 Candidate: 2.22.1-0ubuntu1

"The Save button doesn't function, only if you open gedit with a sudo command will enable the button"

Thx anticipately.

ProblemType: Bug
Architecture: i386
Date: Tue Apr 22 15:38:41 2008
DistroRelease: Ubuntu 8.04
ExecutablePath: /usr/bin/gedit
NonfreeKernelModules: nvidia
Package: gedit 2.22.1-0ubuntu1
PackageArchitecture: i386
SourcePackage: gedit
Uname: Linux 2.6.24-16-generic i686

Question information

English Edit question
Ubuntu gedit Edit question
No assignee Edit question
Last query:
Last reply:
Revision history for this message
Zeroc00l (joekill) said :
Revision history for this message
Pedro Villavicencio (pedro) said :

Thank you for your comments. This does not appear to be a bug report and we are closing it. We appreciate the difficulties you are facing, but it would make more sense to raise your question in the support tracker.

Revision history for this message
Harvey Muller (hlmuller) said :


It looks like you are trying to modify a file owned by the root user. In this case, you are correct, you have to open the file as the root user, which is done by:

    $ gksu gedit /path/to/file

It is recommended that you use gksu instead of sudo when opening a gnome application as root.

If you run in a terminal:

    $ ls -l /path/to/file

It will show you who owns the file. If root is listed, then you have to open the file as root. Otherwise, you should be able to open, edit, and save any file created by you.

Please return to this question and mark it Solved if this answers your question, or if you need further information regarding the original question.



Revision history for this message
Bhavani Shankar (bhavi) said :


While editing files in ubuntu (except those of user related and those in /home folder to be precise) you need to have superuser/administrative privileges to edit and save files.. Since the superuser privileges are disabled by default you use the sudo command as a prefix to achieve the same purpose

Hope it answers your doubt... :)


Bhavani Shankar.

Revision history for this message
Zeroc00l (joekill) said :

Thanks for the answers, but what I want say is that also if I start a new document with gedit I can't save it, and I assure you that I am the administrator of the pc, I can make all, except install/remove programs that I use inserting my user password.

Hope that this help.

Revision history for this message
Harvey Muller (hlmuller) said :


Couple questions.

1. How are you starting gedit?

2. Have you installed any gedit plugins recently?

If you reinstall gedit does it still display that behavior?

  $ sudo aptitude reinstall gedit

Please let me know if this resolves the issue.



Revision history for this message
Zeroc00l (joekill) said :

Thanks Harvey, I'll answer all your questions:

1: I'm starting it just clicking on the icon in Applications Menu, and I assure you that with alacarte just I saw if the command line was mistyped.

2: no plugins installed a part the orignal ones

3: I tried to reinstall a couple days ago, but nothing resolve this problem

PS: Now I'm typing from another pc with Ubuntu Hardy and I verified if there's this problem with gedit, and obviuosly it seems a problem that only I have with the other pc, because in this it just function. Perhaps it's only a galactic bug that happens in some conditions and in some days of the year ^_^.

Revision history for this message
dan od (dan-odonovan+ubuntu) said :

Hey there,

This does sound like some kind of write permissions mixup. One thing to try;
If gedit can't save files (when you're not root) can other apps?
Maybe try:

$ touch test.file

in your home directory without sudo - if that creates a test.file then your write permissions seem ok and we should look more closely at gedit. If that asks for an administrator password then maybe you could check your $HOME directory access rights:

$ ls -la /home

and post back

Hope you get it fixed soon, Dan

Revision history for this message
Zeroc00l (joekill) said :

Hi dan, thanks for the help

However your question are all answered with an "Yes" everything seems right, I can make everything in my home, last day I try to cancel everything in my home that was hidden, like setups of gnome and other things, just to make Ubuntu clean after all these aupdates, I remember that my installation isn't so clean, but it's just an update of an update from Alpha 5 8.04 to the release 8.04.

However gEdit doesn't function anyway. Mh perhaps something is misconfigured inside gedit, is there something to defaulting the app to the original state?


Revision history for this message
Launchpad Janitor (janitor) said :

This question was expired because it remained in the 'Open' state without activity for the last 15 days.