Skip to content

Windows

Guy Davis edited this page Mar 4, 2023 · 45 revisions

Start a Discussion or join our Discord for support and to help out.

Machinaris runs well inside Docker on Windows systems, but consider these known-issues. The following guide covers a standalone install on a single machine. Once launched, you'll just browse to http://localhost:8926.

Standalone

Machinaris also supports monitoring and controlling multiple workers on your local-area-network.

Pre-requisites

  • You'll need a recent Docker and docker-compose installed.
  • Recommend a minimum of 16 GB memory for a Machinaris controller (full-node). May need 32 GB+ if you add many forks. Machinaris harvesters will use less memory than full-nodes, even 2 GB can work on some hardware.
  • Ensure you have at least 150 GB of free space to hold the Chia blockchain... more required for forks.
  • Use a SSD to hold the Machinaris appdata (including blockchains) as a HDD will be too slow. HDDs are great to hold plots though!

Install and Launching

Most users will want to run a full-node with all services started and full-functionality available. Use the Launch Wizard to create docker-compose.yml file for your system.

Place the docker-compose.yml you generated from https://www.machinaris.app/ into a folder on your computer, could be in your Home directory, I recommend naming the folder machinaris. Then open a shell in that folder:

docker compose config
docker compose pull
docker compose up -d
docker logs -f machinaris

That config command will check the docker-compose.yml and output an error if problems. Watch the logs command to ensure a clean startup happens, then browse to http://localhost:8926/. From there you can run the Setup through the Machinaris WebUI.

Network Share Access

Docker on Windows won't allow a container such as Machinaris to list the contents of a remote network share (even a mapped drive letter). So, if you hold your plots on a remote share (such as a NAS), then the Launch Wizard allows you to mark a Windows volume as "Remote". In that case, the remote share is mounted inside the Machinaris container using the CIFS library upon startup.

Remote

Note the remote_mounts environment variable containing remote shares and their local mount paths.

Remote

In this case, the remote share and mount point of "//192.168.1.129/data" is passed into the container, to be mounted as a CIFS share internally using Samba. You MUST save the mounting credentials for your remote share into a new ~/.machinaris/smbcredentials.txt file. This must contain a username, password, and optionally a domain. Here are some example contents:

username=myusername
password=mypassword

NOTE: Some users have reported authentication errors when their smbcredentials.txt file had Windows line-endings. So, if you encounter STATUS_LOGON_FAILURE in dmesg in the container, try saving the file with Linux line-endings instead.

Other Modes

A Machinaris plotter is a remotely-controlled worker. Please see the Workers page for details on launching a plotter, a harvester, a harvester+plotter instead.

Post-Install Configuration

Once you have launched Machinaris, be sure to do the following, regardless of which platform you are using. For fullnode (default) and farmer modes, you'll need to either import a key or generate a new one as described below. Plotter and harvester modes DO NOT require key import or generation (see steps above).

Import Key Mnemonic

Just browse to http://localhost:8926 where you can either import an existing key or generate a new one:

GenerateKey

Port-Forward TCP/8444

For your full-node, you should port-forward your router back to your Docker container on port tcp/8444. This is required to stay synced and thus participating in farming challenges.

Here's an example port-forward config from my Unifi-router:

PortForward

Upgrade

First, be sure you are done plotting as updating/restarting the container will kill any running plotting jobs. When ready, do this:

docker compose stop
docker compose rm -f
docker compose pull
docker compose up -d --force-recreate

This will stop the Machinaris container and remove the old Machinaris image. It should NOT delete/touch any files in your .machinaris folder, including your mnemonic.txt file. When you execute your docker run again, it will pull the latest release and start up for you. Then browse to http://localhost:8926 or similar.

Known Issues

Slower Disk Performance

Docker on Windows offers much slower disk i/o than a Linux system. Not a big deal for a harvester, but can be a showstopper for plotting. As a workaround, please download Stotik's Windows version of the madmax plotter directly to a folder on your Windows machine. From the Machinaris WebUI, copy these settings to plot with using Windows Powershell:

  • Machinaris WebUI -> Keys page, copy your Farmer public key value. Use as -f to chia_plot.exe
  • Machinaris WebUI -> Settings | Pools page, copy your Pool contract address value. Use as -c parameter to chia_plot.exe

An native Machinaris plot manager for Windows is being considered which will execute chia_plot.exe via the Machinaris WebUI | Plotting page. This will be the final solution to speed up plotting on Windows using Machinaris.

GPU Pass Through

Unlike on Linux, passing a GPU from the Windows host OS through into the Docker container is non-trivial and error-prone. Since the GPU will be dedicated to the container (not shared), simply using Linux as the Host OS is generally a better approach.

Cleaning up WSL2 Disk Space

If you find a large amount (GBs) of space used within C:\Users\USERNAME\AppData\local\Docker\wsl\data\ext4.vhdx, please follow these directions to shrink the virtual disk.

Drives Mounted as Folders

Because Windows runs out of drive letters at 26, Microsoft bolted on the ability to mount drive to a folder path within drive letter. For example:

C:\Mounts\DriveA
C:\Mounts\DriveB
C:\Mounts\DriveC
...

Unfortunately, Docker on Windows does not seem to allow Volume Mounting paths like this, at least not in a way that allows a process in the container to list the plot files they contain, making your plots invisible to Machinaris.

WORKAROUND: Share the drives on your network and mount them within the Machinaris container as CIFS shares.

Drive Monitoring

Machinaris is able to to use smartctl to monitor hard drive status across your farm. Unfortunately, it seems that Docker on a Windows host is not able to expose native devices, like drives, into a Linux container such as Machinaris. Please let us know if you are aware of a workaround!

Clone this wiki locally