github.com/mvdan/u-root-coreutils@v0.0.0-20230122170626-c2eef2898555/docs/index.html (about) 1 <!DOCTYPE html> 2 <html dir="ltr"> 3 4 <head> 5 <meta charset="utf-8"> 6 <meta name="viewport" content="width=device-width, initial-scale=1"> 7 <title>u-root</title> 8 <link rel="shortcut icon" href="images/favicon.ico" type="image/x-icon"> 9 <link rel="apple-touch-icon-precomposed" href="images/apple-touch-icon.png"> 10 <!--<link rel="stylesheet" href="/templates/pandoc-uikit/uikit.css">--> 11 <!--<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/uikit/2.26.4/css/uikit.gradient.css">--> 12 <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/uikit/2.26.4/css/uikit.gradient.min.css"> 13 <link rel="stylesheet" href="/templates/pandoc-uikit/style.css"> 14 <link href="https://vjs.zencdn.net/5.4.4/video-js.css" rel="stylesheet" /> 15 <script src="https://code.jquery.com/jquery-2.2.1.min.js"></script> 16 <!--<script src="https://cdnjs.cloudflare.com/ajax/libs/uikit/2.26.4/js/uikit.min.js"></script>--> 17 <script src="/templates/pandoc-uikit/uikit.js"></script> 18 <script src="/templates/pandoc-uikit/scripts.js"></script> 19 <script src="/bower_components/sticky-kit/jquery.sticky-kit.js "></script> 20 21 <meta name="generator" content="pandoc" /> 22 <title>u-root</title> 23 <style type="text/css">code{white-space: pre;}</style> 24 <style type="text/css"> 25 pre > code.sourceCode { white-space: pre; position: relative; } 26 pre > code.sourceCode > span { display: inline-block; line-height: 1.25; } 27 pre > code.sourceCode > span:empty { height: 1.2em; } 28 .sourceCode { overflow: visible; } 29 code.sourceCode > span { color: inherit; text-decoration: inherit; } 30 div.sourceCode { margin: 1em 0; } 31 pre.sourceCode { margin: 0; } 32 @media screen { 33 div.sourceCode { overflow: auto; } 34 } 35 @media print { 36 pre > code.sourceCode { white-space: pre-wrap; } 37 pre > code.sourceCode > span { text-indent: -5em; padding-left: 5em; } 38 } 39 pre.numberSource code 40 { counter-reset: source-line 0; } 41 pre.numberSource code > span 42 { position: relative; left: -4em; counter-increment: source-line; } 43 pre.numberSource code > span > a:first-child::before 44 { content: counter(source-line); 45 position: relative; left: -1em; text-align: right; vertical-align: baseline; 46 border: none; display: inline-block; 47 -webkit-touch-callout: none; -webkit-user-select: none; 48 -khtml-user-select: none; -moz-user-select: none; 49 -ms-user-select: none; user-select: none; 50 padding: 0 4px; width: 4em; 51 color: #aaaaaa; 52 } 53 pre.numberSource { margin-left: 3em; border-left: 1px solid #aaaaaa; padding-left: 4px; } 54 div.sourceCode 55 { } 56 @media screen { 57 pre > code.sourceCode > span > a:first-child::before { text-decoration: underline; } 58 } 59 code span.al { color: #ff0000; font-weight: bold; } /* Alert */ 60 code span.an { color: #60a0b0; font-weight: bold; font-style: italic; } /* Annotation */ 61 code span.at { color: #7d9029; } /* Attribute */ 62 code span.bn { color: #40a070; } /* BaseN */ 63 code span.bu { } /* BuiltIn */ 64 code span.cf { color: #007020; font-weight: bold; } /* ControlFlow */ 65 code span.ch { color: #4070a0; } /* Char */ 66 code span.cn { color: #880000; } /* Constant */ 67 code span.co { color: #60a0b0; font-style: italic; } /* Comment */ 68 code span.cv { color: #60a0b0; font-weight: bold; font-style: italic; } /* CommentVar */ 69 code span.do { color: #ba2121; font-style: italic; } /* Documentation */ 70 code span.dt { color: #902000; } /* DataType */ 71 code span.dv { color: #40a070; } /* DecVal */ 72 code span.er { color: #ff0000; font-weight: bold; } /* Error */ 73 code span.ex { } /* Extension */ 74 code span.fl { color: #40a070; } /* Float */ 75 code span.fu { color: #06287e; } /* Function */ 76 code span.im { } /* Import */ 77 code span.in { color: #60a0b0; font-weight: bold; font-style: italic; } /* Information */ 78 code span.kw { color: #007020; font-weight: bold; } /* Keyword */ 79 code span.op { color: #666666; } /* Operator */ 80 code span.ot { color: #007020; } /* Other */ 81 code span.pp { color: #bc7a00; } /* Preprocessor */ 82 code span.sc { color: #4070a0; } /* SpecialChar */ 83 code span.ss { color: #bb6688; } /* SpecialString */ 84 code span.st { color: #4070a0; } /* String */ 85 code span.va { color: #19177c; } /* Variable */ 86 code span.vs { color: #4070a0; } /* VerbatimString */ 87 code span.wa { color: #60a0b0; font-weight: bold; font-style: italic; } /* Warning */ 88 </style> 89 <style>.kommentar {display: none;}</style> 90 91 </head> 92 93 <body> 94 95 96 <div class="uk-container uk-container-center uk-margin-top uk-margin-large-bottom"> 97 98 <div class="uk-grid" data-uk-grid-margin> 99 <div class="uk-width-1-1"> 100 <h1 class="uk-heading-large">u-root</h1> 101 </div> 102 </div> 103 104 <div class="uk-grid" data-uk-grid-margin > 105 <div class="uk-width-medium-1-4"> 106 <div class="uk-overflow-container" data-uk-sticky="{top:25,media: 768}"> 107 <div class="uk-panel uk-panel-box menu-begin" > 108 109 <ul> 110 <li><a href="#u-root">u-root</a> 111 <ul> 112 <li><a href="#setup">Setup</a></li> 113 <li><a href="#submitting-changes">Submitting Changes</a></li> 114 <li><a href="#faqs">FAQs</a> 115 <ul> 116 <li><a href="#so-why-u-root">So, why “u-root”?</a></li> 117 <li><a href="#any-publications">Any publications?</a></li> 118 </ul></li> 119 <li><a href="#community">Community</a></li> 120 <li><a href="#contributors">Contributors</a></li> 121 <li><a href="#logo">Logo</a></li> 122 </ul></li> 123 </ul> 124 125 </div> 126 </div> 127 </div> 128 129 <div class="uk-width-medium-3-4"> 130 <p><img src="img/u-root-logo.png" width="300" alt="u-root logo" /><br /> 131 </p> 132 <h1 id="u-root">u-root</h1> 133 <p>u-root embodies four different projects.</p> 134 <ul> 135 <li><p>Go versions of many standard Linux tools, such as <a href="https://github.com/u-root/u-root/tree/master/cmds/core/ls/ls.go">ls</a>, <a href="https://github.com/u-root/u-root/tree/master/cmds/core/cp/cp.go">cp</a>, or <a href="https://github.com/u-root/u-root/tree/master/cmds/core/shutdown/shutdown.go">shutdown</a>. See <a href="https://github.com/u-root/u-root/tree/master/cmds/core">cmds/core</a> for most of these.</p></li> 136 <li><p>A way to compile many Go programs into a single binary with <a href="https://github.com/u-root/u-root/tree/master/pkg/bb/README.md">busybox mode</a>.</p></li> 137 <li><p>A way to create initramfs (an archive of files) to use with Linux kernels.</p></li> 138 <li><p>Go bootloaders that use <code>kexec</code> to boot Linux or multiboot kernels such as ESXi, Xen, or tboot. They are meant to be used with <a href="https://www.linuxboot.org">LinuxBoot</a>. With that, parsers for <a href="https://github.com/u-root/u-root/tree/master/pkg/boot/grub">GRUB config files</a> or <a href="https://github.com/u-root/u-root/tree/master/pkg/boot/syslinux">syslinux config files</a> are to make transition to LinuxBoot easier.</p></li> 139 </ul> 140 <h2 id="setup">Setup</h2> 141 <p>On an Ubuntu system, install prerequisites and ensure Go is at least version 1.13:</p> 142 <div class="sourceCode" id="cb1"><pre class="sourceCode sh"><code class="sourceCode bash"><span id="cb1-1"><a href="#cb1-1" aria-hidden="true" tabindex="-1"></a><span class="fu">sudo</span> apt-get install git golang build-essential</span> 143 <span id="cb1-2"><a href="#cb1-2" aria-hidden="true" tabindex="-1"></a><span class="ex">go</span> version</span></code></pre></div> 144 <p>Set your <code>GOPATH</code>:</p> 145 <div class="sourceCode" id="cb2"><pre class="sourceCode sh"><code class="sourceCode bash"><span id="cb2-1"><a href="#cb2-1" aria-hidden="true" tabindex="-1"></a><span class="bu">export</span> <span class="va">GOPATH=</span><span class="st">"</span><span class="va">$HOME</span><span class="st">/go"</span></span></code></pre></div> 146 <p>Clone u-root:</p> 147 <div class="sourceCode" id="cb3"><pre class="sourceCode sh"><code class="sourceCode bash"><span id="cb3-1"><a href="#cb3-1" aria-hidden="true" tabindex="-1"></a><span class="ex">go</span> get github.com/u-root/u-root</span></code></pre></div> 148 <p>Generate an initramfs containing u-root Go tools:</p> 149 <div class="sourceCode" id="cb4"><pre class="sourceCode sh"><code class="sourceCode bash"><span id="cb4-1"><a href="#cb4-1" aria-hidden="true" tabindex="-1"></a><span class="ex">u-root</span> <span class="at">-format</span><span class="op">=</span>cpio <span class="at">-o</span> initramfs.cpio</span></code></pre></div> 150 <p>You can use this initramfs with your favorite Linux kernel in QEMU to try it out.</p> 151 <p>More instructions can be found in the repo’s <a href="https://github.com/u-root/u-root/blob/master/README.md">README.md</a>.</p> 152 <h2 id="submitting-changes">Submitting Changes</h2> 153 <p>We use <a href="https://github.com/u-root/u-root/pulls">GitHub Pull Requests</a> for code review. Pull requests must receive one approval and pass CI before being merged.</p> 154 <h2 id="faqs">FAQs</h2> 155 <h3 id="so-why-u-root">So, why “u-root”?</h3> 156 <p>It’s to reflect a universal root, you can mount on every local and get a userland portable (it’s a goal).</p> 157 <h3 id="any-publications">Any publications?</h3> 158 <ul> 159 <li><a href="https://www.usenix.org/system/files/conference/atc15/atc15-paper-minnich.pdf">USENIX 2015 ATC Paper</a></li> 160 <li><a href="https://www.usenix.org/conference/atc15/technical-session/presentation/minnich">USENIX 2015 ATC Talk</a></li> 161 <li>Related: Embedded Linux Conference 2017 LinuxBoot Talk (<a href="https://www.youtube.com/watch?v=iffTJ1vPCSo">YouTube video</a>, <a href="https://schd.ws/hosted_files/osseu17/84/Replace%20UEFI%20with%20Linux.pdf">slides</a>)</li> 162 </ul> 163 <h2 id="community">Community</h2> 164 <ul> 165 <li><a href="https://groups.google.com/forum/#!forum/u-root">Join the mailing list</a></li> 166 <li><a href="https://osfw.slack.com/">Join the Open Source Firmware Slack team</a> (Get an invite <a href="https://slack.osfw.dev">here</a>.)</li> 167 <li><a href="https://github.com/u-root/u-root/blob/master/roadmap.md">Checkout the roadmap</a></li> 168 </ul> 169 <h2 id="contributors">Contributors</h2> 170 <ul> 171 <li><a href="https://github.com/rminnich">Ron Minnich</a></li> 172 <li><a href="https://github.com/mirtchovski">Andrey Mirtchovski</a></li> 173 <li><a href="https://github.com/rhiguita">Alexandre Beletti</a></li> 174 <li><a href="https://github.com/ryukinix">Manoel Machado</a></li> 175 <li><a href="https://github.com/rafaelcn">Rafael C. Nunes</a></li> 176 <li><a href="https://github.com/mathgamain">Matheus Pinto Rodrigues</a></li> 177 <li><a href="https://github.com/GanShun">Gan Shun Lim</a></li> 178 <li><a href="https://github.com/rjoleary">Ryan O’Leary</a></li> 179 <li><a href="https://github.com/hugelgupf">Chris Koch</a></li> 180 <li><a href="https://github.com/insomniacslk">Andrea Barberio</a></li> 181 <li><a href="https://github.com/vejmarie">Jean-Marie Verdun</a></li> 182 <li><a href="https://github.com/n-canter">Max Shegai</a></li> 183 </ul> 184 <h2 id="logo">Logo</h2> 185 <p>The Go gopher was designed by Renee French. The u-root logo design is licensed under the Creative Commons 3.0 Attributions license.</p> 186 <p>The logo is communicating several things:</p> 187 <ul> 188 <li><p>u-root has several flavors: firmware and as a root file system</p></li> 189 <li><p>the gopher at the bottom is a firmware u-root; that gopher brings the machine up, hence the wrench. Its work is also done, so it is resting.</p></li> 190 <li><p>the other gophers can make more copies of u-root; hence the u-root logo on their chest.</p></li> 191 <li><p>the highest gopher is showing how u-root is a good root file system for a VM.</p></li> 192 <li><p>the U itself is a stylized tree, evocative of roots.</p></li> 193 </ul> 194 </div> 195 </div> 196 197 </script> 198 <script src="https://vjs.zencdn.net/5.4.4/video.js"></script> 199 </div> 200 </body> 201 </html>