TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

Bored? How about trying a Linux speed run?

495 pointsby lwhsiaoabout 5 years ago

45 comments

dlossabout 5 years ago
Reminds me of David Beazley&#x27;s talk about being locked in a hidden vault to analyse 1.5 TBytes of C++ source code. No tools or internet connection, but a Python interpreter. <a href="https:&#x2F;&#x2F;pyvideo.org&#x2F;pycon-us-2014&#x2F;discovering-python.html" rel="nofollow">https:&#x2F;&#x2F;pyvideo.org&#x2F;pycon-us-2014&#x2F;discovering-python.html</a>
评论 #22846757 未加载
评论 #22850754 未加载
sdenton4about 5 years ago
This is basically what early Gentoo releases were like... A hilariously minimal tool chain and a txt guide to compiling and configuring every piece between basically nothing and a functioning web browser. A typical speed run took a day because compilation times were long. And if you realized late that you&#x27;d made a fatal mistake, starting over took a loooong time.<p>#pepperidgefarmremembers
评论 #22849831 未加载
评论 #22850428 未加载
评论 #22850439 未加载
评论 #22849724 未加载
评论 #22852760 未加载
评论 #22864439 未加载
评论 #22850288 未加载
carapaceabout 5 years ago
Phase 1: Bit bang a Three-Instruction Forth: &quot;A 3-INSTRUCTION FORTH FOR EMBEDDED SYSTEMS WORK&quot; by Frank Sergeant<p>&gt; Illustrated on the Motorola MC68HC11 ... Copyright 1991<p><a href="http:&#x2F;&#x2F;pygmy.utoh.org&#x2F;3ins4th.html" rel="nofollow">http:&#x2F;&#x2F;pygmy.utoh.org&#x2F;3ins4th.html</a><p>Phase 2: &quot;A BNF PARSER IN FORTH&quot; Bradford J. Rodriguez<p>&gt; (This article first appeared in ACM SigFORTH Newsletter vol. 2 no. 2)<p><a href="https:&#x2F;&#x2F;www.bradrodriguez.com&#x2F;papers&#x2F;bnfparse.htm" rel="nofollow">https:&#x2F;&#x2F;www.bradrodriguez.com&#x2F;papers&#x2F;bnfparse.htm</a><p>Phase 3: &quot;Metal to the Desktop in 20,000 LoC&quot;<p>Using principles from OMeta ( <a href="https:&#x2F;&#x2F;en.wikipedia.org&#x2F;wiki&#x2F;OMeta" rel="nofollow">https:&#x2F;&#x2F;en.wikipedia.org&#x2F;wiki&#x2F;OMeta</a> ) recapitulate the VPRI STEPS project:<p>&quot;STEPS Toward the Reinvention of Programming, 2012 Final Report&quot;<p>&gt; Submitted to the National ScienceFoundation (NSF) October 2012<p>&gt; (In random order) Yoshiki Ohshima, Dan Amelang,Ted Kaehler, Bert Freudenberg, Aran Lunzer, Alan Kay,Ian Piumarta, Takashi Yamamiya, Alan Borning,Hesam Samimi, Bret Victor, Kim Rose<p><a href="http:&#x2F;&#x2F;www.vpri.org&#x2F;pdf&#x2F;tr2012001_steps.pdf" rel="nofollow">http:&#x2F;&#x2F;www.vpri.org&#x2F;pdf&#x2F;tr2012001_steps.pdf</a>
jml7c5about 5 years ago
I think an important category has to be: no outside servers designed to help with this speedrunning challenge. Without such a rule, one can get an outside computer to do much of the work. One would merely write a small program that connects to the known IP and pulls bootstrap code straight into memory. (Granted, still a fair piece of work, but without such a rule the finish line for the speedrun would become &quot;establish a TCP connection&quot;).<p>EDIT: I wonder if including the Linux kernel + C library is just too much. How minimal could one go with this challenge, yet have it still be fun&#x2F;doable in a reasonable duration? You start with just MS-DOS on the disk? Or a Forth interpreter? Or maybe you start with a blank disk, but you get to twiddle bits one at a time before you first use it, in the vein of the Altair 8800?<p>EDIT 2: An even more entertaining idea than some sort of 8800-style toggle switch interface: you start with an actual Altair 8800, then get a few &quot;stepping stone&quot; computers that have just enough hardware compatibility that you can transfer data from one to the next. The final computer is a modern PC with a network connection.
评论 #22847189 未加载
INTPenisabout 5 years ago
This is how I used to live my life. Sort of. I mean early 2000s when I had left home and moved to a far away city for a job in IT. All I had was a stolen 256M RAM laptop with FreeBSD. No internet and no TV at home because I lived in a shitty apartment building.<p>At work I had all the bandwidth and resources I could use.<p>So I downloaded all I could during the weekdays and during evenings and weekends I&#x27;d just browse manuals and try things on my laptop, in my own little virtual LAN.<p>That&#x27;s how you learn, kids.
评论 #22847027 未加载
评论 #22847501 未加载
评论 #22847159 未加载
评论 #22854429 未加载
评论 #22846954 未加载
butzabout 5 years ago
I&#x27;d like to suggest &quot;Linux From Scratch&quot; (<a href="http:&#x2F;&#x2F;www.linuxfromscratch.org&#x2F;lfs&#x2F;" rel="nofollow">http:&#x2F;&#x2F;www.linuxfromscratch.org&#x2F;lfs&#x2F;</a>) category. It might be easier for beginners, as it has definite start and finish states and instructions. It would be interesting to do a blind run to see how long it takes and later try a &quot;real&quot; speed run to optimize it as much as possible.
jake_morrisonabout 5 years ago
Embdded development is like this sometimes.<p>Start with some hardware. If you are lucky, you get a board support package with a Linux kernel. Otherwise you need to write some drivers to talk to the hardware. Progressively get it to the point that it will boot up and get on the network. Then get the application running.<p>Microcontroller development is even worse. When you don&#x27;t have any space, you may actually end up writing everything in C from scratch.
评论 #22847207 未加载
danieldkabout 5 years ago
If you have bash, you could retrieve wget or CURL and go from there.<p><pre><code> { echo -e &quot;GET &#x2F; HTTP&#x2F;1.0\r\nHost: ftp.gnu.org\r\n\r&quot; &gt;&amp;3; cat &lt;&amp;3 ; } 3&lt;&gt; &#x2F;dev&#x2F;tcp&#x2F;ftp.gnu.org&#x2F;80</code></pre>
评论 #22846918 未加载
评论 #22846880 未加载
评论 #22848084 未加载
评论 #22913624 未加载
评论 #22846865 未加载
brian_hermanabout 5 years ago
I did it on mega. But I&#x27;ll post youtube later I have to verify my account. <a href="https:&#x2F;&#x2F;mega.nz&#x2F;file&#x2F;ZY1BGLgC#VVIxq6HYB8UWXAF5d3S6aQBLKog89OPynqvFvVew9-M" rel="nofollow">https:&#x2F;&#x2F;mega.nz&#x2F;file&#x2F;ZY1BGLgC#VVIxq6HYB8UWXAF5d3S6aQBLKog89O...</a> Youtube link: <a href="https:&#x2F;&#x2F;www.youtube.com&#x2F;watch?v=8bSBBnLLhko" rel="nofollow">https:&#x2F;&#x2F;www.youtube.com&#x2F;watch?v=8bSBBnLLhko</a>
anthkabout 5 years ago
Writting a shell is easy, but it&#x27;s already done (do&#x27;h). You could be restricted to a really basic one, with no cd having to reimplenent that yourself. A simple &quot;cd&quot; command taking ARGV as the path would be around 10 lines in C.<p>Reimplementing echo would be the obvious second thing to do, and later, a barebones cat a la plan9&#x2F;OpenBSD. Finally the 3rd basic tool would be an ed(1) clone without regex support.<p>ed(1) can work as a simple &quot;more&quot; like pager, too. Add add readonly flag to argc&#x2F;argv so it fopens the file with just read permissions and you have the best setting to start. ed(1) is much easier to write than a visual editor.<p>Any TCP&#x2F;IP stack related would be hard, but it the libc&#x2F;kernel has a basic implementation bundled, I&#x27;d write a gopher client and I&#x27;d declare the problem solved, as I can fetch everything from here.<p>Gopher is much easier to implement than banging the FTP ports. Also you can do a barebones IRC client with few lines. Nothing too complex, but usable enough.<p>Or better: write a netcat clone, <a href="https:&#x2F;&#x2F;git.2f30.org&#x2F;openbsd-nc&#x2F;" rel="nofollow">https:&#x2F;&#x2F;git.2f30.org&#x2F;openbsd-nc&#x2F;</a> connect to gopher, fetch the specs, write a dumb gopher client, (or fetch sacc(1), you can compile it without ncurses by editing the Makefile), connect to gpoherpedia&#x2F;gutenberg Gopher proxies to fetch all the documentation.<p>gopher:&#x2F;&#x2F;1436.ninja&#x2F;1&#x2F;Project_Gutenberg_in_Gopherspace<p>gopher:&#x2F;&#x2F;gopherpedia.com<p>But the netcat clone combined with the ed editor could serve as a basic IRC client with FIFO files, also as a basic gopher client if you don&#x27;t want to fetch sacc(1). Once you get connected to an IRC channel in order to seek help, among Gopher, you&#x27;ll have tons of information.<p>Also it&#x27;s the most Unix-y way to solve a problem, by far.
评论 #22847912 未加载
评论 #22846922 未加载
m463about 5 years ago
A similar sort of exercise might be to just install Arch Linux to a working desktop or some other use case.<p>Arch Linux puts responsibility for the install on your shoulders based on your needs and decisions.<p>In the end, you get a VERY up-to-date installation of linux, without needless bloat, and it stays that way due to rolling updates.
评论 #22848699 未加载
评论 #22847634 未加载
fantispugabout 5 years ago
I&#x27;ve thought about a variant of this with Baking Pi [1]. That takes you through assembly to the point of having a Raspberry Pi with a minimal terminal (with just an external USB driver the author wrote).<p>I think it would be interesting to see how quickly you could get from there to a useful system, say one where you could download the USB driver from github and compile it. But I definitely don&#x27;t know enough to do that.<p>[1] <a href="https:&#x2F;&#x2F;www.cl.cam.ac.uk&#x2F;projects&#x2F;raspberrypi&#x2F;tutorials&#x2F;os&#x2F;" rel="nofollow">https:&#x2F;&#x2F;www.cl.cam.ac.uk&#x2F;projects&#x2F;raspberrypi&#x2F;tutorials&#x2F;os&#x2F;</a>
lcallabout 5 years ago
This is a very cool idea. I have thought similarly, but for a &quot;create current civilization from scratch&quot; game (edit: this is a real-life challenge, not on a computer, and maybe not even as a competition): Start in an empty open area, with nothing but nature and the low-tech clothing you wear and means of communication with outside. The only things you can exchange with outside are: any information at all (so, maybe use a smartphone but only to read&#x2F;research, or a &quot;border&quot; for q&amp;a with anyone), and &quot;traded&quot; goods from similarly-managed areas. Find and record the shortest (reasonable? by some definition?) path to building a smartphone (or such) with its supporting infrastructure.
评论 #22849796 未加载
评论 #22849216 未加载
评论 #22849634 未加载
qzncabout 5 years ago
I more serious variation on the topic: <a href="http:&#x2F;&#x2F;bootstrappable.org&#x2F;" rel="nofollow">http:&#x2F;&#x2F;bootstrappable.org&#x2F;</a>
nonamenosloganabout 5 years ago
I&#x27;ve spent many hours doing similar things to this--my most recent was building Virtualbox VM&#x27;s of the more interesting abandoned and ancient OSs from WinWorldPC. So far I&#x27;ve got working versions of OpenSTEP, BeOS, SyllableOS, Plan9, Solaris, ReactOS, Memphis&#x2F;Neptune&#x2F;Chicago, OS&#x2F;2 Warp and ECommStation, and another dozen or so. When I say working, I mean bootable with a network connection of some type, though mine are usually a little higher up the stack than raw UDP.<p>Thanks for a great read, love ideas like this if for nothing else but to keep one&#x27;s nerdiness and thirst for obscure trivia alive.
m3atabout 5 years ago
Close enough, there are distro install speedrun: <a href="https:&#x2F;&#x2F;www.reddit.com&#x2F;r&#x2F;linux&#x2F;comments&#x2F;7kg7i1&#x2F;install_gentoo_speedrun_l_i_v_e&#x2F;" rel="nofollow">https:&#x2F;&#x2F;www.reddit.com&#x2F;r&#x2F;linux&#x2F;comments&#x2F;7kg7i1&#x2F;install_gento...</a><p>Then of course, once you have the OS you can attempt the classical editor speedrun: <a href="https:&#x2F;&#x2F;www.reddit.com&#x2F;r&#x2F;speedrun&#x2F;comments&#x2F;8rqkzz&#x2F;vim_exit_speedrun_wr_25013&#x2F;" rel="nofollow">https:&#x2F;&#x2F;www.reddit.com&#x2F;r&#x2F;speedrun&#x2F;comments&#x2F;8rqkzz&#x2F;vim_exit_s...</a>
评论 #22848523 未加载
eqvinoxabout 5 years ago
The C library includes the stub resolver &#x2F; getaddrinfo(), so you don&#x27;t need to memorize any IP addresses ;D
bschwindHNabout 5 years ago
Bored? Write a touchpad driver based on libinput which gives you identical mouse acceleration between Macbook trackpads and linux trackpads.
评论 #22847675 未加载
评论 #22846999 未加载
评论 #22847111 未加载
评论 #22846801 未加载
bawolffabout 5 years ago
I imagine at some point, some hardcore person would just end up doing echo -e &#x27;bunch of machine code here&#x27; &gt; file
joantuneabout 5 years ago
Bored?! I&#x27;m sure that there are a gazillion more useful - and even fun - things to do
评论 #22848669 未加载
bscphilabout 5 years ago
&gt; Who knows how far down the stack this could go?<p>Seems to be like the obvious initial way to up the ante would be to get rid of the compiler. How would you go about bootstrapping your way out if all you had was the Linux kernel, glibc, and the Bourne shell?
评论 #22846768 未加载
评论 #22846758 未加载
评论 #22849876 未加载
评论 #22846752 未加载
lwhabout 5 years ago
These sound like things that used to be regular part of install&#x2F;setup on BSD and Linux. It&#x27;s so much nicer now not having to setup the network, GUI or disks. Nevermind the week of downloading all the floppy images.
lilSebastianabout 5 years ago
What is &quot;the Stevens book&quot; mentioned here? TIA
评论 #22846846 未加载
pnakoabout 5 years ago
The last thing I would want to do is re-invent Unix once again.<p>I would probably try to hack myself some sort of Forth-like language and have fun.
评论 #22848911 未加载
p410n3about 5 years ago
I have done LEMP Speedruns in the past.<p>Start with an Debian USB stick and finish when you see the output of phpinfo() in a browser
rmetzlerabout 5 years ago
Why would you write a terrible editor in C and what would you use to type that in?<p>Isn’t cat - &gt; file.txt or echo enough?<p>AFAIK bash is able to set up tcp connections. Can’t you just download a static compiled editor through this?<p>Maybe you don’t have bash. So what exactly is the starting point?
评论 #22846823 未加载
zitterbewegungabout 5 years ago
To avoid memorizing certain things to win speed running Linux could be broken down into categories so that it can be a fair comparison. An example would be no memorization or no networking . The current speeedrin community does this already.
评论 #22849200 未加载
29athrowawayabout 5 years ago
You get all this functionality from the kernel for free.<p><a href="http:&#x2F;&#x2F;man7.org&#x2F;linux&#x2F;man-pages&#x2F;man2&#x2F;syscalls.2.html" rel="nofollow">http:&#x2F;&#x2F;man7.org&#x2F;linux&#x2F;man-pages&#x2F;man2&#x2F;syscalls.2.html</a>
评论 #22846743 未加载
romesabout 5 years ago
It&#x27;d be very interesting to see an actual &quot;starter kit&quot; :I<p>The original idea could even be adapted to more than one degree of difficulty... I love the idea, it&#x27;s, at least, a fascinating concept
Aissenabout 5 years ago
That&#x27;s basically gokrazy : <a href="https:&#x2F;&#x2F;gokrazy.org&#x2F;" rel="nofollow">https:&#x2F;&#x2F;gokrazy.org&#x2F;</a><p>Or is the game to do it only with the syscall interface and no library?
brian_hermanabout 5 years ago
<a href="https:&#x2F;&#x2F;www.youtube.com&#x2F;watch?v=8bSBBnLLhko" rel="nofollow">https:&#x2F;&#x2F;www.youtube.com&#x2F;watch?v=8bSBBnLLhko</a>
imprettycoolabout 5 years ago
I know this is kind of a joke but this will never catch on the way videogame speedruns do. Watching someone else write code is incredibly boring
eloisiusabout 5 years ago
This would be a really fun competition in a maddening way. If somebody put up a VM to start with, I&#x27;d bite. Or at least, if there was some kind of criteria for a starting point, putting together a bare bones distro wouldn&#x27;t be too hard. I can see bootstrapping a basic editor using cat and working all the way through a TCP stack, DNS, etc. but my mind blanks at implementing TLS. Seems like it would be a requirement to do anything meaningful on the internet at this point, but I wouldn&#x27;t even know where to begin.
评论 #22848594 未加载
exdsqabout 5 years ago
I&#x27;ll bite and try this out myself, although I expect it will take a long time to work everything out...
tyingqabout 5 years ago
I suppose TLS might be something of a barrier. Plain old ftp and http sites are disappearing.
评论 #22848209 未加载
fizixerabout 5 years ago
The first thing you should do with the C compiler is create a scheme&#x2F;lisp interpreter.
radium3dabout 5 years ago
So, get Arch Linux running via UEFI (no grub) with gnome on boot? Always a fun challenge!
6510about 5 years ago
A dumb idea I had was to turn each and every occupation into a competitive sports.
z3t4about 5 years ago
Something similar is installing an unsupported OS or fresh OS via SSH.
hattoriabout 5 years ago
First sentence: &quot;I have a lot of dumb ideas.&quot;<p>One of us! One of us!
adrianmonkabout 5 years ago
Ugh. As a former sysadmin, I&#x27;ve done more than plenty of permutations of this game already. Playing it again wouldn&#x27;t cure boredom for me.
DeathArrowabout 5 years ago
&gt;&quot; About 15 years ago, I mused about the idea of having a &quot;desert island machine&quot;. This is where I&#x27;d put someone in a room with a box that has a couple of hard drives and a working network connection. HD #1 is blank. HD #2 has a few scraps of a (Linux) OS on it: bootloader, kernel, C library and compiler, that sort of thing. There&#x27;s a network connection of some sort, and that&#x27;s about it.<p>There are no editors and nothing more advanced than &#x27;cat&#x27; to read files. You don&#x27;t have jed, joe, emacs, pico, vi, or ed (eat flaming death). Don&#x27;t even think about X. telnet, nc, ftp, ncftp, lftp, wget, curl, lynx, links? Luxury! Gone. Perl, Python and Ruby? Nope.<p>There&#x27;s your situation. What do you do? &quot;<p>I would swim, do some sunbathing, eat coconuts, do some fishing and generally enjoy the situation. No work, no stress, nobody to bother. :)
评论 #22848306 未加载
评论 #22849112 未加载
评论 #22851117 未加载
评论 #22848818 未加载
评论 #22849161 未加载
评论 #22850033 未加载
b0rsukabout 5 years ago
Speedrunning with root. What can possibly go wrong...
zerm778about 5 years ago
how about no
DeathArrowabout 5 years ago
&gt;&quot; So here&#x27;s the pitch: Linux speedruns. By that, I don&#x27;t mean &quot;speedrunning a game on a Linux box&quot; (like emulation, or something). Nope.<p>I mean speedrunning the Linux situation itself. Start with a minimal system and get yourself to the point where you can do something meaningful (like reading cat pictures on Reddit). &quot;<p>I&#x27;d rather do something useful or at least pleasant. I don&#x27;t have an infinite amount of time and I don&#x27;t like to waste it.
评论 #22848121 未加载
评论 #22849856 未加载
评论 #22848686 未加载