AppImage / appimagetool

A low-level tool to generate an AppImage from an existing AppDir
58 stars 11 forks source link

Could not open regular file for writing as destination: Text file busy #28

Closed probonopd closed 12 months ago

probonopd commented 12 months ago
% uname -a
FreeBSD Users-Laptop 13.1-RELEASE-p3 FreeBSD 13.1-RELEASE-p3 GENERIC amd64

% ./appimagetool-x86_64.AppImage --appimage-extract

% ./appimagetool-x86_64.AppImage squashfs-root 
appimagetool, continuous build (git version 9b6fadd), build 61 built on 2023-07-08 11:20:56 UTC
WARNING: zsyncmake command is missing, please install it if you want to use binary delta updates
WARNING: appstreamcli command is missing, please install it if you want to use AppStream metadata
Using architecture x86_64
/media/.debian/tmp/squashfs-root should be packaged as appimagetool-x86_64.AppImage
AppStream upstream metadata found in usr/share/metainfo/appimagetool.appdata.xml
Generating squashfs...
Downloading runtime file from https://github.com/AppImage/type2-runtime/releases/download/continuous/runtime-x86_64
Redirected to https://objects.githubusercontent.com/github-production-release-asset-2e65be/536952188/980ed5ee-5380-4f76-8305-2b387ebeb534?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIWNJYAX4CSVEH53A%2F20230708%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20230708T113651Z&X-Amz-Expires=300&X-Amz-Signature=d2602d2366482395f2bfca057ed765e8eb063b81c8aa49a4b4f76f60aff80cfc&X-Amz-SignedHeaders=host&actor_id=0&key_id=0&repo_id=536952188&response-content-disposition=attachment%3B%20filename%3Druntime-x86_64&response-content-type=application%2Foctet-stream
Downloading runtime binary of size 631200
Could not open regular file for writing as destination: Text file busy
mksquashfs (pid 5676) exited with code 1
sfs_mksquashfs error
probonopd commented 12 months ago

In my case the issue was:

./appimagetool-x86_64.AppImage --appimage-extract
./appimagetool-x86_64.AppImage squashfs-root

So it wanted to overwrite itself, while being in active use. Maybe this is an edge case that we don't need to handle specifically.