You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
bwrap: Can't make symlink at $HOME/Music: File exists #1971
Hey, I'm having the same problem on the same OS on the same version of flatpak. By removing the symlink Steam can work. If I create a folder called Music it has the error bwrap: Can't bind mount /oldroot/home/solarinas/Music on /newroot/home/solarinas/Music: No such file or directory
I realize this isn't the core of the problem but the correct way to set a music directory is xdg-user-dirs-update --set MUSIC /foo/barnot symlinking.
Reacted by Devin Murray, Alexander Rüedlinger, Julian Richen, Jon Irving Levin, Matt Boehm, swedneck, proailurus, Kamen Mladenov, Václav Šmejkal, kees-closed and 3 more
Reacted by PorcelainMouse, Magnus Bergmark, Yury Martynov, Roman Hargrave, PSSGCSim, BT, Muhammad Faizud Daroin, Arash Sal Moslehian, tomikaka22, Aura Herrero Ruiz and 2 more
I don't understand why steam is messing with the the home directory or desktop environment things like Picutres, Music, Videos. It is nonstandard for applications to f with that stuff on Linux.
Is there some other workaround that don't involve making weird hacks to the current symlink setup?
I tried switching from a symlink to a --bind mount, but then I get this error:
bwrap: Can't bind mount /oldroot/home/mange/Media/Music on /newroot/home/mange/Media/Music: No such file or directory
I'm mounting my NAS on /mnt/nas, and I'm using the music storage there in my standard Music path (set to /home/mange/Media/Music in my XDG dirs). I'd rather not have to build a big system for having custom XDG directories on all my machines, when I could use the same path for all of them. Right now I can keep the XDG dirs file in my dotfiles repo.
@Mange Exactly as I said: xdg-user-dirs-update --set MUSIC /mnt/nas/Music or whatever. You can then symlink the home dir there if you just wanted a shortcut from there.
If you want a non-standard xdg dir you have to run that command, thats just how it is.
That's a very unhelpful reply. I am using a custom directory, on purpose, and that directory happens to be a symlink on one of my machines. There's nothing weird or non-standard with that.
I've tried the following things to try to get rid of the buggy behavior:
Override the XDG_MUSIC_DIR env variable as the command is starting. (I had no expectation that this would work, however)
Attaching overrides that forbids access to the music directory.
Running with music explicitly forbidden.
Fixing the generated symlink (in ~/.var/…).
Explicitly allowing access to the symlink destination.
All of the above at the same time.
Seems like #1658 is the one holding us back, with #1781 preventing us from doing any overrides.
Technically it works if I wrap the command in a script that removes the symlink in .var before invoking flatpak, but then that wrapper won't be used by the .desktop files, etc.
I decided that flatpak still isn't worth the hassle so I uninstalled it. I came in exited to try to help you guys find the source of a bug, but this sort of response soured me up quite a bit. I wish you luck with your future endeavors.
Reacted by ૮༼⚆︿⚆༽つ, James Flynn, Arash Sal Moslehian, Nick Mertin, Justin Zobel, Janik, isometra, Markus Koller, forlornidealist, G2 and 2 more
@Mange I believe you may have misunderstood @TingPing’s answer. You can keep the current symlinks in your home directory. You just also need to reconfigure XDG using the command he provided. Flatpak doesn’t actually care about the symlink in your home directory if it can find the direct destination from your XDG configuration.
I now have the same issue. I get the error message:
✘ user@machine ~ flatpak run com.valvesoftware.Steam
bwrap: Can't make symlink at /home/chris/media/images: File exists
More info:
✘ user@machine ~ cat .config/user-dirs.dirs
# This file is written by xdg-user-dirs-update
# If you want to change or add directories, just edit the line you're
# interested in. All local changes will be retained on the next run.
# Format is XDG_xxx_DIR="$HOME/yyy", where yyy is a shell-escaped
# homedir-relative path, or XDG_xxx_DIR="/yyy", where /yyy is an
# absolute path. No other format is supported.
#
XDG_DESKTOP_DIR="$HOME/desktop"
XDG_DOWNLOAD_DIR="$HOME/downloads"
XDG_TEMPLATES_DIR="$HOME/templates"
XDG_PUBLICSHARE_DIR="$HOME/public"
XDG_DOCUMENTS_DIR="$HOME/documents"
XDG_MUSIC_DIR="$HOME/media/music"
XDG_PICTURES_DIR="$HOME/media/images"
XDG_VIDEOS_DIR="$HOME/media/videos"
So my XDG directories are properly set up.
Reacted by ૮༼⚆︿⚆༽つ, swedneck, Arash Sal Moslehian, Zesko and Utkarsh Verma
@da2x No, I think you misunderstood my requirements. I do use a custom directory. I use the same custom directory on all my machines as I share XDG configuration files in my dotfiles repo.
But on one machine, I mount my NAS directly instead of relying on file syncing. I solve that with symlinks, something which symlinks are really useful for.
If I change the setting on that machine, my Git-tracked config file will be changed and all my machines would require access to my NAS. This is why I want the override in the filesystem, so my configs don't have to care where my music is stored. Maybe my SSD would be full on another machine, so I move the music storage over to a disk drive and set up a symlinks and I'm done. All apps that scans music directories will keep working. All "recently opened" entries stay the same, etc.
The command doesn't change your directories at all. It won't affect your simlinks. It doesn't even touch your setup. It just tells XDG-aware programs where to look for the actual folders that would normally be in the home folder (MUSIC, PICTURES, etc.).
It tells those programs by changing the .config/user-dirs.dirs file. Which is the exact same file on all my machines since it's in my dotfiles. Which means that if I change it on Machine A to point to a disk connected only to Machine A, then Machine B and C and D will break. As it is the same file on all of them.
It is much simpler to have a standard path on all my machines, and on the only machine with a special case (out of multiple machines) uses symlinks or mountpoints to get in line.
On Fri, Dec 6, 2019, 4:18 AM Magnus Bergmark ***@***.***> wrote:
The command doesn't change your directories at all. It won't affect your
simlinks. It doesn't even touch your setup. It just tells XDG-aware
programs where to look for the actual folders that would normally be in the
home folder (MUSIC, PICTURES, etc.).
It tells those programs by changing the .config/user-dirs.dirs file.
Which is the exact same file on all my machines since it's in my dotfiles.
Which means that if I change it on Machine A to point to a disk connected
only to Machine A, then Machine B and C and D will break. As it is the same
file on all of them.
It is much simpler to have a standard path on all my machines, and on the
only machine with a special case (out of multiple machines) uses symlinks
or mountpoints to get in line.
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#1971?email_source=notifications&email_token=AAM4YSLJ4BTNSUGEQFPI6OTQXIRHLA5CNFSM4FPX5TGKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEGDVBWQ#issuecomment-562516186>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAM4YSMZ673CCJAZAGA6B5DQXIRHLANCNFSM4FPX5TGA>
.
I have similar issue but with ~/.icons directory. I have filesystems=~/.icons/:ro; in my overrides, to make the cursor theme work in flatpak applications, I guess it has something to do with it.
I am using a shared root steam library across two linux installs, symlinked to ~/Games. I have the XDG_GAMES_DIR in user-dirs.dirs set to use the dir that is not behind a symlink, but it's not being set as an environment variable, which I have no idea whether would it affect anything. I also added ~/Games to allowed filesystems for steam to access using flatseal. I get the error bwrap: Can't make symlink at /home/jtcf/Games: File exists when trying to launch steam.
It's irritating trying to find out where the issue is (whether it's flatpak or my system config) and I'm surprised it exists for 5 years already
I'm getting a similar problem but its because i made a script to automatically generate a Discord Rich Presence Client symlink at /run/user/1000/discord-ipc-0
bwrap: Can't make symlink at /run/user/1000/discord-ipc-0: File exists
One thing that is interesting is that if its a hardlink Flatpak wont complain. Maybe a way to fix this is to just clear all symlinks once the program closes/Just ignore the symlink if "File exists"
/usr/bin/flatpak run --branch=stable --arch=x86_64 --command=heroic-run --file-forwarding com.heroicgameslauncher.hgl @@u %u @@
bwrap: Can't make symlink at /home/legluondunet/Games: File exists
I installed Flatseal and give to Heroic app authorization to access my home.
I didn't find this solution myself, I didn't guess it, I read it on another forum.
I am an IT professional, I work in IT support and I want to say that this message does not help anyone, it is not intuitive. It would have been more relevant to point out in this message that the Heroic application does not have access rights to my home directory.
I had this problem with Steam (Flatpak). I had symlinked ~/Música to ~/Music, ~/Documentos to ~/Documents, etc. I removed the symlinks, and that stopped the error.
I had this problem with Steam (Flatpak). I had symlinked ~/Música to ~/Music, ~/Documentos to ~/Documents, etc. I removed the symlinks, and that stopped the error.
If the issue is caused by a symlink you've created the only current "workaround" AFAIK is using hardlinks instead of symlinks.
I have this same problem. I want to keep some of the default xdg directories in another disk and i have symlink for them in my home directory. If i update xdg directories rather than symlink, with xdg update command, it brokes other applications such as Firefox. Even if I add other disk and directory path as permission with Flatseal, Firefox can't save files I downloaded. Tried to search Flatpak mount directories but the files aren't there either. If I only use symlink, which makes Firefox works without any problem, then Steam creates problem. I don't know how to keep them together.
Perhaps this is my inexperience with this repo, but this issue was 3-4 months older than the one referenced. Additionally, this issue has had far more active engagement and productive discussion attempting to understand/debug the problem. It seems like #2387 is the duplicate to close, and this issue #1971 should be reopened?
The order does't matter, you don't get a badge for filing it first. Nor for engagement. And github doesn't provide the tools to handle duplicate issues.
Reacted by Teoh Han Hui, Jesse Johnson, Queria Sa-Tas, Martin, Max Roncace, Pavel Kolesnikov and Mayu
I apologize if I came across negatively, as I am not trying to create a problem.
However, I am not seeking a badge (it isn't even my issue post). I am also not trying to base merit of an issue on its "engagement" alone.
I am simply pointing out if it makes more sense for record-keeping to preserve the discussion with more debugging information and active attempts to solve the problem, as this info could help with resolving the issue in the future.
Reacted by Alsiel Rosewood, Frank, Jesse Johnson, Queria Sa-Tas, Martin, Pavel Kolesnikov and Mayu
Hi, I have the same issue here. System: Fedora 43, Gnome 49, bwrap 0.11.0, flatpak 1.16.3
Log:
user@fedora:~ $ ln -s Nextcloud/Bilder/ Bilder
user@fedora:~ $ ln -s Nextcloud/Dokumente/ Dokumente
user@fedora:~ $ steam
bash: steam: Befehl nicht gefunden...
user@fedora:~ $ flatpak run com.valvesoftware.Steam
bwrap: Can't make symlink at /home/user/Bilder: destination exists and is not a symlink
user@fedora:~ $
Activity
Solarinas commentedon Aug 20, 2018
Hey, I'm having the same problem on the same OS on the same version of flatpak. By removing the symlink Steam can work. If I create a folder called Music it has the error
bwrap: Can't bind mount /oldroot/home/solarinas/Music on /newroot/home/solarinas/Music: No such file or directoryTingPing commentedon Aug 20, 2018
I realize this isn't the core of the problem but the correct way to set a music directory is
xdg-user-dirs-update --set MUSIC /foo/barnot symlinking.PorcelainMouse commentedon Dec 5, 2018
I don't understand why steam is messing with the the home directory or desktop environment things like Picutres, Music, Videos. It is nonstandard for applications to f with that stuff on Linux.
Mange commentedon Jan 1, 2019
Is there some other workaround that don't involve making weird hacks to the current symlink setup?
I tried switching from a symlink to a
--bindmount, but then I get this error:I'm mounting my NAS on
/mnt/nas, and I'm using the music storage there in my standard Music path (set to/home/mange/Media/Musicin my XDG dirs). I'd rather not have to build a big system for having custom XDG directories on all my machines, when I could use the same path for all of them. Right now I can keep the XDG dirs file in my dotfiles repo.TingPing commentedon Jan 1, 2019
@Mange Exactly as I said:
xdg-user-dirs-update --set MUSIC /mnt/nas/Musicor whatever. You can then symlink the home dir there if you just wanted a shortcut from there.Mange commentedon Jan 1, 2019
But then I need to make the same change on all my machines as they share config files with each other.
TingPing commentedon Jan 2, 2019
If you want a non-standard xdg dir you have to run that command, thats just how it is.
Mange commentedon Jan 3, 2019
That's a very unhelpful reply. I am using a custom directory, on purpose, and that directory happens to be a symlink on one of my machines. There's nothing weird or non-standard with that.
I've tried the following things to try to get rid of the buggy behavior:
XDG_MUSIC_DIRenv variable as the command is starting. (I had no expectation that this would work, however)~/.var/…).Seems like #1658 is the one holding us back, with #1781 preventing us from doing any overrides.
Technically it works if I wrap the command in a script that removes the symlink in
.varbefore invoking flatpak, but then that wrapper won't be used by the.desktopfiles, etc.I decided that flatpak still isn't worth the hassle so I uninstalled it. I came in exited to try to help you guys find the source of a bug, but this sort of response soured me up quite a bit. I wish you luck with your future endeavors.
da2x commentedon May 17, 2019
@Mange I believe you may have misunderstood @TingPing’s answer. You can keep the current symlinks in your home directory. You just also need to reconfigure XDG using the command he provided. Flatpak doesn’t actually care about the symlink in your home directory if it can find the direct destination from your XDG configuration.
charlydelta commentedon Oct 1, 2019
I now have the same issue. I get the error message:
More info:
So my XDG directories are properly set up.
Mange commentedon Oct 1, 2019
@da2x No, I think you misunderstood my requirements. I do use a custom directory. I use the same custom directory on all my machines as I share XDG configuration files in my dotfiles repo.
But on one machine, I mount my NAS directly instead of relying on file syncing. I solve that with symlinks, something which symlinks are really useful for.
If I change the setting on that machine, my Git-tracked config file will be changed and all my machines would require access to my NAS. This is why I want the override in the filesystem, so my configs don't have to care where my music is stored. Maybe my SSD would be full on another machine, so I move the music storage over to a disk drive and set up a symlinks and I'm done. All apps that scans music directories will keep working. All "recently opened" entries stay the same, etc.
Mange commentedon Dec 6, 2019
It tells those programs by changing the
.config/user-dirs.dirsfile. Which is the exact same file on all my machines since it's in my dotfiles. Which means that if I change it on Machine A to point to a disk connected only to Machine A, then Machine B and C and D will break. As it is the same file on all of them.It is much simpler to have a standard path on all my machines, and on the only machine with a special case (out of multiple machines) uses symlinks or mountpoints to get in line.
refi64 commentedon Dec 6, 2019
egeexyz commentedon Nov 23, 2020
It's been a couple years since this issue was created and it still seems to exist.
For most applications, this will impact the MUSIC and PICTURES folders in ~. It's easy enough to work around though. For me it was:
xdg-user-dirs-update --set MUSIC /mnt/71ba0404-2768-426f-a5d3-602c3557970c/Musicxdg-user-dirs-update --set PICTURES /mnt/71ba0404-2768-426f-a5d3-602c3557970c/PicturesThe location under
/mntis my external drive. If you want to work around this issue quickly, you could set these paths to tmp:xdg-user-dirs-update --set MUSIC /tmpxdg-user-dirs-update --set PICTURES /tmpKeep in mind that /tmp/ won't persist between reboots but its a quick & dirty way around this issue for now.
3 remaining items
vlad196 commentedon May 28, 2023
So far, problems with symlinks, if they exist. Why does flatpack steam need something from my home directory?
ilyasturki commentedon Jul 6, 2023
I have the same issue
JohnTheCoolingFan commentedon Dec 10, 2023
I am using a shared root steam library across two linux installs, symlinked to
~/Games. I have theXDG_GAMES_DIRinuser-dirs.dirsset to use the dir that is not behind a symlink, but it's not being set as an environment variable, which I have no idea whether would it affect anything. I also added~/Gamesto allowed filesystems for steam to access using flatseal. I get the errorbwrap: Can't make symlink at /home/jtcf/Games: File existswhen trying to launch steam.It's irritating trying to find out where the issue is (whether it's flatpak or my system config) and I'm surprised it exists for 5 years already
hideki2k02 commentedon Jan 29, 2024
I'm getting a similar problem but its because i made a script to automatically generate a Discord Rich Presence Client symlink at
/run/user/1000/discord-ipc-0bwrap: Can't make symlink at /run/user/1000/discord-ipc-0: File existsOne thing that is interesting is that if its a hardlink Flatpak wont complain. Maybe a way to fix this is to just clear all symlinks once the program closes/Just ignore the symlink if "File exists"
legluondunet commentedon Jan 31, 2024
I had the same issue:
I installed Flatseal and give to Heroic app authorization to access my home.
I didn't find this solution myself, I didn't guess it, I read it on another forum.
I am an IT professional, I work in IT support and I want to say that this message does not help anyone, it is not intuitive. It would have been more relevant to point out in this message that the Heroic application does not have access rights to my home directory.
ChocolateLoverRaj commentedon Jan 31, 2024
I had this problem with Steam (Flatpak). I had symlinked
~/Músicato~/Music,~/Documentosto~/Documents, etc. I removed the symlinks, and that stopped the error.hideki2k02 commentedon Jan 31, 2024
If the issue is caused by a symlink you've created the only current "workaround" AFAIK is using hardlinks instead of symlinks.
rosimelade commentedon Feb 5, 2024
I have this same problem. I want to keep some of the default xdg directories in another disk and i have symlink for them in my home directory. If i update xdg directories rather than symlink, with xdg update command, it brokes other applications such as Firefox. Even if I add other disk and directory path as permission with Flatseal, Firefox can't save files I downloaded. Tried to search Flatpak mount directories but the files aren't there either. If I only use symlink, which makes Firefox works without any problem, then Steam creates problem. I don't know how to keep them together.
hfiguiere commentedon Feb 11, 2024
dupes of #2387
AyoungDukie commentedon Feb 11, 2024
Perhaps this is my inexperience with this repo, but this issue was 3-4 months older than the one referenced. Additionally, this issue has had far more active engagement and productive discussion attempting to understand/debug the problem. It seems like #2387 is the duplicate to close, and this issue #1971 should be reopened?
hfiguiere commentedon Feb 11, 2024
The order does't matter, you don't get a badge for filing it first. Nor for engagement. And github doesn't provide the tools to handle duplicate issues.
AyoungDukie commentedon Feb 11, 2024
I apologize if I came across negatively, as I am not trying to create a problem.
However, I am not seeking a badge (it isn't even my issue post). I am also not trying to base merit of an issue on its "engagement" alone.
I am simply pointing out if it makes more sense for record-keeping to preserve the discussion with more debugging information and active attempts to solve the problem, as this info could help with resolving the issue in the future.
Rotstein007 commentedon Mar 27, 2026
Hi, I have the same issue here. System: Fedora 43, Gnome 49, bwrap 0.11.0, flatpak 1.16.3
Log:
user@fedora:~ $ ln -s Nextcloud/Bilder/ Bilder
user@fedora:~ $ ln -s Nextcloud/Dokumente/ Dokumente
user@fedora:~ $ steam
bash: steam: Befehl nicht gefunden...
user@fedora:~ $ flatpak run com.valvesoftware.Steam
bwrap: Can't make symlink at /home/user/Bilder: destination exists and is not a symlink
user@fedora:~ $