Skip to content

Instantly share code, notes, and snippets.

@nkhine
nkhine / Install-WSLAndUbuntuFocal.ps1
Created August 22, 2020 10:57 — forked from ScriptAutomate/Install-WSLAndUbuntu.ps1
Enable WSL and Install Ubuntu 20.04
<#
- BIOS of host machine also needs to be configured to allow hardware virtualization
- This gist WSLv2, but can use WSLv1 instead. I needed v1 as I run Windows 10 in a VM in Virtualbox.
- WSLv2 has been giving me problems in Virtualbox 6.1, but WSLv1 works properly.
- vbox has issues with the GUI settings when it comes to nested virtualization on certain systems,
so run the following if needing to give a VM this enabled setting:
VBoxManage modifyvm <vm-name> --nested-hw-virt on
#>
@nkhine
nkhine / zfs-docker.md
Created May 12, 2021 21:20 — forked from AnatomicJC/zfs-docker.md
ZFS and Docker

Create a dedicated ZFS docker pool with deduplication disabled in case of dedup enabled on your system:

zfs create -o mountpoint=/var/lib/docker -o dedup=off rpool/docker

Sometimes, you don't want ZFS for docker storage. ZFS can be sadly quite painful with Docker in Docker and similar scenarios. It might be best to avoid the problem by creating a volume in your ZFS pool, formatting that volume to ext4, and having docker use "overlay2" on top of that, instead of "zfs".

zfs create -s -V 30G rpool/docker

mkfs.ext4 /dev/zvol/rpool/docker