More progress writing .md files
This commit is contained in:
parent
dfc44ac222
commit
215360ceef
6 changed files with 40 additions and 14 deletions
|
|
@ -6,7 +6,7 @@ Yes, you read that right. For development purposes, Linsk remains 100% supported
|
||||||
|
|
||||||
## QEMU
|
## QEMU
|
||||||
|
|
||||||
On Ubuntu (and probably on any other Debian-based distro) you can install the required `qemu-system-$(arch)` binary by running the following:
|
On Ubuntu (and probably on any other Debian-based distro), you can install the required `qemu-system-$(arch)` binary by running the following:
|
||||||
```sh
|
```sh
|
||||||
apt install qemu-system
|
apt install qemu-system
|
||||||
```
|
```
|
||||||
|
|
@ -27,7 +27,3 @@ go build
|
||||||
```
|
```
|
||||||
|
|
||||||
After that is done, you will be able to find the `linsk` binary in the same directory you ran `go build` in.
|
After that is done, you will be able to find the `linsk` binary in the same directory you ran `go build` in.
|
||||||
|
|
||||||
# The next steps
|
|
||||||
|
|
||||||
That's it. You can follow the further usage instructions set in TODO just like with any other OS.
|
|
||||||
13
SHELL.md
Normal file
13
SHELL.md
Normal file
|
|
@ -0,0 +1,13 @@
|
||||||
|
# Linsk shell
|
||||||
|
|
||||||
|
`linsk shell` will start a VM and open a full-fledged Linux shell for you. Linsk will not mount nor configure any file server.
|
||||||
|
|
||||||
|
Linsk's VM runs Alpine Linux, a lightweight busybox-based Linux distribution. Upon the startup, you will find little to no preinstalled tools. This is intentional as the goal is to have the lightest VM possible. There is no default text editor preinstalled either. However, Linsk's Alpine Linux is supplied with `apk` package manager. You can use it to install packages of any kind. An installation of `vim`, for example, would mean running `apk add vim`.
|
||||||
|
|
||||||
|
The main use of Linsk's shell is to format disks using tools like `mkfs`, run diagnostic tools like `fsck`. Please note that you will need to install these tools separately using Alpine Linux's `apk` package manager. The other important purpose of Linsk's shell is to assist with troubleshooting.
|
||||||
|
|
||||||
|
# Access the shell within `linsk run`
|
||||||
|
|
||||||
|
In addition to `linsk shell` aimed to help investigate disk-related issues, Linsk also provides a `--debug-shell` CLI flag for the `run` command. Unlike `linsk shell` , `linsk run --debug-shell` will start the shell *after* starting a network share. This is useful for investigating file share issues.
|
||||||
|
|
||||||
|
Please note that by default, networking is restricted when `linsk run --debug-shell` is run. You will need to add `--vm-unrestricted-networking` flag in order to be able to access the outside network.
|
||||||
21
TROUBLESHOOTING.md
Normal file
21
TROUBLESHOOTING.md
Normal file
|
|
@ -0,0 +1,21 @@
|
||||||
|
# Linsk troubleshooting tools
|
||||||
|
|
||||||
|
To aid with debugging/troubleshooting, Linsk is bundled with a few tools aimed to give you access to the virtual machine's internals.
|
||||||
|
|
||||||
|
### Error messages
|
||||||
|
|
||||||
|
By far, error messages is the single most helpful tool to help with problems of any kind. Before referring to anything, please analyze the errors and logs in detail.
|
||||||
|
|
||||||
|
**A great effort was put into ensuring that errors in Linsk are self-contained and provide enough information to understand what went wrong.** Please use them to your advantage.
|
||||||
|
|
||||||
|
### Shell
|
||||||
|
|
||||||
|
Linsk's shell is a powerful tool to assist with investigating issues inside the VM. Please refer to [SHELL.md](SHELL.md).
|
||||||
|
|
||||||
|
### `--vm-debug` flag
|
||||||
|
|
||||||
|
This flag is applicable in any `linsk` subcommand that starts a VM. Provided `--vm-debug`, Linsk will not start QEMU in headless mode and instead open a window with the virtual machine's display. **This is useful for investigating boot issues.**
|
||||||
|
|
||||||
|
# Common issues
|
||||||
|
|
||||||
|
TBD.
|
||||||
|
|
@ -179,6 +179,6 @@ Password: <random password>
|
||||||
|
|
||||||
This example showed how you can use LUKS with LVM2 volumes, but that doesn't mean that you can't use volumes without LVM. You can specify plain device paths like `vdb3` without any issue.
|
This example showed how you can use LUKS with LVM2 volumes, but that doesn't mean that you can't use volumes without LVM. You can specify plain device paths like `vdb3` without any issue.
|
||||||
|
|
||||||
# How to investigate in case something goes wrong
|
# Troubleshooting
|
||||||
|
|
||||||
<!-- TODO: Include a link to a DEBUGGING.md file -->
|
Please refer to [TROUBLESHOOTING.md](TROUBLESHOOTING.md).
|
||||||
|
|
@ -183,6 +183,6 @@ Password: <random password>
|
||||||
|
|
||||||
This example showed how you can use LUKS with LVM2 volumes, but that doesn't mean that you can't use volumes without LVM. You can specify plain device paths like `vdb3` without any issue.
|
This example showed how you can use LUKS with LVM2 volumes, but that doesn't mean that you can't use volumes without LVM. You can specify plain device paths like `vdb3` without any issue.
|
||||||
|
|
||||||
# How to investigate in case something goes wrong
|
# Troubleshooting
|
||||||
|
|
||||||
<!-- TODO: Include a link to a DEBUGGING.md file -->
|
Please refer to [TROUBLESHOOTING.md](TROUBLESHOOTING.md).
|
||||||
|
|
@ -67,10 +67,6 @@ func configureBaseVMCmd(logger *slog.Logger, cfg Config) (string, []qemucli.Arg,
|
||||||
var accel []qemucli.KeyValueArgItem
|
var accel []qemucli.KeyValueArgItem
|
||||||
switch {
|
switch {
|
||||||
case osspecifics.IsWindows():
|
case osspecifics.IsWindows():
|
||||||
// TODO: To document: For Windows, we need to install QEMU using an installer and add it to PATH.
|
|
||||||
// Then, we should enable Windows Hypervisor Platform in "Turn Windows features on or off".
|
|
||||||
// IMPORTANT: We should also install libusbK drivers for USB devices we want to pass through.
|
|
||||||
// This can be easily done with a program called Zadiag by Akeo.
|
|
||||||
accel = []qemucli.KeyValueArgItem{
|
accel = []qemucli.KeyValueArgItem{
|
||||||
{Key: "whpx"},
|
{Key: "whpx"},
|
||||||
{Key: "kernel-irqchip", Value: "off"},
|
{Key: "kernel-irqchip", Value: "off"},
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue