GNU social JP
  • FAQ
  • Login
GNU social JPは日本のGNU socialサーバーです。
Usage/ToS/admin/test/Pleroma FE
  • Public

    • Public
    • Network
    • Groups
    • Featured
    • Popular
    • People

Conversation

Notices

  1. Embed this notice
    fgaz (fgaz@cdrom.tokyo)'s status on Thursday, 21-Sep-2023 20:08:29 JST fgaz fgaz

    I somehow managed to accidentally delete /dev/null and it’s unbelievable how much stuff relies on writing data to nothing.

    • SSH just doesn’t start
    • same with tmux
    • bash completion doesn’t work and spams errors about _upvars
    • I can’t open GUI programs unless I launch them from a terminal that was opened when /dev/null was still there
    • Firefox prints assertion failures, then the error handler segfaults (!!)
    In conversation Thursday, 21-Sep-2023 20:08:29 JST from cdrom.tokyo permalink
    • Haelwenn /элвэн/ :triskell: likes this.
    • Embed this notice
      your new favourite fungus (duponin@udongein.xyz)'s status on Thursday, 21-Sep-2023 20:08:17 JST your new favourite fungus your new favourite fungus
      in reply to
      @fgaz how
      have
      you
      deleted /dev/null

      :wat: :what_cirno: :what:
      In conversation Thursday, 21-Sep-2023 20:08:17 JST permalink
      Sexy Moon likes this.
    • Embed this notice
      Haelwenn /элвэн/ :triskell: (lanodan@queer.hacktivis.me)'s status on Thursday, 21-Sep-2023 21:17:53 JST Haelwenn /элвэн/ :triskell: Haelwenn /элвэн/ :triskell:
      in reply to
      • your new favourite fungus
      @duponin @fgaz Well /dev/null is a regular file, because the only actual virtual filesystem linux has is /proc
      In conversation Thursday, 21-Sep-2023 21:17:53 JST permalink
    • Embed this notice
      fgaz (fgaz@cdrom.tokyo)'s status on Thursday, 21-Sep-2023 21:18:44 JST fgaz fgaz
      in reply to

      The answer appears to be 0. They just like to know that it’s there

      In conversation Thursday, 21-Sep-2023 21:18:44 JST permalink
      Haelwenn /элвэн/ :triskell: likes this.
    • Embed this notice
      fgaz (fgaz@cdrom.tokyo)'s status on Thursday, 21-Sep-2023 21:18:45 JST fgaz fgaz
      in reply to

      Just how much data gets produced and the immediately thrown away into /dev/null at any given moment?

      Hmm actually I can easily find that out…

      In conversation Thursday, 21-Sep-2023 21:18:45 JST permalink
    • Embed this notice
      fgaz (fgaz@cdrom.tokyo)'s status on Thursday, 21-Sep-2023 21:18:46 JST fgaz fgaz
      in reply to

      Like… I know it’s required by POSIX, and it’s helpful in scripts, but how is it possible that standalone programs rely on it instead of just… not producing that data.

      Just how much data gets produced and the immediately thrown away into /dev/null at any given moment?

      In conversation Thursday, 21-Sep-2023 21:18:46 JST permalink
    • Embed this notice
      fgaz (fgaz@cdrom.tokyo)'s status on Thursday, 21-Sep-2023 21:19:39 JST fgaz fgaz
      in reply to

      But wait, that was a regular file! A file that can be overwritten (and reset to 0 bytes) by multiple processes, so it could be that I just didn’t see the data in time.

      So I tried to make it a FIFO… forgetting that FIFOs are blocking until a reader is set up. My shell instantly locked up, and so did the most random parts of the system

      In conversation Thursday, 21-Sep-2023 21:19:39 JST permalink

      Attachments

      1. No result found on File_thumbnail lookup.
        http://time.So/
      Haelwenn /элвэн/ :triskell: likes this.
    • Embed this notice
      Haelwenn /элвэн/ :triskell: (lanodan@queer.hacktivis.me)'s status on Friday, 22-Sep-2023 02:54:54 JST Haelwenn /элвэн/ :triskell: Haelwenn /элвэн/ :triskell:
      in reply to
      • your new favourite fungus
      • Attie Grande
      @attie @fgaz @duponin Fine, there's a bit more than just procfs.
      But the point is: devtmpfs just allows whatever.
      In conversation Friday, 22-Sep-2023 02:54:54 JST permalink
    • Embed this notice
      Attie Grande (attie@chaos.social)'s status on Friday, 22-Sep-2023 02:54:56 JST Attie Grande Attie Grande
      in reply to
      • Haelwenn /элвэн/ :triskell:
      • your new favourite fungus

      @lanodan @fgaz @duponin if by "regular file" you mean "character special", then sure... and what about sysfs, securityfs, debugfs, etc... for pseudo-filesystems?

      "Virtual File System", or VFS is different again?
      https://docs.kernel.org/filesystems/vfs.html

      In conversation Friday, 22-Sep-2023 02:54:56 JST permalink

      Attachments

      1. No result found on File_thumbnail lookup.
        Overview of the Linux Virtual File System — The Linux Kernel documentation
    • Embed this notice
      Attie Grande (attie@chaos.social)'s status on Friday, 22-Sep-2023 03:03:15 JST Attie Grande Attie Grande
      in reply to
      • Haelwenn /элвэн/ :triskell:

      @lanodan ah, thought I was having a moment there 😂🙈

      In conversation Friday, 22-Sep-2023 03:03:15 JST permalink
      Haelwenn /элвэн/ :triskell: likes this.
    • Embed this notice
      Haelwenn /элвэн/ :triskell: (lanodan@queer.hacktivis.me)'s status on Friday, 22-Sep-2023 04:34:45 JST Haelwenn /элвэн/ :triskell: Haelwenn /элвэн/ :triskell:
      in reply to
      • a kilo of saucepans (rakslice)
      @rakslice I'm aware, this is just pedantry. We all know I'm not saying /dev/null is a regular file as in non-special.

      And given repliers here love their kind of correctness, here's mine: /dev/null is *any* file, due to /dev being on a regular filesystem (tmpfs or on-disk) and not a virtual filesystem (like procfs).
      And that's a mouthful, yet I'm sure it'll trigger your kind.
      In conversation Friday, 22-Sep-2023 04:34:45 JST permalink
    • Embed this notice
      a kilo of saucepans (rakslice) (rakslice@mastodon.social)'s status on Friday, 22-Sep-2023 04:34:46 JST a kilo of saucepans (rakslice) a kilo of saucepans (rakslice)
      in reply to
      • Haelwenn /элвэн/ :triskell:
      • your new favourite fungus

      @lanodan @fgaz @duponin that's not what "regular file" means on Linux (or any Unix)

      In conversation Friday, 22-Sep-2023 04:34:46 JST permalink
    • Embed this notice
      a kilo of saucepans (rakslice) (rakslice@mastodon.social)'s status on Friday, 22-Sep-2023 04:57:04 JST a kilo of saucepans (rakslice) a kilo of saucepans (rakslice)
      in reply to
      • Haelwenn /элвэн/ :triskell:

      @lanodan just like "we all know" nobody was asking how it's possible to delete /dev/null

      In conversation Friday, 22-Sep-2023 04:57:04 JST permalink
    • Embed this notice
      Haelwenn /элвэн/ :triskell: (lanodan@queer.hacktivis.me)'s status on Friday, 22-Sep-2023 04:57:04 JST Haelwenn /элвэн/ :triskell: Haelwenn /элвэн/ :triskell:
      in reply to
      • a kilo of saucepans (rakslice)
      @rakslice Literally second post in the thread: https://udongein.xyz/objects/a5ffd7f9-44d5-4c12-8ce9-2a92cb64a743
      In conversation Friday, 22-Sep-2023 04:57:04 JST permalink

      Attachments


    • Embed this notice
      jordan (jordan@sometimes.social)'s status on Friday, 22-Sep-2023 04:57:57 JST jordan jordan
      in reply to

      @fgaz At a job long in the past, I had a coworker who was very enamored of a particular do-everything Python library which I will not name at this time. This library included some built-in logging facilities, but he didn't actually need the log for the thing he was making, so he set it to log to `/dev/null`.

      It turns out that this library had automatic log rotation built in. The way it worked was that it kept track of the number of bytes written to a log, and when it crossed a certain threshold, it would rename the file it was logging to, and open a new log file.

      Unfortunately, the thing my coworker built ran as `root`. It started up and ran fine for a while, merrily logging to `/dev/null` as instructed. After a while, though, it noticed "oh hey I've written more than a megabyte of logs, time to rotate the log file" - it then renamed `/dev/null` to `/dev/null.YYYY-mm-dd.HH:MM:SS` and created a new `/dev/null` that was just a regular text file. From that point onward, anything that got written to `/dev/null` actually got written to disk. Chaos ensued.

      That one took a whole day to figure out...

      In conversation Friday, 22-Sep-2023 04:57:57 JST permalink
      Haelwenn /элвэн/ :triskell: likes this.

Feeds

  • Activity Streams
  • RSS 2.0
  • Atom
  • Help
  • About
  • FAQ
  • TOS
  • Privacy
  • Source
  • Version
  • Contact

GNU social JP is a social network, courtesy of GNU social JP管理人. It runs on GNU social, version 2.0.2-dev, available under the GNU Affero General Public License.

Creative Commons Attribution 3.0 All GNU social JP content and data are available under the Creative Commons Attribution 3.0 license.