Lunduke
News • Science & Tech
The Fork Bomb: What it is, how it works, and where it originated
The idea started in 1969... and it's been causing computers to crash ever since.
December 03, 2023
post photo preview
:(){ :|:& };:

That simple line has been crashing systems in the Linux world for years — It is known as the (infamous) “BASH Fork Bomb”.

When run in a GNU/BASH shell, this BASH variant of the Fork Bomb will bring your average Linux system to its knees, lickety-split. A mere handful of characters that can cause a computer to cry “Uncle.”

But what, exactly, is a “Fork Bomb”? How do they work? And where on this green Earth of ours were they first created?

Come with me on a journey into the history, design, and usage of one of the most dastardly ideas in all of computing… of The Fork Bomb!

What is a Fork Bomb?

The idea of a Fork Bomb is simple: Create a piece of code that does one thing and one thing only: replicate running instances of itself. And do so as quickly as possible.

Here, a visual will help drive the idea home.

In this case each Bunny Rabbit represents one instance of the Fork Bomb. Each bunny makes two new bunnies. Quickly. Multiplying like, well, rabbits.

Each of those adorable little bunny rabbits may not take up much RAM… or much CPU time… but imagine 20 of them. Or 1000. Or, like, a bazillion?! That Fork Bomb will continue making running copies of itself just as long as the system allows it to (by continuing to have available memory or not fully crash).

With how quickly each Fork Bomb replicates itself… and the number of copies growing exponentially… you can see how they can become a problem in a hurry. Often causing a system to lock up quicker than you can say, “Maybe I shouldn't have pressed Enter.”

A real-world example… and how it works

Let’s take a look at that BASH version of the Fork Bomb again (as that is one of the most popular and famous examples).

(If you don’t know how BASH scripting works, no worries. I’ll break it down… make it nice and easy.)

:(){ :|:& };:

Ok. So how does this, ridiculous looking, collection of semi-random seeming characters, actually work?

Let’s break that apart into multiple lines to make it all easier to read.

: ( ) {

   : | : &

} ; :

This… is a BASH script function.

But there’s something… weird about it. Note the many usages of “:”? In this case “:” is being used as a function name.

“Why is using “:” as a function name weird,” you ask?

Because, on most UNIX-y systems, it is not allowed to use a character in a function name other than letters and numbers (and underscores). But the GNU version of BASH — which is commonly used on oh-so-many Linux systems — allows : and so many other characters to be used.

Why does GNU allow a “:”? Who knows. GNU be crazy.

Regardless…

Let’s replace the “:” in that BASH script with “rabbit”. That will, in addition to making it run on more UNIX systems, make this a bit easier to read.

rabbit() {
rabbit | rabbit &
}; rabbit

There. So much better. Here we go. Line by line.

Line 1: rabbit() {

That first line does something simple. It defines a function named “rabbit”. That’s it and that’s all.

Line 2: rabbit | rabbit &

Line 2 is the insidious part.

It calls the function named “rabbit”, and sends the output of that function to the function named “rabbit.”

But, here’s the thing, there really isn’t any output of the “rabbit” function. So this is really just a fancy way of calling the “rabbit” function twice… at the same time.

Yeah. The “rabbit” function calls itself, from within itself, then calls itself again.

Oh, and that “&” at the end? That's the BASH way of telling “rabbit” to run in the background.

The net result? Every “rabbit”, makes two new “rabbit”s.

Line 3: }; rabbit

That last nine simply ends the “rabbit” function… and then calls itself.

Note: I highly recommend not running this code on your system unless you do so in a virtual machine. Without taking the proper precautions… this will bring your system to its knees.

Every variation of a Fork Bomb operates in a roughly similar fashion. A small piece of code that creates copies of itself… repeatedly. Thus eternally replicating itself until the system runs out of resources.

The first Fork Bomb

The very first known usage of a “Fork Bomb” was way back in 1969 at the University of Washington.

There, a Burroughs B5500 computer had been installed three years earlier. A big computer that provided the first time-sharing system on the University of Washington campus (through a series of dial-up modems running at 110 baud). This was also the first computer at the University of Washington to provide disk storage for user files. Pretty cool.

A Burroughs B-5500. Not the one at the U of W, though. Classy looking machine, right?

On that big, beautiful Burroughs B-5500, someone reportedly wrote a small bit of code that would make two copies of itself — over and over again — until the memory of the machine was full and the entire system would crash.

That intrepid programmer named that tiny little program, appropriately: “RABBITS”

Fun historical tidbit: RABBITS for the Burroughs B-5500 was not, technically the first computer virus. That distinction appears to go to the 1971 “Creeper Virus”. While RABBITS predated Creeper by a good two years… RABBITS doesn’t really act like a virus. It requires a user to explicitly run it in order to cause its own mischeif.

The 1974 “Wabbit”

A similar piece of code was written on an IBM System/360, a few years later, in 1974. Clearly inspired by “RABBITS”, this new code was called “Wabbit” and was, as Elmer Fudd might say, quite “wascally”.

The IBM System/360 Model 22 control panel. That thing was awesome looking.

Legend has it that the individual who created “Wabbit” ran the program on the System/360 at work… causing the entire system to crash. The man, again according to legend, lost his job.

Fun bit-o-trivia: As years went on any program that would self-replicate when ran by the user… but wasn’t actually a virus… would become known as a "wabbit.” in honor of this particular event.

Some other variations on the Fork Bomb

There have been Fork Bomb type bits of code written in just about every language you can imagine. At the beginning we covered how to write a Fork Bomb in BASH. But, because this sort of mayhem is simply too much fun, below you will find code to create similar bits of functionality in several other programming languages.

Enjoy.

Just… you know… try not to get yourself fired.

Fork Bomb in C:

int main(void) {
for (;;) {
    fork();
}
}
Fork Bomb in Python:

#!/usr/bin/env python

    import os
    while True: os.fork()

Fork Bomb in Ruby:

#!/usr/bin/env ruby
loop { fork { bomb } }
community logo
Join the Lunduke Community
To read more articles like this, sign up and join my community today
6
What else you may like…
Videos
Podcasts
Posts
Articles
Google Intentionally Cripples Nextcloud Android App

Nextcloud is an open source competitor to Google Drive. Google doesn't like competition.

00:11:06
Yet Another Linux Distro Ditches Firefox for Brave

First Zorin OS, now the Fedora-based Nobara changes the default web browser.

00:18:50
Coinbase Hacker Demands $20 Million Dollar Ransom

In filing, Coinbase says damages may be upward of $400 Million.

00:14:27
November 22, 2023
The futility of Ad-Blockers

Ads are filling the entirety of the Web -- websites, podcasts, YouTube videos, etc. -- at an increasing rate. Prices for those ad placements are plummeting. Consumers are desperate to use ad-blockers to make the web palatable. Google (and others) are desperate to break and block ad-blockers. All of which results in... more ads and lower pay for creators.

It's a fascinatingly annoying cycle. And there's only one viable way out of it.

Looking for the Podcast RSS feed or other links? Check here:
https://lunduke.locals.com/post/4619051/lunduke-journal-link-central-tm

Give the gift of The Lunduke Journal:
https://lunduke.locals.com/post/4898317/give-the-gift-of-the-lunduke-journal

The futility of Ad-Blockers
November 21, 2023
openSUSE says "No Lunduke allowed!"

Those in power with openSUSE make it clear they will not allow me anywhere near anything related to the openSUSE project. Ever. For any reason.

Well, that settles that, then! Guess I won't be contributing to openSUSE! 🤣

Looking for the Podcast RSS feed or other links?
https://lunduke.locals.com/post/4619051/lunduke-journal-link-central-tm

Give the gift of The Lunduke Journal:
https://lunduke.locals.com/post/4898317/give-the-gift-of-the-lunduke-journal

openSUSE says "No Lunduke allowed!"
September 13, 2023
"Andreas Kling creator of Serenity OS & Ladybird Web Browser" - Lunduke’s Big Tech Show - September 13th, 2023 - Ep 044

This episode is free for all to enjoy and share.

Be sure to subscribe here at Lunduke.Locals.com to get all shows & articles (including interviews with other amazing nerds).

"Andreas Kling creator of Serenity OS & Ladybird Web Browser" - Lunduke’s Big Tech Show - September 13th, 2023 - Ep 044

Hands-On with COSMIC Alpha 7 - Full Walkthrough of System76’s New Linux Desktop

System76 dropped COSMIC Alpha 7, and it’s a big step forward in their custom Rust-based desktop environment. Join me as I walk through the newest changes and features to see what's cooking for this desktop. From draggable workspaces to polished UI tweaks, COSMIC is shaping up to be a serious contender in the Linux desktop space.

May 15, 2025

Jeremy covers Lunduke's Minecraft story.

placeholder
May 15, 2025

Google wants to "help" you. By watching your screen to "fight scams". 🤔

How Android 16 will fight scams for you | Mashable
https://mashable.com/article/android-16-scam-protection-features

50% off Monthly, Yearly Subscriptions! Lifetime Subs for $100! Let's get everyone subscribing to The Lunduke Journal!

The number of free subscribers to The Lunduke Journal has absolutely exploded — across a bunch of platforms — which is truly amazing. The real Tech News is spreading farther than ever.

In fact, the free subscriber growth is so utterly massive, that if even a tiny fraction of you became a paying subscriber… The Lunduke Journal would become comfortably financially set for a very long time. Able to continue reporting on Big Tech — and corrupt Tech Foundations — well into the future.

All without taking a penny from Big Tech.

With that in mind, let’s do something awesome… something that will make Big Tech really grumpy.

Let’s get as many people subscribing to The Lunduke Journal as possible. Right now. This week. Let’s make this Big-Tech-Free, Non-Woke Tech News publication financially set for a good, long time.

To give everyone a kick-in-the-butt to help make that happen, I’m going to discount absolutely every type of subscription in a crazy way — through Friday, May 9th.

  • %50 off Monthly — Now $3 / Month (was $6 / Month)

  • %50 off Yearly — Now $27 / Year (was $54 / Year)

  • %50 off Yearly MP4 Downloads — Now $27 / Year (was $54 / Year)

  • %50 off Lifetime Subscriptions — Now $100 (was $200)

That Lifetime Subscription one is crazy.

Seriously. Make a one-time donation of $100, and be subscribed to The Lunduke Journal… for life. (This includes full access to the community Forum.)

If even 1% of the new free subscribers who have joined in the last month take advantage of this… The Lunduke Journal will be fully funded through the end of this year. And then some.

Let’s make it happen. Scroll down. Pick which ever subscription type works best for you. Then high-five yourself for making Big Tech grumpy.

Just be sure to do it by the end of the day on Friday, May 9th. The prices all go back to normal after that.

50% Off Yearly or Monthly Subscription:

50% off a Yearly or Monthly subscription to The Lunduke Journal are available via both Locals and Substack. (This includes full access to the community Forum.)

That means $3 / Month. Or $27 / Year (which works out to $2.25 / Month).

Via Lunduke.Locals.com:

Via Lunduke.Substack.com:

The Famous Lifetime Subscription:

The "World Famous Lunduke Journal Lifetime Subscription" is exactly what it sounds like. Pay once and get full access to The Lunduke Journal. For life.

And now, through Friday, May 9th… you can snag one at a crazy discount. Normally these are $200… but you can grab one for $100. (You can also pay more if you’d like to donate a little extra.)

The Lifetime Subscription can be obtained via Locals, Substack, or using Bitcoin. All three options work great and are super easy. Scroll down and choose your option.

How to get a Lifetime Subscription via Locals:

  1. Go to Lunduke.Locals.com/support.

  2. Select "Give Once".

  3. Enter "100" (or more) into the amount field.

  4. After checking out, Lunduke will toss you an email once your account is set to full lifetime status. (This usually happens within a few hours.)

How to get a Lifetime Subscription via Substack:

  1. Go to Lunduke.Substack.com/subscribe.

  2. Select the “Lifetime Subscription” option.

  3. After checking out, Lunduke will toss you an email once your account is set to full lifetime status. (This usually happens within a few hours.)

If you would also like full, Lifetime access to Lunduke.Locals.com (which is included):

  1. Make a free account on Lunduke.Locals.com.

  2. Email “bryan at lunduke.com” with the email address you use on both Substack and Locals (can be different email addresses).

  3. Lunduke will toss you an email once your account is set to full lifetime status on Locals.

How to get a Lifetime Subscription with Bitcoin:

You can also obtain a Lifetime Subscription via Bitcoin.

bc1qyjakve8fywm8pz2v99v57yhjj0vzr2vjze6fcq

  • Email "bryan at lunduke.com" with the following information: What time you made the transaction, how much was sent (in Bitcoin), and the email address you use (or plan to use) on Locals.com or Substack.com.

50% Off DRM-Free, MP4 Downloads:

Want to be able to download every show The Lunduke Journal releases (and watch them on whatever device you like)? Yeah. You can do that. For 50% off.

Note: This DRM-Free download option does not include access to the Forum. This option is strictly for downloading the episodes.

Make a One Time Donation

Subscription not enough (or not your thing)? Want to toss in a one-time donation to The Lunduke Journal? There’s a few great options!

Via BitCoin:

Send any amount of BTC to the following address:

bc1qyjakve8fywm8pz2v99v57yhjj0vzr2vjze6fcq

  • Email "bryan at lunduke.com" with to let us know it was you! You can choose to keep your donation anonymous if you prefer. (Either way, all BTC donations get included in the matching deal.)

Via Locals:

  1. Go to Lunduke.Locals.com/support.

  2. Click “GIVE ONCE”.

  3. Enter any amount you like.

You Make This Possible

A huge thank you to all of the subscribers who have made The Lunduke Journal possible. Because of you, we have been able to do true Tech Journalism — to tell the stories that no other Tech News outlet has the cajones to touch.

And to all of you new Lunduke Journal subscribers: Welcome to the last bastion of truly independent, Big-Tech-Free, ad-free, non-Woke Tech Journalism.

-Lunduke

Read full Article
Lunduke Interviewed by Side Scrollers

Yesterday I joined the Side Scrollers show for an hour-long interview.

We covered the Adobe Copyright fight, PewDiePie and Linux, Pokemon Go and the CIA, and how The Lunduke Journal came to be. Definitely worth a watch. I join the show around the 56 minute mark.

 

Next Monday (May 12th), I’ll be a guest on Citizen Podcast with Dan Hollaway.

Critically Important Reminder: The Lunduke Journal refuses to take any funding from Big Tech. The coverage from The Lunduke Journal is only possible because of you.

And with efforts to silence The Lunduke Journal ramping up (including fraudulent copyright take-downs on YouTube), your support is needed more than ever before. If you haven’t already become a subscriber… there’s a lot of options.

All of them make a huge difference:

Without your support, so many stories about Big Tech and Woke Tech would never get told.

Seriously. Now’s the time to support this work, if you are able.

And a huge thank you to each and every one of you. You are making the Tech World a better place.

-Lunduke

Read full Article
Adobe silences Lunduke, "GNOME is Antifa", & Linux Leftists v. PewDiePie
The Lunduke Journal coverage for the week ending May 4th, 2025.

This has been one heck of a weird week — both for Open Source in general, and The Lunduke Journal in particular.

From GNOME contributors declaring that “GNOME is Antifa” to Open Source project leaders declaring that they intend to block PewDiePie fans from using Linux — because PewDiePie fans are, according to Open Source Leftists, “fascists”. Just plain weird.

And, of course, the saga of Adobe working to silence The Lunduke Journal continues to march forward.

As usual, most of these stories were not only broken by The Lunduke Journal… but most Tech News outlets have refused to cover them at all.

Highlights from the last week (ending Sunday, May 4th, 2025):

Those links are all to X — but you can also find all of these shows on every other platform where The Lunduke Journal is available (including Rumble, Podcast, YouTube, and the rest).

Reminder: The Lunduke Journal refuses to take any funding from Big Tech. This type of reporting is only possible through the support of all of you. There are a number of ways you can help out — and, big or small, every option goes directly towards funding this work.

Without your support, so many stories about Big Tech and Woke Tech would never get told.

Seriously. You make The Lunduke Journal possible.

Thank you.

-Lunduke

Read full Article
See More
Available on mobile and TV devices
google store google store app store app store
google store google store app tv store app tv store amazon store amazon store roku store roku store
Powered by Locals