panaceya / winbox

Snap package with winbox from MikroTik (https://mikrotik.com)
https://snapcraft.io/winbox
94 stars 28 forks source link

session save workaround; fixing #7, #15, #17 #33

Closed HonzaCZ closed 1 year ago

HonzaCZ commented 1 year ago

In the winbox binary there is probably hardcoded path of tmp files used to save sessions and settings. It's same directory where the executed binary is. This snap is configured to put binaries to R/O directory $SNAPCRAFT_PRIME/usr/libexec/. So tmp files can't be created there.

See attached strace log: save_session_strace.log

The workaround is copying the binary to writable $TMPDIR and executing from this location.

It works well for me. Ubuntu 22.04 LTS