Unlinkat /var/snap/firefox/common/host-hunspell/en_US.aff: read-only file system

Hello.

I’m trying to remove the snap “firefox” on Ubuntu 22.10. Unfortunately an error prevents the task to be completed.

# snap list

Name    Version Rev   Tracking       Publisher Note

firefox 106.0-1 1969  latest/stable  mozilla   disabled 
snapd   2.58.2  18357 latest/stable  canonical snapd 

# snap disconnect firefox:host-hunspell
ok

# snap remove firefox

error : cannnot perform the following tasks :
remove data for the official snap "firefox" (1969) (Unlinkat /var/snap/firefox/common/host-hunspell/en_US.aff: read-only file system)

how to fix it ? thanks.

try to first run:

sudo snap disconnect firefox:host-hunspell

and only then the snap remove command …

EDIT: BAH ! ignore me, i’m obviously blind !

you could try to use snap disable firefox first, that should unmount everything (but leave it around in disabled state), then the snap remove should work …

# snap disable firefox
error : cannot disable "firefox" ; snap "firefox" already disabled

# snap disconnect firefox:host-hunspell
ok

# snap remove firefox

error : cannnot perform the following tasks :
remove data for the official snap "firefox" (1969) (Unlinkat /var/snap/firefox/common/host-hunspell/en_US.aff: read-only file system)

I was able to to remove firefox by umounting the folder:

# umount /var/snap/firefox/common/host-hunspell
1 Like

Hi ziomario,

I reproduced the problem.

The mount in question: /dev/mapper/vgubuntu-root on /var/snap/firefox/common/host-hunspell type ext4 (ro,noexec,noatime,errors=remount-ro)

For me, the issue only happens when firefox is disabled. I will provide more information on this behaviour shortly.