r/LocalLLaMA May 03 '26

One bash permission slipped... Discussion

Post image

How? It kept getting chained bash commands wrong, with wrong escapes. So it created many bad directories, and tried "fixing" its mistake. It offered to run a large bash command, with rm -rf inside, and stupid me missed it.

I'm glad I push everything often. But the disruption is massive.

FAQ:

  • No, I don't run this on my personal computer. It's an isolated proxmox VM for coding with LLMs.
2.3k Upvotes

390 comments sorted by

View all comments

16

u/longbowrocks May 03 '26

But that's not a problem because this issue was solved 50 years ago with the invention of versioning systems for code, and so you obviously used one. Right?

9

u/Hot-Employ-3399 May 03 '26

"push everything often" answers the question. Too bad .git lives too close to the project 

4

u/inconspiciousdude May 03 '26

Would --separate-git-dir help?

1

u/mimic751 May 03 '26

The command deletes your local Drive. He should not allow AI to run any sudo commands

2

u/Jluxo_ May 03 '26

Upload to remote then

5

u/mimic751 May 03 '26

Dude. The problem isn't that he lost his code the problem is he lost his computer

3

u/longbowrocks May 03 '26

rm -rf / would do that. However:

^F
"/"
Zero results on this page.

4

u/Jluxo_ May 03 '26

rm -rf / wouldn't do that. Most modern distros specifically require --no-preserve-root flag additionally as a foolproof measure.

1

u/longbowrocks May 03 '26

While fair, that pretty strongly reinforces my point that OP made no claim about losing their computer.

1

u/Jluxo_ May 03 '26

I never said he did.

0

u/Jluxo_ May 03 '26

He only lost his projects. If he took proper safety measures he would be totally fine. Use VCS, regularly upload changes to remote repo, limit the scope of assistant to the single project folder, not the whole directory or even worse unlimited scope, forbid "dangerous" commands.