12

I am using software called Gnome Sound Recorder to record some audio. However, it gives me no options to do anything with the recordings aside from deleting it. I have looked high and low for the file, even using the whereis command and poking around in the corresponding directories, but have found nothing. Any help would be greatly appreciated--I recorded a half hour long recording and don't want to lose it!

Here is a screenshot: enter image description here

  • 3
    On my system it just puts the recordings in /home/username/Recordings by default. – n8te Apr 8 '17 at 3:32
  • @n8te YESSSSSSSSSSS THANK YOU SO MUCH OH MY GOD LIFE SAVER please put your answer as an answer so i can give you rep!!! – Joseph Farah Apr 8 '17 at 3:34
  • 1
    No problem. Glad you found it. – n8te Apr 8 '17 at 3:37
  • @JosephFarah: whereis doesn't look for audio files as far as I know. Perhaps you meant locate... – Francesco Turco Apr 8 '17 at 17:12
  • @FrancescoTurco excellent point! I used whereis to find the folder that the command was run from in order to search for the file at that location. I did not use it to directly search for the audio file. – Joseph Farah Apr 9 '17 at 0:34
12

n8te commented that the files are in the subdirectory Recordings of your home directory. My answer covers how to find the files if the application doesn't give you a clue.

While an application has the file open, you can use lsof to locate it. Note that this only works while the file is open at the operating system level, which may not always be the case while the application displays the file. For example a text or image editor typically opens the file to read or save it, but closes it immediately after each load or save operation. But I would expect a sound recorder to write progressively to the output file, and for that it would keep the file open as long as it's recording.

To find what files an application has open, first install lsof. It's available as a package on most distributions. Open a terminal; all my instructions use the command line. You'll need to determine the process ID of the application. You can run the command ps xf (that's on Linux; other Unix variants have different options for the ps command; as a last resort you can use ps -e to list everything). Try pgrep sound ps x | grep -i sound to locate all the running programs whose name contains “sound”. Alternatively, run xprop | grep _NET_WM_PID and click on the program window. Once you've determined the process ID, for example 1234, run

lsof -p1234

Another approach is to look for recently modified files. You can use the find command for that. For example, to look for files modified in the last 5 minutes:

find ~ -type f -mmin -5

~ means your home directory. A saved file would normally be in your home directory because that's the only location where an application is guaranteed to be able to write, except for temporary files that can be wiped out as soon as the application exits. -type f restricts to regular files (we don't need to see directories here) and -mmin 5 means “less than 5 minutes ago”. There's also -mtime which counts in days instead of minutes. If you're looking for a file that's been moved rather than created or modified, use -cmin instead of -mmin; the ctime is the time at which anything was last done on the file except for reading it (but including changing permissions, moving, etc.). You can also look for files by name, e.g.

find ~ -name '*blendervid*' -type f

looks for files whose name contains blendervid (and you can add something like `-mmin -5 further restrict matches to recent files).

If you know part of the name of a file and the file was created a while ago, you can use the locate command.

locate blendervid

locate is a lot faster than find because it uses a pre-built index. But it can only find files that existed when the index was built. Most distributions arrange for the index to be rebuilt every night, or soon after boot (via anacron) if the system isn't always on.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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