What is the most destroying command you can type in the Linux terminal?

oriond@lemmy.ml to Asklemmy@lemmy.ml – 155 points –
136

You are viewing a single comment

That 'amp;' does not belong in there, it's probably either a copy-paste error or a Lemmy-error.

What this does (or would do it it were done correctly) is define a function called ":" (the colon symbol) which recursively calls itself twice, piping the output of one instance to the input of the other, then forks the resulting mess to the background. After defining that fork bomb of a function, it is immediately called once.

It's a very old trick that existed even on some of the ancient Unix systems that predated Linux. I think there's some way of defending against using cgroups, but I don't know how from the top of my head.

I think however you're accessing Lemmy is rendering it wrong. I see the usual function.

2 more...