I tried removing it and putting it back in but i still can’t see it on windows, also I tried using my old pc and installed the latest Ubuntu version on it but like in the VM I just see some file folders (most of them are empty)
I'm sorry but you've either done something incorrectly or just don't understand how Linux handles drives and partitions (or possibly even what a partition is). Or the purpose of each directory.
Have you tried booting the card in your Pi?
Going right back to basics.*
Neither Windows Nor Linux uses the bare drive. Instead the bare drive is broken down into one or more sections (called partitions). Windows assigns a drive letter to each partition. Linux does not use drive letters.
Most modern desktop Linux will auto mount partitions on hot swap into /media/<your username>/<some name>. This is the equivalent of windows assigning a drive letter to each partition. Most Linux that boot to the command line do not automatically mount anything on hot swap.
Linux does not use drive letters. Instead each partition is mounted (made available in the file hierarchy) at an arbitrary, user specified location which is usually (but not always) an empty directory.
On a freshly written SD card or on a mounted but not booted one the following directories in the top level "root" directory of the OS partition will be empty. This is by design and is to be expected:
- boot on RPiOS Bullseye and earlier and some other OS. This is where the boot partition gets mounted when the system is running.
- dev a virtual in RAM filesystem gets mounted here when the system is running.
- media see above
- mnt
- proc a virtual in RAM filesystem gets mounted here when the system is running.
- run
- srv
- sys a virtual in RAM filesystem gets mounted here when the system is running.
For a full explanation of what those directories are for see https://en.wikipedia.org/wiki/Filesyste ... y_Standard
So, when you connect the SD card to your Ubuntu system it will create two sub directories in /media/username and mount the SD card's partitions on them. One for the boot partition and one for the root partition. No other mounts that would happen were you booting from that SD card occur. That's why the directories mentioned above are empty.
When you boot from the SD card, the additional mounts happen so those directories no longer appear to be empty.
*: and possibly mansplaining
Statistics: Posted by thagrol — Sun Dec 22, 2024 3:42 pm