1

lsblock on an osboxes Ubuntu VM return this:

sda      8:0    0   500G  0 disk
├─sda1   8:1    0 220.6G  0 part /var/snap/firefox/common/host-hunspell
│                                /
├─sda2   8:2    0   286M  0 part /boot
├─sda3   8:3    0    95M  0 part
├─sda4   8:4    0   8.9G  0 part [SWAP]
└─sda5   8:5    0 270.1G  0 part /home

The 220.6G size of host-hunspell raises concern? Why would it be so big? Is this a strange problem with the osboxes VM?

guiverc
  • 30,396
AturSams
  • 215
  • 1
    You've allocated 220GB to your / system, which is also accessible (within confinement restrictions anyway) by the firefox snap; the snap isn't using additional space though; it's just a mount. – guiverc Feb 01 '23 at 05:51
  • @guiverc Please explain it more accessibly (to new users)? I didn't understand the answer. I did notice it appears that there are two mountpoints on that device. – AturSams Feb 01 '23 at 05:57

1 Answers1

2

Your file-system mounted on / is ~220GB

That file-system (sda1 or drive SDA & partition 1) is mounted twice, firstly as the root (/) file-system, and secondly so it can be accessed by firefox (if you want to save/upload files*).

You'll find however that not all of / can be accessed from within firefox, as most snap packages run confined thus have only limited access to your / file-system, even though in theory the mount could allow for it.

For my current Ubuntu system, I have the following

guiverc@d7080-next:~/.config/liferea$   lsblk
(some details redacted for length)
├─sda5   8:5    0   512M  0 part /boot/efi
├─sda6   8:6    0  97.4G  0 part /var/snap/firefox/common/host-hunspell

guiverc@d7080-next:~/.config/liferea$ df -h Filesystem Size Used Avail Use% Mounted on tmpfs 1.6G 2.1M 1.6G 1% /run /dev/sda6 96G 39G 52G 43% / tmpfs 7.8G 301M 7.5G 4% /dev/shm tmpfs 5.0M 8.0K 5.0M 1% /run/lock tmpfs 7.8G 54M 7.7G 1% /tmp /dev/sda5 511M 6.1M 505M 2% /boot/efi tmpfs 1.6G 104K 1.6G 1% /run/user/1000

ie. you'll note it's the same, my ~96GB partition mounted as my root (/) is also mounted for use by the firefox snap package.

It's not strange, nor is it a concern (not ~220GB of wasted space for you, ~96GB for me), it's just how it works,

guiverc
  • 30,396
  • Not sure it's well explained sorry, others could I'm sure explain it better. – guiverc Feb 01 '23 at 06:09
  • When you said upload, did you mean download? – AturSams Feb 01 '23 at 07:25
  • I think the part that puzzles me the most as a new user is multiple mountpoints for one partition. Can you elaborate on the concept of mounting twice? Thank you! – AturSams Feb 01 '23 at 07:27
  • 1
    I don't know if you realize it yet, but snap packages (running confined) can access your $HOME (/home/$USER directory) but not your base file-system; the instead see a squashfs version of it; or the snap itself & that's what you explore if looking for files in firefox to upload for example. I have various network shares appearing in my df -h that I redacted, they are mounted off / as I prefer to avoid typing.. ie. /de2900 is a directory for a network share.. That is outside of where confined snaps can go, thus I can't save/upload from firefox or chromium there. – guiverc Feb 01 '23 at 07:50
  • 1
    To explore that I'll provide a question on this site where I used tried & failed (see https://askubuntu.com/questions/1303845/cannot-find-files-downloaded-in-tmp-folder/1303991#1303991). Snaps can also access /mnt and /media. As I didn't want to type /mnt/de2900/ everywhere, I mount that share twice; it's found in /de2900/ where I've had it for years, plus a more restricted mount is found in /mnt/de2900/ which the snap packages can use. I've added more restrictions to the mount in /mnt/ as I'll be using that from browsers (firefox/chromium) but that was my choice. – guiverc Feb 01 '23 at 07:55
  • 1
    I'm using the /de2900 as example... with my mounting it twice as it means I didn't need to type /mnt/de2900/lan/un.... & saved myself four characters for all mounts, but can still upload/download from browsers that run confined too using that longer name with /mnt/ in it... Same share mounted twice (using different permission/restrictions was just as I chose to; as browsers can be used to download from the web & thus less-trusted data...) – guiverc Feb 01 '23 at 07:58
  • 1
    re: save/upload... from a browser I think of SAVE instead of download, and thus said that instead of SAVE/UPLOAD, but for readers - that maybe DOWNLOAD/UPLOAD ... just my preferred word usage sorry. – guiverc Feb 01 '23 at 07:59