this post was submitted on 12 Nov 2024
768 points (91.4% liked)

linuxmemes

21355 readers
1297 users here now

Hint: :q!


Sister communities:


Community rules (click to expand)

1. Follow the site-wide rules

2. Be civil
  • Understand the difference between a joke and an insult.
  • Do not harrass or attack members of the community for any reason.
  • Leave remarks of "peasantry" to the PCMR community. If you dislike an OS/service/application, attack the thing you dislike, not the individuals who use it. Some people may not have a choice.
  • Bigotry will not be tolerated.
  • These rules are somewhat loosened when the subject is a public figure. Still, do not attack their person or incite harrassment.
  • 3. Post Linux-related content
  • Including Unix and BSD.
  • Non-Linux content is acceptable as long as it makes a reference to Linux. For example, the poorly made mockery of sudo in Windows.
  • No porn. Even if you watch it on a Linux machine.
  • 4. No recent reposts
  • Everybody uses Arch btw, can't quit Vim, and wants to interject for a moment. You can stop now.
  •  

    Please report posts and comments that break these rules!


    Important: never execute code or follow advice that you don't understand or can't verify, especially here. The word of the day is credibility. This is a meme community -- even the most helpful comments might just be shitposts that can damage your system. Be aware, be smart, don't fork-bomb your computer.

    founded 1 year ago
    MODERATORS
     
    you are viewing a single comment's thread
    view the rest of the comments
    [–] [email protected] 2 points 1 week ago (2 children)

    My filesystem is btrfs and I've got timeshift setup, how hard will this fuck me, if at all? Is there anyway I can be fucked harder? (Asking for a friend)

    [–] [email protected] 1 points 22 minutes ago

    WARNING:

    Don't ever do this on a current bare metal system!
    Even if you have everything backed up, plan on re-installing anyway, and just want to see what happens.

    On a modern EFI system, recursively deleting everything (including the EFI path) has a chance of permanently hard-bricking your computer!
    https://github.com/systemd/systemd/issues/2402

    [–] [email protected] 4 points 1 week ago (2 children)

    Depends, are you backing up to another partition or drive?

    If not, you're pretty fucked.

    [–] [email protected] 1 points 1 week ago
    [–] [email protected] 1 points 1 week ago* (last edited 1 week ago)

    Aren’t snapshots in btrfs above root?

    Edit: they are in “subvolumes”

    Source: ChatGPT

    On a Btrfs filesystem, running rm -rf /* will attempt to delete everything in the root directory, which includes all files and directories accessible to your permissions. However, Btrfs snapshots are designed to be resistant to regular file deletion commands. Here’s what happens:

    1. Snapshots remain intact: rm -rf /* doesn’t automatically delete snapshots because snapshots are stored in special subvolumes. By default, this command won’t affect subvolumes that are not mounted within the filesystem you’re deleting from.

    2. You would need specific commands to delete snapshots: To delete snapshots on Btrfs, you would typically use a command like btrfs subvolume delete <snapshot> for each snapshot individually, as snapshots are managed by the filesystem and not treated as standard directories.

    3. The data inside the snapshots is preserved: Even if files in the root filesystem are deleted, any data captured in snapshots remains, as snapshots are essentially read-only copies at a certain point in time.

    Important Note: If the snapshots are mounted and accessible in the directory tree where rm -rf /* is run, you could accidentally delete them if the command traverses into the snapshots’ directories. To protect snapshots, administrators often mount them in isolated directories (e.g., /snapshots) or keep them unmounted until explicitly needed.

    In summary, unless you run specific deletion commands for Btrfs subvolumes, snapshots should remain unaffected by rm -rf /* due to the unique way Btrfs manages snapshots.