Linux - SoftwareThis forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
When downloading photos directly from within a Gmail message, I noticed that instead of putting them in my home folder, Debian insisted on putting them time and again in /run/user/documents/1000/some_alphanumerical_name. Afterwards, I paid attention to always changing the download path to /home/Pictures, but if I do not do this, the system saves them in that /run directory. OK so...
1/ what does this run directory do? It only seems to save stuff in /run form within Gmail, not when downloading photos from a website
2/ it is filled with a lot of subdirectories, most of them empty. Can I just delete these files and directories in /run/user/ ?
3/ apparently they are created at boot, but do they ever get cleaned up, e.g. on a reboot?
The system is a Debian 10 buster, the browser I use is Firefox 88
When downloading photos directly from within a Gmail message, I noticed that instead of putting them in my home folder, Debian insisted on putting them time and again in /run/user/documents/1000/some_alphanumerical_name. Afterwards, I paid attention to always changing the download path to /home/Pictures, but if I do not do this, the system saves them in that /run directory. OK so...
Once upon a time, when you plugged in a memory stick, you mounted it somewhere like /media/usb0 and that's where you put your downloaded pictures. Nowadays when you plug in a memory stick, your file manager automatically mounts it somewhere like /run/media/yourname/the_stick's_manuafacturer's_name. I don't like this but people coming over from Windows apparently prefer it that way. They are used to the system doing everything for them..
Quote:
1/ what does this run directory do? It only seems to save stuff in /run form within Gmail, not when downloading photos from a website
2/ it is filled with a lot of subdirectories, most of them empty. Can I just delete these files and directories in /run/user/ ?
3/ apparently they are created at boot, but do they ever get cleaned up, e.g. on a reboot?
This tree is for temporary files that are created after boot and scrapped before shutdown. It's all on a ramdisk so there's no point in deleting anything. Besides, some of those directories get used in specific circumstances.
When downloading photos directly from within a Gmail message, I noticed that instead of putting them in my home folder, Debian insisted on putting them time and again in /run/user/documents/1000/some_alphanumerical_name. Afterwards, I paid attention to always changing the download path to /home/Pictures, but if I do not do this, the system saves them in that /run directory. OK so...
1/ what does this run directory do? It only seems to save stuff in /run form within Gmail, not when downloading photos from a website
2/ it is filled with a lot of subdirectories, most of them empty. Can I just delete these files and directories in /run/user/ ?
3/ apparently they are created at boot, but do they ever get cleaned up, e.g. on a reboot?
The system is a Debian 10 buster, the browser I use is Firefox 88
3.15. /run : Run-time variable data
3.15.1. Purpose
This directory contains system information data describing the system since it was booted. Files under this directory must be cleared (removed or truncated as appropriate) at the beginning of the boot process.
The purposes of this directory were once served by /var/run. In general, programs may continue to use /var/run to fulfill the requirements set out for /run for the purposes of backwards compatibility. Programs which have migrated to use /run should cease their usage of /var/run, except as noted in the section on /var/run.
Programs may have a subdirectory of /run; this is encouraged for programs that use more than one run-time file. Users may also have a subdirectory of /run, although care must be taken to appropriately limit access rights to prevent unauthorized use of /run itself and other subdirectories. [17]
3.15.2. Requirements
Process identifier (PID) files, which were originally placed in /etc, must be placed in /run. The naming convention for PID files is <program-name>.pid. For example, the crond PID file is named /run/crond.pid.
The internal format of PID files remains unchanged. The file must consist of the process identifier in ASCII-encoded decimal, followed by a newline character. For example, if crond was process number 25, /run/crond.pid would contain three characters: two, five, and newline.
Programs that read PID files should be somewhat flexible in what they accept; i.e., they should ignore extra whitespace, leading zeroes, absence of the trailing newline, or additional lines in the PID file. Programs that create PID files should use the simple specification located in the above paragraph.
System programs that maintain transient UNIX-domain sockets must place them in this directory or an appropriate subdirectory as outlined above.
As to why your distro and browser saves them to /run I can only guess, but it might have something to do with HOW you "save" or "download" them perhaps. Normally these kind of things are first copied to /tmp, then moved to the specified location (/home/user/downloads). My guess is that you are not "downloading" them, but doing something else.
Hi, thx for the replies and reference. So, if I put two and two together, I conclude:
1/ no worries, because it is all ramdisk and so the system creates and cleans it when needed
2/ nothing is significantly "wrong" with the system
3/ I will keep an eye on it to see which files it wants to save to /run
Zeebra may be on to something because the photos were included in a press release and amongst the options were "download" and "save to Drive" (= the windows cloud service). Now I am sure I clicked "download" but maybe it gets the images from "Drive".
So we learn something every single day.
If nothing has to be added further, we can consider this "solved"
Are you sure about the "documents" part of the path? Because that's something I've never seen before.
In other words, I only ever get /run/user/1000/..." paths.
1000 is the numerical ID of my "normal" user, you can check with the 'id' command.
FWIW, File save dialogs often propose the last location you used for a particular filetype, so just telling it once to save the file elsewhere might fix it for subsequent saves.
Often browsers have an option for the default download path.
Mine has a choice of a fixed path that I specify, or the last used directory.
That option can be found in the browser settings and can be changed to your preferred choice.
Are you sure about the "documents" part of the path? Because that's something I've never seen before.
In other words, I only ever get /run/user/1000/..." paths.
1000 is the numerical ID of my "normal" user, you can check with the 'id' command.
FWIW, File save dialogs often propose the last location you used for a particular filetype, so just telling it once to save the file elsewhere might fix it for subsequent saves.
You are right, I was working on my laptop and misquoted the path, the 1000 indeed comes first in the path, before the docs like for instance /run/user/1000/Docs/Y8AEM1456m
The "last used download location" is bypassed in that particular mail and that is what I found peculiar. Now, as far as I can tell the phenomenom only occurs on Debian10 (not on my laptop that runs Ubuntu) and only in certain press releases that are sent in some "mail chimp" style method. I will keep an eye on it.
The "last used download location" is bypassed in that particular mail and that is what I found peculiar. Now, as far as I can tell the phenomenom only occurs on Debian10 (not on my laptop that runs Ubuntu) and only in certain press releases that are sent in some "mail chimp" style method. I will keep an eye on it.
Could be a quirk of the mail client software used?
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.