-
Notifications
You must be signed in to change notification settings - Fork 10
/
mkusb.1
117 lines (116 loc) · 3.1 KB
/
mkusb.1
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
.TH "MKUSB" "1" "February 2022" "0.3" ""
.hy
.SH NAME
.PP
mkusb \[en] ISO multiboot USB creator
.SH SYNOPSIS
.PP
\f[B]mkusb\f[] [\f[I]distros\f[]] [\f[I]device\f[]] [\f[I]efi
partition\f[]] [\f[I]live partition\f[]]
.SH DESCRIPTION
.PP
mkusb is a shell script to create ISO multiboot USB flash drives that
support both legacy and EFI boot and x86 or amd64 systems.
.SH GENERAL OPTIONS
.TP
.B \f[I]distros\f[]
Multiboot defintion file to load
.RS
.PP
Defaults to "\f[B]distros\f[]"
.RE
.TP
.B \f[I]device\f[]
Device path for target USB drive
.RS
.PP
Dialog asks for device if not specified
.RE
.TP
.B \f[I]efi partition\f[]
Device path for EFI partition of target USB drive
.RS
.PP
USB is partitioned with an EFI and ISO partition if not specified
.RE
.TP
.B \f[I]live partition\f[]
Device path for ISO partition of target USB drive
.RS
.PP
USB is partitioned with an EFI and ISO partition if not specified
.RE
.SH ENVIRONMENT VARIABLES
.TP
.B \f[B]MKUSB_GRUB\f[]
Prefix for grub utilities and paths (e.g. "\f[B]grub\f[]" or "\f[B]grub2\f[]")
.RS
.RE
.TP
.B \f[B]MKUSB_GRUB_EFI\f[]
Path to grub-install with x86_64-efi target
.RS
.RE
.TP
.B \f[B]MKUSB_GRUB_PC\f[]
Path to grub-install with i386-pc target
.RS
.RE
.TP
.B \f[B]MKUSB_MEMDISK\f[]
Path to memdisk boot image from syslinux
.RS
.RE
.SH MULTIBOOT DEFINITION
.PP
Multiboot definition files contain details about where an ISO is located
and the appropriate boot parameters for that ISO.
A filesystem label can optionally be added to the drive if it is
partitioned (i.e.
\f[I]efi partition\f[] or \f[I]live partition\f[] are not specified).
.PP
Format:
.IP
.nf
\f[C]
label\ <filesystem\ label>
iso\ <boot\ label>\ <iso>\ <kernel>\ <initrd>\ <boot\ flags>
iso\ <boot\ label>\ <iso>\ <kernel>\ <initrd>\ <boot\ flags>
freedos\ <boot\ label>\ <FD.img>
refind\ <boot\ label>\ <refind-cd.iso>
\&...
\f[]
.fi
.PP
The boot flags are parsed for \f[I]%variable%\f[] expressions and fills
them out to GRUB variables.
Currently only \f[I]%filename%\f[] and \f[I]%label%\f[] are supported.
Arguments with a space or characters parsed by the shell must be quoted.
Most of these arguments can be found by mounting the ISO file and
checking the boot parameters in it.
Because the distros file is just a shell script, more advanced features
can be added like conditionally adding ISO files based on the
environment.
Example distros files are available below or at
\f[B]https://github.com/lilyinstarlight/mkusb/tree/main/examples\f[].
.SH EXAMPLES
.PP
The following examples requires ISOs to be downloaded in the same
directory as the definition file.
Specify relative or absolute paths to change this.
.PP
Rescue:
.IP
.nf
\f[C]
label\ RESCUE
iso\ \[aq]System\ Rescue\ 9.01\[aq]\ systemrescue\-9.01-amd64.iso\ \\
\ \ \ \ /sysresccd/boot/x86_64/vmlinuz\ \\
\ \ \ \ \[aq]/sysresccd/boot/intel_ucode.img\ /sysresccd/boot/amd_ucode.img\ /sysresccd/boot/x86_64/sysresccd.img\[aq]\ \\
\ \ \ \ \[aq]archisobasedir=sysresccd\ img_label=%label%\ img_loop=%filename%\ copytoram\[aq]
freedos\ \[aq]FreeDOS\ 1.3 RC5\[aq]\ FD13LITE.img
refind\ \[aq]rEFInd\ 0.13.2\[aq]\ refind\-cd\-0.13.2.iso
\f[]
.fi
.SH AUTHORS
Lily Foster <[email protected]>.