1 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
\r
2 "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
\r
3 <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
\r
5 <meta http-equiv="Content-Type" content="application/xhtml+xml; charset=UTF-8" />
\r
6 <meta name="generator" content="AsciiDoc 8.6.6" />
\r
7 <title>grml2usb(8)</title>
\r
8 <style type="text/css">
\r
9 /* Shared CSS for AsciiDoc xhtml11 and html5 backends */
\r
13 font-family: Georgia,serif;
\r
17 h1, h2, h3, h4, h5, h6,
\r
18 div.title, caption.title,
\r
19 thead, p.table.header,
\r
21 #author, #revnumber, #revdate, #revremark,
\r
23 font-family: Arial,Helvetica,sans-serif;
\r
27 margin: 1em 5% 1em 5%;
\r
32 text-decoration: underline;
\r
48 h1, h2, h3, h4, h5, h6 {
\r
51 margin-bottom: 0.5em;
\r
56 border-bottom: 2px solid silver;
\r
76 border: 1px solid silver;
\r
81 margin-bottom: 0.5em;
\r
87 ul > li { color: #aaa; }
\r
88 ul > li > * { color: black; }
\r
102 #revnumber, #revdate, #revremark {
\r
107 border-top: 2px solid silver;
\r
108 padding-top: 0.5em;
\r
113 padding-bottom: 0.5em;
\r
117 padding-bottom: 0.5em;
\r
122 margin-bottom: 1.5em;
\r
124 div.imageblock, div.exampleblock, div.verseblock,
\r
125 div.quoteblock, div.literalblock, div.listingblock, div.sidebarblock,
\r
126 div.admonitionblock {
\r
128 margin-bottom: 1.5em;
\r
130 div.admonitionblock {
\r
132 margin-bottom: 2.0em;
\r
137 div.content { /* Block element content. */
\r
141 /* Block element titles. */
\r
142 div.title, caption.title {
\r
147 margin-bottom: 0.5em;
\r
153 td div.title:first-child {
\r
156 div.content div.title:first-child {
\r
159 div.content + div.title {
\r
163 div.sidebarblock > div.content {
\r
164 background: #ffffee;
\r
165 border: 1px solid #dddddd;
\r
166 border-left: 4px solid #f0f0f0;
\r
170 div.listingblock > div.content {
\r
171 border: 1px solid #dddddd;
\r
172 border-left: 5px solid #f0f0f0;
\r
173 background: #f8f8f8;
\r
177 div.quoteblock, div.verseblock {
\r
178 padding-left: 1.0em;
\r
179 margin-left: 1.0em;
\r
181 border-left: 5px solid #f0f0f0;
\r
185 div.quoteblock > div.attribution {
\r
186 padding-top: 0.5em;
\r
190 div.verseblock > pre.content {
\r
191 font-family: inherit;
\r
192 font-size: inherit;
\r
194 div.verseblock > div.attribution {
\r
195 padding-top: 0.75em;
\r
198 /* DEPRECATED: Pre version 8.2.7 verse style literal block. */
\r
199 div.verseblock + div.attribution {
\r
203 div.admonitionblock .icon {
\r
204 vertical-align: top;
\r
207 text-decoration: underline;
\r
209 padding-right: 0.5em;
\r
211 div.admonitionblock td.content {
\r
212 padding-left: 0.5em;
\r
213 border-left: 3px solid #dddddd;
\r
216 div.exampleblock > div.content {
\r
217 border-left: 3px solid #dddddd;
\r
218 padding-left: 0.5em;
\r
221 div.imageblock div.content { padding-left: 0; }
\r
222 span.image img { border-style: none; }
\r
223 a.image:visited { color: white; }
\r
227 margin-bottom: 0.8em;
\r
232 font-style: normal;
\r
235 dd > *:first-child {
\r
240 list-style-position: outside;
\r
243 list-style-type: decimal;
\r
246 list-style-type: lower-alpha;
\r
249 list-style-type: upper-alpha;
\r
252 list-style-type: lower-roman;
\r
255 list-style-type: upper-roman;
\r
258 div.compact ul, div.compact ol,
\r
259 div.compact p, div.compact p,
\r
260 div.compact div, div.compact div {
\r
262 margin-bottom: 0.1em;
\r
274 margin-bottom: 0.8em;
\r
277 padding-bottom: 15px;
\r
279 dt.hdlist1.strong, td.hdlist1.strong {
\r
283 vertical-align: top;
\r
284 font-style: normal;
\r
285 padding-right: 0.8em;
\r
289 vertical-align: top;
\r
291 div.hdlist.compact tr {
\r
297 background: yellow;
\r
300 .footnote, .footnoteref {
\r
304 span.footnote, span.footnoteref {
\r
305 vertical-align: super;
\r
309 margin: 20px 0 20px 0;
\r
310 padding: 7px 0 0 0;
\r
313 #footnotes div.footnote {
\r
319 border-top: 1px solid silver;
\r
328 padding-right: 0.5em;
\r
329 padding-bottom: 0.3em;
\r
330 vertical-align: top;
\r
332 div.colist td img {
\r
337 #footer-badges { display: none; }
\r
341 margin-bottom: 2.5em;
\r
349 margin-bottom: 0.1em;
\r
352 div.toclevel1, div.toclevel2, div.toclevel3, div.toclevel4 {
\r
369 span.aqua { color: aqua; }
\r
370 span.black { color: black; }
\r
371 span.blue { color: blue; }
\r
372 span.fuchsia { color: fuchsia; }
\r
373 span.gray { color: gray; }
\r
374 span.green { color: green; }
\r
375 span.lime { color: lime; }
\r
376 span.maroon { color: maroon; }
\r
377 span.navy { color: navy; }
\r
378 span.olive { color: olive; }
\r
379 span.purple { color: purple; }
\r
380 span.red { color: red; }
\r
381 span.silver { color: silver; }
\r
382 span.teal { color: teal; }
\r
383 span.white { color: white; }
\r
384 span.yellow { color: yellow; }
\r
386 span.aqua-background { background: aqua; }
\r
387 span.black-background { background: black; }
\r
388 span.blue-background { background: blue; }
\r
389 span.fuchsia-background { background: fuchsia; }
\r
390 span.gray-background { background: gray; }
\r
391 span.green-background { background: green; }
\r
392 span.lime-background { background: lime; }
\r
393 span.maroon-background { background: maroon; }
\r
394 span.navy-background { background: navy; }
\r
395 span.olive-background { background: olive; }
\r
396 span.purple-background { background: purple; }
\r
397 span.red-background { background: red; }
\r
398 span.silver-background { background: silver; }
\r
399 span.teal-background { background: teal; }
\r
400 span.white-background { background: white; }
\r
401 span.yellow-background { background: yellow; }
\r
403 span.big { font-size: 2em; }
\r
404 span.small { font-size: 0.6em; }
\r
406 span.underline { text-decoration: underline; }
\r
407 span.overline { text-decoration: overline; }
\r
408 span.line-through { text-decoration: line-through; }
\r
417 font-family: monospace;
\r
418 font-size: inherit;
\r
424 margin-bottom: 1.5em;
\r
426 div.tableblock > table {
\r
427 border: 3px solid #527bbd;
\r
429 thead, p.table.header {
\r
436 /* Because the table frame attribute is overriden by CSS in most browsers. */
\r
437 div.tableblock > table[frame="void"] {
\r
438 border-style: none;
\r
440 div.tableblock > table[frame="hsides"] {
\r
441 border-left-style: none;
\r
442 border-right-style: none;
\r
444 div.tableblock > table[frame="vsides"] {
\r
445 border-top-style: none;
\r
446 border-bottom-style: none;
\r
456 font-family: monospace;
\r
457 font-size: inherit;
\r
463 margin-bottom: 1.5em;
\r
465 thead, p.tableblock.header {
\r
474 border-spacing: 0px;
\r
475 border-style: solid;
\r
476 border-color: #527bbd;
\r
477 border-collapse: collapse;
\r
479 th.tableblock, td.tableblock {
\r
482 border-style: solid;
\r
483 border-color: #527bbd;
\r
486 table.tableblock.frame-topbot {
\r
487 border-left-style: hidden;
\r
488 border-right-style: hidden;
\r
490 table.tableblock.frame-sides {
\r
491 border-top-style: hidden;
\r
492 border-bottom-style: hidden;
\r
494 table.tableblock.frame-none {
\r
495 border-style: hidden;
\r
498 th.tableblock.halign-left, td.tableblock.halign-left {
\r
501 th.tableblock.halign-center, td.tableblock.halign-center {
\r
502 text-align: center;
\r
504 th.tableblock.halign-right, td.tableblock.halign-right {
\r
508 th.tableblock.valign-top, td.tableblock.valign-top {
\r
509 vertical-align: top;
\r
511 th.tableblock.valign-middle, td.tableblock.valign-middle {
\r
512 vertical-align: middle;
\r
514 th.tableblock.valign-bottom, td.tableblock.valign-bottom {
\r
515 vertical-align: bottom;
\r
525 padding-top: 0.5em;
\r
526 padding-bottom: 0.5em;
\r
527 border-top: 2px solid silver;
\r
528 border-bottom: 2px solid silver;
\r
531 border-style: none;
\r
533 body.manpage div.sectionbody {
\r
538 body.manpage div#toc { display: none; }
\r
541 <script type="text/javascript">
\r
543 var asciidoc = { // Namespace.
\r
545 /////////////////////////////////////////////////////////////////////
\r
546 // Table Of Contents generator
\r
547 /////////////////////////////////////////////////////////////////////
\r
549 /* Author: Mihai Bazon, September 2002
\r
550 * http://students.infoiasi.ro/~mishoo
\r
552 * Table Of Content generator
\r
555 * Feel free to use this script under the terms of the GNU General Public
\r
556 * License, as long as you do not remove or alter this notice.
\r
559 /* modified by Troy D. Hanson, September 2006. License: GPL */
\r
560 /* modified by Stuart Rackham, 2006, 2009. License: GPL */
\r
562 // toclevels = 1..4.
\r
563 toc: function (toclevels) {
\r
565 function getText(el) {
\r
567 for (var i = el.firstChild; i != null; i = i.nextSibling) {
\r
568 if (i.nodeType == 3 /* Node.TEXT_NODE */) // IE doesn't speak constants.
\r
570 else if (i.firstChild != null)
\r
571 text += getText(i);
\r
576 function TocEntry(el, text, toclevel) {
\r
579 this.toclevel = toclevel;
\r
582 function tocEntries(el, toclevels) {
\r
583 var result = new Array;
\r
584 var re = new RegExp('[hH]([2-'+(toclevels+1)+'])');
\r
585 // Function that scans the DOM tree for header elements (the DOM2
\r
586 // nodeIterator API would be a better technique but not supported by all
\r
588 var iterate = function (el) {
\r
589 for (var i = el.firstChild; i != null; i = i.nextSibling) {
\r
590 if (i.nodeType == 1 /* Node.ELEMENT_NODE */) {
\r
591 var mo = re.exec(i.tagName);
\r
592 if (mo && (i.getAttribute("class") || i.getAttribute("className")) != "float") {
\r
593 result[result.length] = new TocEntry(i, getText(i), mo[1]-1);
\r
603 var toc = document.getElementById("toc");
\r
608 // Delete existing TOC entries in case we're reloading the TOC.
\r
609 var tocEntriesToRemove = [];
\r
611 for (i = 0; i < toc.childNodes.length; i++) {
\r
612 var entry = toc.childNodes[i];
\r
613 if (entry.nodeName == 'div'
\r
614 && entry.getAttribute("class")
\r
615 && entry.getAttribute("class").match(/^toclevel/))
\r
616 tocEntriesToRemove.push(entry);
\r
618 for (i = 0; i < tocEntriesToRemove.length; i++) {
\r
619 toc.removeChild(tocEntriesToRemove[i]);
\r
622 // Rebuild TOC entries.
\r
623 var entries = tocEntries(document.getElementById("content"), toclevels);
\r
624 for (var i = 0; i < entries.length; ++i) {
\r
625 var entry = entries[i];
\r
626 if (entry.element.id == "")
\r
627 entry.element.id = "_toc_" + i;
\r
628 var a = document.createElement("a");
\r
629 a.href = "#" + entry.element.id;
\r
630 a.appendChild(document.createTextNode(entry.text));
\r
631 var div = document.createElement("div");
\r
632 div.appendChild(a);
\r
633 div.className = "toclevel" + entry.toclevel;
\r
634 toc.appendChild(div);
\r
636 if (entries.length == 0)
\r
637 toc.parentNode.removeChild(toc);
\r
641 /////////////////////////////////////////////////////////////////////
\r
642 // Footnotes generator
\r
643 /////////////////////////////////////////////////////////////////////
\r
645 /* Based on footnote generation code from:
\r
646 * http://www.brandspankingnew.net/archive/2005/07/format_footnote.html
\r
649 footnotes: function () {
\r
650 // Delete existing footnote entries in case we're reloading the footnodes.
\r
652 var noteholder = document.getElementById("footnotes");
\r
656 var entriesToRemove = [];
\r
657 for (i = 0; i < noteholder.childNodes.length; i++) {
\r
658 var entry = noteholder.childNodes[i];
\r
659 if (entry.nodeName == 'div' && entry.getAttribute("class") == "footnote")
\r
660 entriesToRemove.push(entry);
\r
662 for (i = 0; i < entriesToRemove.length; i++) {
\r
663 noteholder.removeChild(entriesToRemove[i]);
\r
666 // Rebuild footnote entries.
\r
667 var cont = document.getElementById("content");
\r
668 var spans = cont.getElementsByTagName("span");
\r
671 for (i=0; i<spans.length; i++) {
\r
672 if (spans[i].className == "footnote") {
\r
674 var note = spans[i].getAttribute("data-note");
\r
676 // Use [\s\S] in place of . so multi-line matches work.
\r
677 // Because JavaScript has no s (dotall) regex flag.
\r
678 note = spans[i].innerHTML.match(/\s*\[([\s\S]*)]\s*/)[1];
\r
679 spans[i].innerHTML =
\r
680 "[<a id='_footnoteref_" + n + "' href='#_footnote_" + n +
\r
681 "' title='View footnote' class='footnote'>" + n + "</a>]";
\r
682 spans[i].setAttribute("data-note", note);
\r
684 noteholder.innerHTML +=
\r
685 "<div class='footnote' id='_footnote_" + n + "'>" +
\r
686 "<a href='#_footnoteref_" + n + "' title='Return to text'>" +
\r
687 n + "</a>. " + note + "</div>";
\r
688 var id =spans[i].getAttribute("id");
\r
689 if (id != null) refs["#"+id] = n;
\r
693 noteholder.parentNode.removeChild(noteholder);
\r
695 // Process footnoterefs.
\r
696 for (i=0; i<spans.length; i++) {
\r
697 if (spans[i].className == "footnoteref") {
\r
698 var href = spans[i].getElementsByTagName("a")[0].getAttribute("href");
\r
699 href = href.match(/#.*/)[0]; // Because IE return full URL.
\r
701 spans[i].innerHTML =
\r
702 "[<a href='#_footnote_" + n +
\r
703 "' title='View footnote' class='footnote'>" + n + "</a>]";
\r
709 install: function(toclevels) {
\r
712 function reinstall() {
\r
713 asciidoc.footnotes();
\r
715 asciidoc.toc(toclevels);
\r
719 function reinstallAndRemoveTimer() {
\r
720 clearInterval(timerId);
\r
724 timerId = setInterval(reinstall, 500);
\r
725 if (document.addEventListener)
\r
726 document.addEventListener("DOMContentLoaded", reinstallAndRemoveTimer, false);
\r
728 window.onload = reinstallAndRemoveTimer;
\r
732 asciidoc.install(2);
\r
736 <body class="article">
\r
738 <h1>grml2usb(8)</h1>
\r
740 <div id="toctitle">Table of Contents</div>
741 <noscript><p><b>JavaScript must be enabled in your browser to display the table of contents.</b></p></noscript>
745 <div class="sect1">
\r
746 <h2 id="_name">1. Name</h2>
\r
747 <div class="sectionbody">
\r
748 <div class="paragraph"><p>grml2usb - install grml ISO(s) on usb device for booting</p></div>
\r
751 <div class="sect1">
\r
752 <h2 id="_synopsis">2. Synopsis</h2>
\r
753 <div class="sectionbody">
\r
754 <div class="paragraph"><p>grml2usb [ options ] <ISO[s]> <device></p></div>
\r
755 <div class="sidebarblock">
\r
756 <div class="content">
\r
757 <div class="paragraph"><p>Important! The grml team does not take responsibility for loss of any data!</p></div>
\r
761 <div class="sect1">
\r
762 <h2 id="introduction">3. Introduction</h2>
\r
763 <div class="sectionbody">
\r
764 <div class="paragraph"><p>grml2usb installs grml on a given partition of your usb device and makes it
\r
765 bootable. It provides multi-iso support, meaning you can specify several grml
\r
766 ISOs on the command line at once and select the grml flavour you would like to
\r
767 boot on the bootprompt then. Note that the <strong>first</strong> ISO specified on the grml2usb
\r
768 command line will become the default one (that’s the one that will boot when
\r
769 just pressing enter on the bootprompt or wait until the boot timeout matches).</p></div>
\r
770 <div class="admonitionblock">
\r
773 <img src="./images/icons/important.png" alt="Important" />
\r
775 <td class="content">By default a compatible master boot record (MBR) is installed on the device
\r
776 (being for example /dev/sdX when executing <em>grml2usb grml.iso /dev/sdX1</em>) and
\r
777 syslinux is being used as default bootloader. Avoid installation of the default
\r
778 MBR using the <em>--skip-mbr</em> option or if you encounter any problems with the
\r
779 default MBR consider using <em>--syslinux-mbr</em> instead.</td>
\r
784 <div class="sect1">
\r
785 <h2 id="options">4. Options</h2>
\r
786 <div class="sectionbody">
\r
787 <div class="paragraph"><p>The ISO[s] should be the path to one or multiple grml-ISOs and/or the path to
\r
788 the currently running live-system (being /live/image).</p></div>
\r
789 <div class="paragraph"><p>The device either might be a device name like /dev/sdX1 or a directory. When
\r
790 specifying a device name the device is mounted automatically. When specifying a
\r
791 directory grml2usb is assuming that you did set up a bootloader on your own (or
\r
792 don’t need one) and a bootloader won’t be installed automatically.</p></div>
\r
793 <div class="paragraph"><p>The following options are supported:</p></div>
\r
794 <div class="dlist"><dl>
\r
795 <dt class="hdlist1">
\r
796 <strong>--bootoptions=…</strong>
\r
800 Use specified bootoptions as default. To use flavour name as a argument for a
\r
801 boot parameter use %flavour which will be expanded to the flavour name. To add
\r
802 multiple bootoptions you can specify the option multiple time.
\r
805 <dt class="hdlist1">
\r
806 <strong>--bootloader-only</strong>
\r
810 Do <strong>not</strong> copy files but instead just install a bootloader. Note that the boot
\r
811 addons are copied to /boot/addons at this stage as well. If you want to skip
\r
812 copying the boot addons consider using the --skip-addons option.
\r
815 <dt class="hdlist1">
\r
816 <strong>--copy-only</strong>
\r
820 Copy files only but do <strong>not</strong> install a bootloader.
\r
823 <dt class="hdlist1">
\r
824 <strong>--dry-run</strong>
\r
828 Avoid executing commands, instead show what would be executed.
\r
829 Warning: please notice that the ISO has to be mounted anyway, otherwise
\r
830 identifying the grml flavour would not be possible.
\r
833 <dt class="hdlist1">
\r
834 <strong>--fat16</strong>
\r
838 Format specified partition with FAT16.
\r
839 <strong>Important:</strong> this will destroy any existing data on the specified partition!
\r
842 <dt class="hdlist1">
\r
843 <strong>--force</strong>
\r
847 Force any (possible dangerous) actions requiring manual interaction (like --fat16).
\r
850 <dt class="hdlist1">
\r
851 <strong>--grub</strong>
\r
855 Install grub bootloader instead of (default) syslinux.
\r
858 <dt class="hdlist1">
\r
859 <strong>--grub-mbr</strong>
\r
863 Install grub into MBR (Master Boot Record) instead of PBR (Partition Boot
\r
864 Record). Check out <a href="#mbr-vs-pbr">the <em>mbr-vs-pbr</em> section in the FAQ of this document</a> for further details.
\r
867 <dt class="hdlist1">
\r
868 <strong>--help</strong>
\r
872 Display usage information and exit.
\r
876 <div class="dlist"><dl>
\r
877 <dt class="hdlist1">
\r
878 <strong>--mbr-menu</strong>
\r
882 Install master boot record (MBR) with integrated boot menu: interactively choose
\r
883 the partition to boot from, with a timeout to load the default partition, or
\r
884 boot from floppy. When NOT using the --mbr-menu option a MBR with LBA and large
\r
885 disc support but without an integrated boot menu is installed (so it’s not
\r
886 visible at all but instead directly jumps to the bootloader - being grub or
\r
887 syslinux). Note: This options is available only when using the default MBR and
\r
888 won’t have any effect if you’re using the <em>--syslinux-mbr</em> option.
\r
891 <dt class="hdlist1">
\r
892 <strong>--quiet</strong>
\r
896 Do not output anything but just errors on console.
\r
899 <dt class="hdlist1">
\r
900 <strong>--skip-addons</strong>
\r
904 Do not install /boot/addons/ files (like dos, grub, memdisk,…).
\r
907 <dt class="hdlist1">
\r
908 <strong>--remove-bootoption=…</strong>
\r
912 Remove specified bootoption (could be a regex) from existing boot options. Use
\r
913 multiple entries for removing different bootoptions at once.
\r
916 <dt class="hdlist1">
\r
917 <strong>--skip-grub-config</strong>
\r
921 Skip generation of grub configuration files. By default the configuration
\r
922 files for syslinux <strong>and</strong> grub will be written so you’ve a working configuration
\r
923 file no matter whether you’re using grub or syslinux as bootloader.
\r
926 <dt class="hdlist1">
\r
927 <strong>--skip-mbr</strong>
\r
931 Do not touch/install the master boot record (MBR).
\r
934 <dt class="hdlist1">
\r
935 <strong>--skip-syslinux-config</strong>
\r
939 Skip generation of syslinux configuration files. By default the configuration
\r
940 files for syslinux <strong>and</strong> grub will be written so you’ve a working configuration
\r
941 file no matter whether you’re using grub or syslinux as bootloader.
\r
944 <dt class="hdlist1">
\r
945 <strong>--syslinux</strong>
\r
949 This option is deprecated and is being left only for backwards compatibility
\r
950 reasons. Syslinux is the default bootloader of grml2usb and therefore the
\r
951 <em>--syslinux</em> option doesn’t have any effects. If you do not want to use syslinux
\r
952 as bootloader consider using the <em>--grub</em> option.
\r
955 <dt class="hdlist1">
\r
956 <strong>--syslinux-mbr</strong>
\r
960 Install syslinux' master boot record (MBR, which is booting from the partition
\r
961 with the "active" flag set) instead of the default one. If you encounter any
\r
962 problems with the default MBR you can try using the syslinux MBR instead. If
\r
963 that works for you please <a href="#author">let us know</a> so we can adjust our default
\r
968 <div class="dlist"><dl>
\r
969 <dt class="hdlist1">
\r
970 <strong>-v</strong>, <strong>--version</strong>
\r
974 Return version and exit.
\r
977 <dt class="hdlist1">
\r
978 <strong>--verbose</strong>
\r
982 Enable verbose mode.
\r
988 <div class="sect1">
\r
989 <h2 id="_developers_corner">5. Developers Corner</h2>
\r
990 <div class="sectionbody">
\r
991 <div class="sect2">
\r
992 <h3 id="directory-layout">5.1. Directory layout on usb device</h3>
\r
993 <div class="literalblock">
\r
994 <div class="content">
\r
995 <pre><tt>boot/ ->
\r
997 | |-- allinone.img [grub - all in one image]
\r
998 | |-- bsd4grml/ [MirBSD]
\r
999 | |-- balder10.imz [FreeDOS]
\r
1000 | |-- memdisk [chainloading helper]
\r
1001 | |-- memtest [memtest86+]
\r
1004 | | |-- linux26 [Kernel]
\r
1005 | | |-- initrd.gz [initramfs]
\r
1007 | | |-- linux26 [Kernel]
\r
1008 | | |-- initrd.gz [initramfs]
\r
1010 | | |-- linux26 [...]
\r
1012 | |-- grml64-medium
\r
1018 | `-- grml64-small
\r
1022 | |-- grml.png [graphical bootsplash background image for grub2]
\r
1023 | |-- grub.cfg [configuration file for grub2]
\r
1024 | |-- menu.lst [configuration file for grub1]
\r
1025 | |-- splash.xpm.gz [splash screen for grub1]
\r
1027 |-- grml.png [graphical bootsplash background image for syslinux]
\r
1028 |-- syslinux.cfg [main configuration file for syslinux]
\r
1029 `-- [....] [several further config files for syslinux]</tt></pre>
\r
1031 <div class="literalblock">
\r
1032 <div class="content">
\r
1034 |-- grml2usb.txt [not yet implemented]
\r
1035 |-- grml-cheatcodes.txt [list of bootoptions for grml]
\r
1036 |-- grml-version.txt [file containing information about grml-version]
\r
1037 |-- LICENSE.txt [license information]
\r
1038 |-- md5sums [md5sums of original ISO]
\r
1039 |-- README.txt [informational text]
\r
1040 `-- web/ [browser related files]
\r
1047 `-- logo.png</tt></pre>
\r
1049 <div class="literalblock">
\r
1050 <div class="content">
\r
1053 | |-- filesystem.module [module specifying which squashfs should be used for grml]
\r
1054 | `-- grml.squashfs [squashfs file for grml]
\r
1056 | |-- filesystem.module [module specifying which squashfs should be used for grml-medium]
\r
1057 | `-- grml-medium.squashfs [squashfs file for grml-medium]
\r
1059 | |-- filesystem.module [module specifying which squashfs should be used for grml-medium]
\r
1060 | `-- grml-small.squashfs [squashfs file for grml-small]
\r
1061 `-- ...</tt></pre>
\r
1064 <div class="sect2">
\r
1065 <h3 id="source">5.2. Grabbing the source</h3>
\r
1066 <div class="literalblock">
\r
1067 <div class="content">
\r
1068 <pre><tt>% git clone git://git.grml.org/grml2usb.git</tt></pre>
\r
1071 <div class="sect2">
\r
1072 <h3 id="debugging">5.3. Developers Debugging Hints</h3>
\r
1073 <div class="paragraph"><p>To play with grml2usb you can avoid using a real device via a loopback file
\r
1074 setup, like:</p></div>
\r
1075 <div class="literalblock">
\r
1076 <div class="content">
\r
1077 <pre><tt># dd if=/dev/zero of=~/loopback bs=1M count=100 # adjust size to your needs
\r
1078 # losetup /dev/loop1 ~/loopback</tt></pre>
\r
1080 <div class="paragraph"><p>Then create according partitions either running for example:</p></div>
\r
1081 <div class="literalblock">
\r
1082 <div class="content">
\r
1083 <pre><tt># echo -en "n\np\n1\n\n\nt\n6\na\n1\n w\n" | fdisk /dev/loop1</tt></pre>
\r
1085 <div class="paragraph"><p>or:</p></div>
\r
1086 <div class="literalblock">
\r
1087 <div class="content">
\r
1088 <pre><tt># parted /dev/loop1 -s "mkpart primary fat16 0 -1s mkfs 1 fat16"</tt></pre>
\r
1090 <div class="paragraph"><p>Finally create a filesystem and execute grml2usb as needed:</p></div>
\r
1091 <div class="literalblock">
\r
1092 <div class="content">
\r
1093 <pre><tt># mkfs.vfat /dev/loop1
\r
1094 # grml2usb --bootloader-only /grml/isos/grml-small_2009.10.iso /dev/loop1</tt></pre>
\r
1097 <div class="sect2">
\r
1098 <h3 id="performance-tracing">5.4. Performance tracing</h3>
\r
1099 <div class="literalblock">
\r
1100 <div class="content">
\r
1101 <pre><tt># blktrace -d /dev/sdX -o - | blkparse -i -
\r
1102 # grml2usb grml_2009.10.iso /dev/sdX1</tt></pre>
\r
1107 <div class="sect1">
\r
1108 <h2 id="troubleshooting">6. Troubleshooting and Pitfalls when booting</h2>
\r
1109 <div class="sectionbody">
\r
1110 <div class="paragraph"><p>Here is a list of common error messages from BIOS/bootloader when trying to boot
\r
1111 from USB.</p></div>
\r
1112 <div class="hdlist"><table>
\r
1114 <td class="hdlist1">
\r
1115 <strong>Error message</strong>
\r
1118 <td class="hdlist2">
\r
1119 <p style="margin-top: 0;">
\r
1120 ran out of input data. System halted
\r
1125 <td class="hdlist1">
\r
1126 <strong>Reason</strong>
\r
1129 <td class="hdlist2">
\r
1130 <p style="margin-top: 0;">
\r
1131 Everything OK, except for the filesystem used on your usb device. So
\r
1132 instead of fat16 you are using for example fat32. Fix: use the appropriate
\r
1133 filesystem (fat16 for usb pens usually). The Bootsplash might be displayed, the
\r
1134 kernel loads but you very soon get the error message.
\r
1139 <td class="hdlist1">
\r
1140 <strong>Error message</strong>
\r
1143 <td class="hdlist2">
\r
1144 <p style="margin-top: 0;">
\r
1145 Invalid operating system
\r
1150 <td class="hdlist1">
\r
1151 <strong>Reason</strong>
\r
1154 <td class="hdlist2">
\r
1155 <p style="margin-top: 0;">
\r
1156 the partition layout is not ok. Very probably there’s no primary
\r
1157 partition (/dev/sdX{1..4}) or none has the flag <em>bootable</em> set.
\r
1162 <td class="hdlist1">
\r
1163 <strong>Error message</strong>
\r
1166 <td class="hdlist2">
\r
1167 <p style="margin-top: 0;">
\r
1173 <td class="hdlist1">
\r
1174 <strong>Reason</strong>
\r
1177 <td class="hdlist2">
\r
1178 <p style="margin-top: 0;">
\r
1179 Some BIOSses offer different modes for USB booting. The proper mode
\r
1180 to boot a USB stick is USB-HDD. If that doesn’t work or is not supported by your
\r
1181 system, you need to format your USB-Stick as USB-ZIP. To do this, syslinux
\r
1182 contains an utility called mkdiskimage, which you can use to re-format your USB
\r
1183 stick in USB-ZIP format running <em>mkdiskimage -4 /dev/sdX 1 64 32</em>. Please be
\r
1184 aware that this procedure will erase all data on your stick. After executing
\r
1185 mkdiskimage just continue installing as usual (grml2usb … /dev/sdX4). Note
\r
1186 that this is not going to work for any device larger than 8 GB, since
\r
1187 mkdiskimage only supports 1024c 256h 63s. For a more detailed explanation, refer
\r
1188 to /usr/share/doc/syslinux-common/usbkey.txt.
\r
1193 <td class="hdlist1">
\r
1194 <strong>Error message</strong>
\r
1197 <td class="hdlist2">
\r
1198 <p style="margin-top: 0;">
\r
1199 No operating system found.
\r
1204 <td class="hdlist1">
\r
1205 <strong>Reason</strong>
\r
1208 <td class="hdlist2">
\r
1209 <p style="margin-top: 0;">
\r
1210 you forgot to set the boot-flag on the partition. Or there really isn’t
\r
1211 any operating system at all. :)
\r
1216 <td class="hdlist1">
\r
1217 <strong>Error message</strong>
\r
1220 <td class="hdlist2">
\r
1221 <p style="margin-top: 0;">
\r
1222 kernel-panic: unable to mount root-fs…
\r
1227 <td class="hdlist1">
\r
1228 <strong>Reason</strong>
\r
1231 <td class="hdlist2">
\r
1232 <p style="margin-top: 0;">
\r
1233 Kernel boots but fails to find the root filesystem. The root=
\r
1234 argument in your kernel commandline is pointing to the wrong device. Adjust
\r
1235 root=…, consider using root=UUID=….
\r
1240 <td class="hdlist1">
\r
1241 <strong>Error message</strong>
\r
1244 <td class="hdlist2">
\r
1245 <p style="margin-top: 0;">
\r
1246 Could not find kernel image: …
\r
1251 <td class="hdlist1">
\r
1252 <strong>Reason</strong>
\r
1255 <td class="hdlist2">
\r
1256 <p style="margin-top: 0;">
\r
1257 either a broken isolinux/syslinux version or a broken BIOS. Check out
\r
1258 whether the vendor provides a BIOS update or if using bootloader grub instead of
\r
1259 isolinux/syslinux fixes the problem.
\r
1266 <div class="sect1">
\r
1267 <h2 id="faq">7. Frequently Asked Questions (FAQ)</h2>
\r
1268 <div class="sectionbody">
\r
1269 <div class="sect2">
\r
1270 <h3 id="download">7.1. Where can I get grml2usb?</h3>
\r
1271 <div class="paragraph"><p>grml2usb is available as Debian package via <a href="http://deb.grml.org/">the
\r
1272 grml-testing Debian repository</a>.</p></div>
\r
1273 <div class="paragraph"><p>If you do not want to (or can’t) use the grml2usb Debian package you can either
\r
1274 use the grml2usb git tree running:</p></div>
\r
1275 <div class="literalblock">
\r
1276 <div class="content">
\r
1277 <pre><tt>git clone git://git.grml.org/grml2usb.git
\r
1280 sudo ./grml2usb ...</tt></pre>
\r
1282 <div class="paragraph"><p>or download the provided
\r
1283 <a href="http://grml.org/grml2usb/grml2usb.tgz">http://grml.org/grml2usb/grml2usb.tgz</a>
\r
1284 (<a href="http://grml.org/grml2usb/grml2usb.tgz.md5.asc">gpg signed md5 hash</a>).
\r
1285 Download and extract the tarball and execute the provided script <em>install.sh</em>.</p></div>
\r
1286 <div class="admonitionblock">
\r
1289 <img src="./images/icons/note.png" alt="Note" />
\r
1291 <td class="content">It is <strong>NOT</strong> enough to have just the grml2usb script itself without the according
\r
1292 files provided either via the Debian package, the git tree or the file
\r
1293 grml2usb.tgz.</td>
\r
1297 <div class="sect2">
\r
1298 <h3 id="dd">7.2. Why can’t I just dd the ISO to a USB device?</h3>
\r
1299 <div class="paragraph"><p>Well, you can. :) Starting with grml 2009.10 the ISOs are dd-able straight out-of-the-box.</p></div>
\r
1300 <div class="admonitionblock">
\r
1303 <img src="./images/icons/important.png" alt="Important" />
\r
1305 <td class="content">Note that ANY existing data on your USB device will be destroyed when
\r
1306 using the dd approach.</td>
\r
1309 <div class="paragraph"><p>This allows you to dd the Grml ISO to your USB device (use for example
\r
1310 <a href="http://www.chrysocome.net/rawwrite">rawwrite</a> if you’ve just a Windows
\r
1311 system available) running:</p></div>
\r
1312 <div class="literalblock">
\r
1313 <div class="content">
\r
1314 <pre><tt>% dd if=grml_2009.10.iso of=/dev/sdX</tt></pre>
\r
1316 <div class="paragraph"><p>where /dev/sdX is your USB device. Of course this doesn’t provide such a
\r
1317 flexible system like with grml2usb (no multi-ISO setup, no additional default
\r
1318 bootoptions,…) but it’s a nice way to get a working USB boot setup if you
\r
1319 don’t have grml2usb available.</p></div>
\r
1321 <div class="sect2">
\r
1322 <h3 id="grml2usb-vs-dd">7.3. What’s the difference between grml2usb and just using dd?</h3>
\r
1323 <div class="paragraph"><p>grml2usb does not remove any data from your USB device and does not alter the
\r
1324 partition table at all. grml2usb provides multi-ISO support, support for adding
\r
1325 default bootoptions and selecting the bootloader (syslinux vs. grub) without
\r
1326 having to manually touch the ISO at all.</p></div>
\r
1328 <div class="sect2">
\r
1329 <h3 id="grml2iso">7.4. What’s grml2iso?</h3>
\r
1330 <div class="paragraph"><p>grml2iso is a script which uses grml2usb to generate a multiboot ISO out of
\r
1331 several grml ISOs. See <em>man grml2iso</em> for further details.</p></div>
\r
1333 <div class="sect2">
\r
1334 <h3 id="menu-lst">7.5. Why is there a menu.lst and a grub.cfg inside /boot/grub/?</h3>
\r
1335 <div class="paragraph"><p>grml2usb supports grub version 1 (grub1) as well as grub version 2 (grub2).
\r
1336 Whereas grub1 uses menu.lst the new version grub2 needs grub.cfg.
\r
1337 Providing both files allows grml2usb to install grub on the target device
\r
1338 no matter which grub version is available on the host where grml2usb is
\r
1339 executed on.</p></div>
\r
1341 <div class="sect2">
\r
1342 <h3 id="stage1">7.6. grub-install fails with 'The file ../boot/grub/stage1 not read correctly"?!</h3>
\r
1343 <div class="paragraph"><p>Check whether the partition has the right partition type. For example do NOT use
\r
1344 FAT16 (partition type 6) when using a ext3 filesystem on the partition but
\r
1345 instead use the correct partition type (<em>83</em> - Linux) then.</p></div>
\r
1347 <div class="sect2">
\r
1348 <h3 id="grub-install-xfs_freeze">7.7. grub-install complains about /sbin/grub-install and/or xfs_freeze?!</h3>
\r
1349 <div class="paragraph"><p>The following message:</p></div>
\r
1350 <div class="literalblock">
\r
1351 <div class="content">
\r
1352 <pre><tt>You shouldn't call /sbin/grub-install. Please call /usr/sbin/grub-install instead!
\r
1353 xfs_freeze: specified file ["/tmp/tmpqaBK6z/boot/grub"] is not on an XFS filesystem</tt></pre>
\r
1355 <div class="paragraph"><p>This is "normal". grub-install sends those messages to stderr. To avoid hiding any
\r
1356 possible real error messages grml2usb doesn’t ignore those messages.</p></div>
\r
1358 <div class="sect2">
\r
1359 <h3 id="device-map">7.8. grub-install complains about /boot/grub/device.map?!</h3>
\r
1360 <div class="paragraph"><p>The following message:</p></div>
\r
1361 <div class="literalblock">
\r
1362 <div class="content">
\r
1363 <pre><tt>grub-probe: error: Cannot open `/boot/grub/device.map'</tt></pre>
\r
1365 <div class="paragraph"><p>This is "normal" (at least with grub1). This isn’t a problem, because the
\r
1366 device.map file will be generated on the target device anyway.</p></div>
\r
1368 <div class="sect2">
\r
1369 <h3 id="unary-operator">7.9. grub-install complains about a unary operator?!</h3>
\r
1370 <div class="paragraph"><p>The following message:</p></div>
\r
1371 <div class="literalblock">
\r
1372 <div class="content">
\r
1373 <pre><tt>'/usr/sbin/grub-install: line 374: [: =: unary operator expected'</tt></pre>
\r
1375 <div class="paragraph"><p>This is "normal". Just ignore it. (It usually doesn’t appear
\r
1376 on the second invocation on the same device.)</p></div>
\r
1378 <div class="sect2">
\r
1379 <h3 id="unknown-filesystem">7.10. grub-install fails with grub-probe: error: unknown filesystem?!</h3>
\r
1380 <div class="paragraph"><p>The following message:</p></div>
\r
1381 <div class="literalblock">
\r
1382 <div class="content">
\r
1383 <pre><tt>grub-probe: error: unknown filesystem
\r
1384 Auto-detection of a filesystem module failed.
\r
1385 Please specify the module with the option `--modules' explicitly.</tt></pre>
\r
1387 <div class="paragraph"><p>usually means that the device partition table says something else than the
\r
1388 filesystem on the device. For example using FAT16 as filesystem type and
\r
1389 using FAT32 as filesystem on the partition will not work. Either set filesystem
\r
1390 type to FAT32 or format the partition using FAT16. It is essential that
\r
1391 device partition table and filesystem use the same filesystem type.</p></div>
\r
1393 <div class="sect2">
\r
1394 <h3 id="mbr-vs-pbr">7.11. grub-setup fails after Attempting to install GRUB to a partition instead of the MBR?!</h3>
\r
1395 <div class="paragraph"><p>The following message:</p></div>
\r
1396 <div class="literalblock">
\r
1397 <div class="content">
\r
1398 <pre><tt>grub-setup: warn: Attempting to install GRUB to a partition instead of the MBR. This is a BAD idea.
\r
1399 grub-setup: warn: Embedding is not possible. GRUB can only be installed in this setup by using blocklists. However, blocklists are UNRELIABLE and its use is discouraged.
\r
1400 grub-setup: error: Cannot read `/grub/core.img' correctly</tt></pre>
\r
1402 <div class="paragraph"><p>appears when using grub2 versions older than 1.98 as those version introduced a
\r
1403 regression which avoids that grub is being installed into a partition (PBR,
\r
1404 Partition Boot Record) instead of MBR (Master Boot Record).</p></div>
\r
1405 <div class="paragraph"><p>To work around this issue you can either 1) upgrade to grub versions >=1.98, 2)
\r
1406 install grub into the MBR (Master Boot Record) using the <em>--grub-mbr</em> option of
\r
1407 grml2usb or 3) switch to syslinux as bootmanager (just drop the <em>--grub</em>
\r
1408 option).</p></div>
\r
1410 <div class="sect2">
\r
1411 <h3 id="splash-xpm">7.12. I’m getting something like "Error: /usr/share/grml2usb/grub/splash.xpm.gz can not be read"!?</h3>
\r
1412 <div class="paragraph"><p>Looks like you’ve only the grml2usb script itself available. Please make sure
\r
1413 you’ve the grml2usb Debian package installed. The most resent stable version is
\r
1414 available via <a href="http://deb.grml.org/">the grml-testing Debian repository</a>. If
\r
1415 you do not have a Debian system please see section <a href="#download">Where can I get grml2usb?</a> in this FAQ.</p></div>
\r
1417 <div class="sect2">
\r
1418 <h3 id="fat16">7.13. Why do I have to use a FAT16/FAT32 filesystem?</h3>
\r
1419 <div class="paragraph"><p>Syslinux (currently) does not support any other filesystems besides FAT16/FAT32
\r
1420 (though that’s a sane default if you want to share your files with other
\r
1421 (operating) systems). If you want to use a different filesystem (like ext2/3)
\r
1422 use the bootloader grub instead using grml2usb’s <em>--grub</em> option.</p></div>
\r
1423 <div class="admonitionblock">
\r
1426 <img src="./images/icons/note.png" alt="Note" />
\r
1428 <td class="content">FAT32 is supported since syslinux version 3.0.</td>
\r
1432 <div class="sect2">
\r
1433 <h3 id="hdt-hangs">7.14. Addons → Hardware Detection Tool freezes</h3>
\r
1434 <div class="paragraph"><p>This usually means that the machine you ran grml2usb on had syslinux 3.x
\r
1435 installed. The version of hdt (Hardware detection tool) shipping with Grml
\r
1436 2010.12 and newer requires syslinux 4.x.</p></div>
\r
1438 <div class="sect2">
\r
1439 <h3 id="cool-idea">7.15. I think I’ve got a really cool idea!</h3>
\r
1440 <div class="paragraph"><p>Great! Please check out
\r
1441 <a href="http://git.grml.org/?p=grml2usb.git;a=blob;f=TODO;hb=HEAD">the TODO file</a>.
\r
1442 Feel free to <a href="#author">report your wishes to the author</a>. Patches highly
\r
1443 appreciated.</p></div>
\r
1445 <div class="sect2">
\r
1446 <h3 id="booting-from-usb">7.16. I’ve problems with booting from USB.</h3>
\r
1447 <div class="paragraph"><p>Check out <a href="#troubleshooting">Troubleshooting and Pitfalls when booting</a>.</p></div>
\r
1449 <div class="sect2">
\r
1450 <h3 id="found-a-bug">7.17. I’ve found a bug!</h3>
\r
1451 <div class="paragraph"><p>Please <a href="#author">report it to the author</a>. Please provide usage examples and output
\r
1452 of your grml2usb commandline (consider using the "--verbose" option).</p></div>
\r
1456 <div class="sect1">
\r
1457 <h2 id="usage-examples">8. Usage examples</h2>
\r
1458 <div class="sectionbody">
\r
1459 <div class="literalblock">
\r
1460 <div class="content">
\r
1461 <pre><tt># grml2usb /home/grml/grml_2009.10.iso /dev/sdX1</tt></pre>
\r
1463 <div class="paragraph"><p>Install specified ISO on device /dev/sdX1.</p></div>
\r
1464 <div class="literalblock">
\r
1465 <div class="content">
\r
1466 <pre><tt># grml2usb /home/grml/grml_2009.10.iso /home/grml/grml_small_2009.10.iso /dev/sdX1</tt></pre>
\r
1468 <div class="paragraph"><p>Install specified ISOs on device /dev/sdX1 for multibooting ISOs.</p></div>
\r
1469 <div class="literalblock">
\r
1470 <div class="content">
\r
1471 <pre><tt># grml2usb /live/image /dev/sdX1</tt></pre>
\r
1473 <div class="paragraph"><p>Install currently running grml live system on device /dev/sdX1.</p></div>
\r
1474 <div class="literalblock">
\r
1475 <div class="content">
\r
1476 <pre><tt># grml2usb /live/image /home/grml/grml_2009.10.iso /dev/sdX1</tt></pre>
\r
1478 <div class="paragraph"><p>Install currently running grml live system and the specified
\r
1479 ISO on device /dev/sdX1 for multibooting.</p></div>
\r
1480 <div class="literalblock">
\r
1481 <div class="content">
\r
1482 <pre><tt># grml2usb --fat16 /home/grml/grml_2009.10.iso /dev/sdX1</tt></pre>
\r
1484 <div class="paragraph"><p>Install specified ISO on device /dev/sdX1 and format partition /dev/sdX1 with
\r
1485 FAT16 filesystem.</p></div>
\r
1486 <div class="literalblock">
\r
1487 <div class="content">
\r
1488 <pre><tt># grml2usb --grub --grub-mbr /home/grml/grml_2009.10.iso /dev/sdX1</tt></pre>
\r
1490 <div class="paragraph"><p>Install specified ISO on device /dev/sdX1 and use grub as bootloader (instead of
\r
1491 syslinux being the default) and install a master boot record (MBR) to the MBR of
\r
1492 /dev/sdX.</p></div>
\r
1493 <div class="literalblock">
\r
1494 <div class="content">
\r
1495 <pre><tt># grml2usb --bootoptions="lang=de ssh=mysecret" grml_2009.10.iso /dev/sdX1
\r
1496 # grml2usb --bootoptions="lang=de" --bootoptions="ssh=mysecret" grml_2009.10.iso /dev/sdX1</tt></pre>
\r
1498 <div class="paragraph"><p>Install specified ISO on device /dev/sdX1 and use "lang=de ssh=mysecret" as
\r
1499 default bootoptions.</p></div>
\r
1500 <div class="literalblock">
\r
1501 <div class="content">
\r
1502 <pre><tt># grml2usb --remove-bootoption="vga=791" --remove-bootoption="quiet" grml_2009.10.iso /dev/sdX1</tt></pre>
\r
1504 <div class="paragraph"><p>Install specified ISO on device /dev/sdX1 remove vga=791 and quiet from existing bootoptions.</p></div>
\r
1505 <div class="literalblock">
\r
1506 <div class="content">
\r
1507 <pre><tt># grml2usb --bootoptions="persistent-path=%flavour_name" grml64_2010.04.iso grml_2010.04.iso /dev/sdX1</tt></pre>
\r
1509 <div class="paragraph"><p>Install specified Isos on device /dev/sdx and add parameter persisten-path
\r
1510 to every menu entry. %flavour_name will be expanded to the flavour of the specific
\r
1511 iso, e.g. grml64 and grml.</p></div>
\r
1514 <div class="sect1">
\r
1515 <h2 id="ressources">9. Online Ressources</h2>
\r
1516 <div class="sectionbody">
\r
1517 <div class="paragraph"><p>Check out the <a href="http://grml.org/grml2usb/">grml2usb webpage</a> and the
\r
1518 <a href="http://git.grml.org/?p=grml2usb.git">grml2usb git repository</a>.</p></div>
\r
1521 <div class="sect1">
\r
1522 <h2 id="bugs">10. Bugs</h2>
\r
1523 <div class="sectionbody">
\r
1524 <div class="paragraph"><p>Please report feedback, bugreports and wishes <a href="#author">to the author</a>.</p></div>
\r
1527 <div class="sect1">
\r
1528 <h2 id="author">11. Author</h2>
\r
1529 <div class="sectionbody">
\r
1530 <div class="paragraph"><p>Michael Prokop <<a href="mailto:mika@grml.org">mika@grml.org</a>></p></div>
\r
1534 <div id="footnotes"><hr /></div>
\r
1536 <div id="footer-text">
\r
1537 Last updated 2011-11-26 20:30:03 CET
\r