Skip to content

Set TMPDIR to an app-local temp directory to not exaust /run#103

Open
Summertime wants to merge 1 commit intoflathub:masterfrom
Summertime:patch-1
Open

Set TMPDIR to an app-local temp directory to not exaust /run#103
Summertime wants to merge 1 commit intoflathub:masterfrom
Summertime:patch-1

Conversation

@Summertime
Copy link

See https://gitlab.gnome.org/GNOME/gnome-boxes/-/issues/1105 for more context.

By using the GLib default of /tmp, Boxes will write to the host directory /run/user/$USER/app/org.gnome.Boxes, which, when downloading large enough images, will completely fill the tmpfs and partially hose the system.

Telling GLib to use /var/tmp, this will be redirected by flatpak to the host directory ~/.var/app/org.gnome.Boxes/cache. For something that may be XX GB in size, this seems to be a safer choice.


I've only tested with Flatseal to make the env change.

See https://gitlab.gnome.org/GNOME/gnome-boxes/-/issues/1105 for more context.

By using the GLib default of `/tmp`, Boxes will write to the host directory `/run/user/$USER/app/org.gnome.Boxes`, which, when downloading large enough images, will completely fill the tmpfs and partially hose the system.

Telling GLib to use `/var/tmp`, this will be redirected by flatpak to the host directory `~/.var/app/org.gnome.Boxes/cache`. For something that may be XX GB in size, this seems to be a safer choice.
@flathubbot
Copy link
Contributor

Started test build 177857

@flathubbot
Copy link
Contributor

Build 177857 successful
To test this build, install it from the testing repository:

flatpak install --user https://dl.flathub.org/build-repo/161006/org.gnome.Boxes.flatpakref

"--talk-name=ca.desrt.dconf",
"--env=DCONF_USER_CONFIG_DIR=.config/dconf"
"--env=DCONF_USER_CONFIG_DIR=.config/dconf",
"--env=TMPDIR=/var/tmp"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is wrong, you don't want to override the tmpdir always, but rather the application should download the files in /var/tmp rather than /tmp

@felipeborges
Copy link
Collaborator

Sorry I didn't address this earlier. I have now posted a merge-request https://gitlab.gnome.org/GNOME/gnome-boxes/-/merge_requests/690

I can get this in 49.1.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants