Thursday, October 12, 2023

Arcade DIY - MAME, RetroPi, Batocera Linux and more - Access your Linux Boot Drive on Widows

 Wow, this has been an effort. All I wanted to do was plug in my Batocera boot drive, add some files to it, and move on.

The quick way to do it?

  • Boot your Batocera.Linux USB drive on ANY machine (it won't erase the local drive unless you tell it to)
  • Find out where on the network it is in File Explorer (usually \\batocera\Share)
  • Now you can browse it and drop files to it.
Now....If you are like me and you have a card full of micro SD chips (dust motes I call them) and you have no idea what was installed on each of them. Then you have this problem.
  1. I don't know what's on there
  2. I don't want to boot it up
  3. I don't even know if this is a Raspberry Pi boot chip or x86
  4. When I plug it into windows I get one drive that looks vaguely familiar Some boot files.
  5. I can't see the other drive (cause it's linux and Microsoft doesn't want to talk to Linux)
You will need to do a few things.
  1. Install WSL (Windows System for Linux) on your machine.
    1. Install WSL | Microsoft Learn
  2. That's great, but when you do the whole "Mount a Linux Drive for Windows"
    1. Windows 10 now lets you mount Linux ext4 filesystems in WSL 2 (bleepingcomputer.com)
    2. wmic diskdrive list brief
    3. wsl --mount [DiskPath]
    4. wsl --mount \\.\PHYSICALDRIVE0
  3. It fails. Because WSL Does not support mounting USB Drives at all.
  4. So now you have to install an additional utility
  5. Connect USB devices | Microsoft Learn

After that, you should be able to mount and see the Linux partitions and do something useful with it. It's a pain in the butt, but until Microsoft learns to play nice with Linux, that is where you're at.

Oh, the other "simple" way?
You weren't using that old Core2 Duo machine for anything anyway.