Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Gnote just crashed and erased a good part of a note which wasn't oppened when the crash occured. I can't undo this change so it seems to be a permanent loss... How can I recover it and make sure it doesn't happen again?

The error showed up in the terminal I opened Gnote with:

(gnote:2425): GLib-GIO-CRITICAL **: GApplication subclass 'GnoteApp' failed to chain up on ::startup (from start of override function)

(gnote:2425): Gtk-CRITICAL **: gtk_text_buffer_get_iter_at_mark: assertion `GTK_IS_TEXT_MARK (mark)' failed
Segmentation fault (core dumped)

EDIT: It happened again and the following output was given in the command line.

For this one, I just opened Gnote, opened one note, write a sentence in it and close it, then close Gnote.

(gnote:3570): GLib-GIO-CRITICAL **: GApplication subclass 'GnoteApp' failed to chain up on ::startup (from start of override function)

** (gnote:3570): WARNING **: GDBus.Error:org.gtk.GDBus.UnmappedGError.Quark._g_2dfile_2derror_2dquark.Code12: Failed to write file '/home/romain/.config/dconf/user.QFB8KW': fwrite() failed: No space left on device

** (gnote:3570): WARNING **: GDBus.Error:org.gtk.GDBus.UnmappedGError.Quark._g_2dfile_2derror_2dquark.Code12: Failed to write file '/home/romain/.config/dconf/user.5QK8KW': fwrite() failed: No space left on device

** (gnote:3570): WARNING **: GDBus.Error:org.gtk.GDBus.UnmappedGError.Quark._g_2dfile_2derror_2dquark.Code12: Failed to write file '/home/romain/.config/dconf/user.J3Q8KW': fwrite() failed: No space left on device

** (gnote:3570): WARNING **: GDBus.Error:org.gtk.GDBus.UnmappedGError.Quark._g_2dfile_2derror_2dquark.Code12: Failed to write file '/home/romain/.config/dconf/user.S7I7KW': fwrite() failed: No space left on device

** (gnote:3570): WARNING **: GDBus.Error:org.gtk.GDBus.UnmappedGError.Quark._g_2dfile_2derror_2dquark.Code12: Failed to write file '/home/romain/.config/dconf/user.0JP7KW': fwrite() failed: No space left on device
I/O error : No space left on device
I/O error : write error

In this one, I re-opened Gnote, found the note I'd just changed was empty, its title erased too...

(gnote:4277): GLib-GIO-CRITICAL **: GApplication subclass 'GnoteApp' failed to chain up on ::startup (from start of override function)
(140417336494528) ERROR: error_handler - XML error Extra content at the end of the document

I/O error : No space left on device
I/O error : No space left on device
I/O error : No space left on device
I/O error : No space left on device

And I noticed that my Ubuntu partition was full, so I moved heavy personal files in another data partition.

Thanks a lot.

share|improve this question
    
Please explain after you downvote... –  L01man Sep 22 '12 at 17:21
    
My guess: "how can I recover it?" and "how can I prevent it?" are two different questions, neither of which do you seem to have attempted to research on your own. What have you tried already? Where are you getting stuck? –  techie007 Sep 22 '12 at 18:03
    
I did search. No clue for recovering since the file has not been deleted but edited (against my will) and the error message and other queries such as "gnote lost data" or "gnote bug" don't give any link. On my own, I'll just delete gnote, use gedit, do lots of backups, and rewrite the file by memory, even if it was very long... –  L01man Sep 22 '12 at 18:07
    
I did some research and it seems a flag in the kernel limits my access to programs' memories, for example. Thus, I can't recover the note frome Gnote! Can I change the flag without rebooting? If I reboot, will the note be definitely erased or will it still be in /dev/mem, if it is in the first place? –  L01man Sep 27 '12 at 19:32
add comment

1 Answer

As soon as you notice the crash, you could try to recover whatever you had typed from your memory (if it is not encrypted). As root, open the file /dev/mem and try to locate some chunk of you lost sentences. For example, you could use:

less -f /dev/mem

To avoid this kind of crash, it is another matter.

share|improve this answer
    
Thank you, but the file is just too long. There is at least a week of activity recorded on it and it has mainly black characters I don't understand and very little typed characters. Anyway, what was on the note was not just typed, but written on various dates. –  L01man Sep 22 '12 at 19:26
    
Is there a way to discard the non-typed characters from /dev/mem? Using grep or something like that? –  L01man Sep 22 '12 at 19:38
    
It happened again, on a different note, which I opened it to copy to a safe place... Anyway, hoping to recover this other very important data, I did cat /dev/mem > mem, mem being a file which now holds 1028kB of data. Isn't it strange that the file is so small, since /dev/mem should be tens of times bigger? If it is, how can I save /dev/mem entirely? Then, do I use grep the same way I do with files that are not binaries, to find my "sentence chunks". In fact, I hope the note which Gnote destroyed is still in /dev/mem, but I'm not sure if /dev/mem contains things such as loaded files. –  L01man Sep 27 '12 at 19:17
    
@L01man: cat /dev/mem reads to the first EOF, you'll want to use something aware of EOFs that removes the EOFs from the stream before piping it into a file. –  Tom Wijsman Sep 29 '12 at 22:05
    
@TomWijsman When I find this command, I'll post it here. –  L01man Sep 30 '12 at 7:39
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.