🫩🫩🫩🫩

    • zerofk@lemmy.zip
      link
      fedilink
      arrow-up
      10
      ·
      5 hours ago

      I once deleted /dev/null Do not recommend. You’d be surprised how much of the system needs it.

      • JackbyDev@programming.dev
        link
        fedilink
        English
        arrow-up
        1
        ·
        31 minutes ago

        How? I could’ve sworn it wasn’t even a “real” file. I thought the file system just had special rules for interacting with that name.

      • Dremor@lemmy.world
        link
        fedilink
        arrow-up
        8
        ·
        5 hours ago

        I once deleted /dev/urandom. I didn’t want uncertainty in my life.

        Well, I was on for a surprise.

        • CheesyFox@lemmy.sdf.org
          link
          fedilink
          arrow-up
          1
          ·
          edit-2
          2 hours ago

          well, i guess your pc got into a pretty certain state of being, at least for that evening, so technically it worked:)

  • Inucune@lemmy.world
    link
    fedilink
    arrow-up
    5
    ·
    6 hours ago

    Process explorer, threads and handles tool, search the file name.

    Kill the process or at least you know who now.

  • LoafedBurrito@lemmy.dbzer0.com
    link
    fedilink
    arrow-up
    5
    ·
    6 hours ago

    “Hey Microsoft, i want to safely remove this hard drive so i don’t corrupt my data”

    “Nope, it’s being used by another program”

    “I shut down every program, nothing is open, please eject my Hard drive”

    “Nope, It’s being used by another program”

    **Proceed to just yank the cord out of the computer and flick off the screen.

  • Johanno@feddit.org
    link
    fedilink
    arrow-up
    21
    ·
    10 hours ago

    Actually on windows 7 I found out how to get which process is locking one file.

    You open the resources manager (task manager has a link to it)

    Inside you can see how much each process uses on cpu, network and stuff.

    And there is a tab where all used files for each process is listed. You can search for specific files.

    • Landless2029@lemmy.world
      link
      fedilink
      arrow-up
      31
      ·
      9 hours ago

      Yeah there’s a Microsoft sysinternals utility where you can drag a file into to fetch that info for you.

      Makes zero sense there isn’t a >Details in the error notification that tells you the damned process in Windows.

      • JackbyDev@programming.dev
        link
        fedilink
        English
        arrow-up
        1
        ·
        29 minutes ago

        Right? I get that it’s “alarming” to users to see weird stuff, but just hide it under a little expandable thing.

      • Piafraus@lemmy.world
        link
        fedilink
        arrow-up
        3
        ·
        7 hours ago

        Not only that, but you can actually search all active processes to see which handles they keep references to. Just search the name of your file and it will show you the processes which use it

  • Seefra 1@lemmy.zip
    link
    fedilink
    arrow-up
    162
    arrow-down
    1
    ·
    16 hours ago

    “Hey Linux, can you just delete this file please?”

    “Sure thing bud, a program is using it, it’s ok, I will just unlink the inode anyway, the program can still access it until it closes the file”

    • xthexder@l.sw0.com
      link
      fedilink
      arrow-up
      60
      arrow-down
      3
      ·
      15 hours ago

      This is honestly one of my favorite features of the linux filesystem. As a dev it makes things like replacing and hot-reloading plugins way easier.

      It turns out you can kind of get the same functionality on Windows if you rename the open file and place the new one with the original name, but it’s a bit of a hack.

      • mnemonicmonkeys@sh.itjust.works
        link
        fedilink
        English
        arrow-up
        5
        ·
        6 hours ago

        It turns out you can kind of get the same functionality on Windows if you rename the open file and place the new one with the original name, but it’s a bit of a hack.

        Only if you don’t have OneDrive working. In that case, you have to wait for it to sync or it won’t go through.

        Anytime I have an issue at work where I can’t change or delete a file, it’s a 50/50 split between Excel and OneDrive being the cause

        • mcv@lemmy.zip
          link
          fedilink
          arrow-up
          15
          ·
          14 hours ago

          Yeah, super annoying. In Linux you can rename or move it and the app using it doesn’t care.

          Although having the option of listing the app using a file so I can kill the app would also be really nice to have. I’m sure Linux has something for that too, but I don’t know what it is.

        • REDACTED@infosec.pub
          link
          fedilink
          English
          arrow-up
          6
          ·
          14 hours ago

          That’s actually a thing, but I’m not entirely sure in which cases. Probably only for services and not apps, but I’ve done that myself where deleting a file was impossible, but renaming it and deleting it worked.

        • xthexder@l.sw0.com
          link
          fedilink
          arrow-up
          3
          ·
          14 hours ago

          Maybe it’s only possible in certain cases, but I can tell you for certain it’s possible with running exe’s and loaded dll’s. I have a CMake step on Windows that does this rename hack so my builds don’t fail if I still have the app running.

  • kuneho@lemmy.world
    link
    fedilink
    arrow-up
    55
    ·
    edit-2
    14 hours ago

    back in the XP days, I used a software called “Unlocker” just for this problem. It probably still exists, I don’t know, because since Windows 7, the easiest way to find out what process locks a file is to open Resource Monitor (Start search: resmon) and on the CPU tab, using the “Associated handles” list, you can search for the file name and see the process in question (and kill it).

    So yeah, Resource Monitor is a useful tool on Windows.

    • rumba@lemmy.zip
      link
      fedilink
      English
      arrow-up
      1
      ·
      6 hours ago

      The bugs and horribly slow hardware that caused the locks in NT/XP have slowly disappeared, by win 10, I rarely had any files I couldn’t delete if I, worst case, made explorer reload. It used to happent o be every other day in the late 90s

      • BilSabab@lemmy.world
        link
        fedilink
        arrow-up
        20
        ·
        13 hours ago

        not including PowerToys inside basic package is a fucking choice. Win11 is literally unusable without it in many aspects.

        • TeddE@lemmy.world
          link
          fedilink
          arrow-up
          6
          ·
          9 hours ago

          I suspect it’s in line with big tech policies to coddle end users instead of educating or trusting them. I assert (particularly since the introduction of the iPhone in 2007) that learned helplessness is built into the game plan.

          • MonkeMischief@lemmy.today
            link
            fedilink
            arrow-up
            4
            ·
            6 hours ago

            100%! Like with major setups and upgrades now just being throbbing circles and a pulsing blue light with the creepy “We’re doing stuff on your behalf behind this screen.” messaging.

            I say computers (and the Internet) are for anybody, but not everybody. Learning to use a tool will always be a requirement of useful tools.

            There used to be a time when most people using a computer implicitly understood how files and folders worked, for instance. But now even such a simple abstraction is considered advanced esoteric lost arcana.

            I’m deeply saddened by how the tech industry has deliberately pushed understanding backwards so hard in order to foster more obedient consumers.

            It’s actually wild to see how many people who were at the very least, young adults during the computer boom of the late 80’s/early 90’s, can’t handle anything without a touch screen and don’t comprehend email.

            Ignorance is sold as the future.

          • BilSabab@lemmy.world
            link
            fedilink
            arrow-up
            4
            ·
            9 hours ago

            My dad used to say Apple is evil exactly because of that - they make stuff for people who want fancy shit but have little to no interest in actual tech.

      • Redex@lemmy.world
        link
        fedilink
        arrow-up
        9
        ·
        13 hours ago

        I feel like it’s a testing ground for new features for them, but not sure why some aren’t yet integrated. Best guess: the PowerToys team has less red tape and checks to go through than the Windows team to allow for faster iteration, but that means that integrating the features wouldn’t be just the click of a button since they’d have to adapt it to fit the Windows style. But this is just a wild guess.

        • some_kind_of_guy@lemmy.world
          link
          fedilink
          arrow-up
          5
          ·
          9 hours ago

          I think you’re right on the money. There seems to be a component of enticing power users to stick with Windows as well. The app is still “in beta” despite the first release being in 1996 (!). I had to look that up, because I’d only heard about it in the early windows 10 days.

          • Deebster@infosec.pub
            link
            fedilink
            arrow-up
            3
            ·
            7 hours ago

            The first version of PowerToys was released for Windows 95 on 17 November, 1996 as a download on Microsoft’s FTP server at the time.

            Well wadaya knows?

            I like that it wasn’t a proper installed thing, just a bunch of executables in a zip file.

      • kuneho@lemmy.world
        link
        fedilink
        arrow-up
        10
        ·
        edit-2
        14 hours ago

        Why would they not include these into base kit Windows is beyond me.

        Some of them felt a bit buggy when I last time used Windows, maybe they aren’t fully ready to ship (like Samsung’s Good Lock apps?). And most features didn’t do quite what I imagined it to do, but that’s probably a “me problem”.

    • floquant@lemmy.dbzer0.com
      link
      fedilink
      arrow-up
      27
      ·
      15 hours ago

      Powertoys seems to be the only thing keeping windows somewhat usable, I have no idea why they don’t include it in the build.

    • Sundray@lemmus.org
      link
      fedilink
      English
      arrow-up
      99
      ·
      19 hours ago

      “Time to see who’s stopping me from deleting this file… svchost??? Goddamn it!”

      • fibojoly@sh.itjust.works
        link
        fedilink
        arrow-up
        1
        ·
        6 hours ago

        I’m in this picture and I don’t like it. I was trying to diagnose a prod server crashing this very Wednesday and seeing the lines of svchost.exe is so fucking maddening… I’m glad ProcessExplorer was there to give some useful fucking info, at least.

      • Anivia@feddit.org
        link
        fedilink
        arrow-up
        7
        ·
        13 hours ago

        Well, it could be an executable disguising itself as svchost. Pretty common for malware or video game cheats to name their executables svchost.exe to hide from anti-virus/anticheat

        • boonhet@sopuli.xyz
          link
          fedilink
          arrow-up
          2
          arrow-down
          1
          ·
          13 hours ago

          I used to, all the time

          This was in the XP days so I didn’t know how to figure out which service it was, I was a kid. But some svchost process would manifest as a task to switch to in the alt + tab switcher and made the computer slow and weird. I just killed it. No idea if it was a bug or a virus.

    • Mikina@programming.dev
      link
      fedilink
      arrow-up
      16
      ·
      16 hours ago

      I discovered powertoys only recently, and it’s a pretty cool set of tools. From color picker, tiling window manager to regex file renames or copy/paste tools, it has a lot of QoL features.

      If you have to be on windows, i.e due ro work, I recommend not sleeping on it.

    • affenlehrer@feddit.org
      link
      fedilink
      arrow-up
      4
      ·
      15 hours ago

      The performance view thing that comes with windows also allows searching for file handles but it’s not very user friendly. Also not possible without admin rights if I remember correctly

  • judgyweevil@feddit.it
    link
    fedilink
    arrow-up
    62
    ·
    edit-2
    18 hours ago

    Me: I’ve close the program, now please delete the file

    Windows: ok, give me half an hour, it’s not easy to delete 500 MB

    • killeronthecorner@lemmy.world
      link
      fedilink
      English
      arrow-up
      22
      ·
      15 hours ago

      Here’s an incredibly animated chart of how poorly I’m doing. Note that I seem to throttle the operation every 5 seconds or so.

      Explanation? No, no. Haha. No. We don’t do anything like that.

    • krooklochurm@lemmy.ca
      link
      fedilink
      arrow-up
      3
      arrow-down
      2
      ·
      edit-2
      11 hours ago

      Hey Linux, sudo rm -rf /

      sigh I’m surrounded by idiots.

      “Sure thing boss” you fucking moron.

      • fin@sh.itjust.works
        link
        fedilink
        arrow-up
        2
        ·
        10 hours ago

        I did that once on my Macbook Air a while ago by mistake. The system’s completely fucked and I had to reinstall it.

  • AceFuzzLord@lemmy.zip
    link
    fedilink
    arrow-up
    13
    ·
    14 hours ago

    Same thing whenever I try to unplug a USB, Win10, on my desktop. There have been times where I plugged in one, opened a file, closed it within seconds, did the safely remove thing, and then I get the whole quick song and dance about some program still using it because of how sluggish it is to actually end what’s using it in the background.

    Also, my phone’s keyboard software was bugging out and replaced “song” with “incest” for no discernable and wanted to replace the next word “and” with “rape incest”. Not related, but fuck Gboard and that weird glitch where it’ll replace words with random shit for no reason.

      • mnemonicmonkeys@sh.itjust.works
        link
        fedilink
        English
        arrow-up
        2
        ·
        edit-2
        6 hours ago

        Yeah, dude really needs to atop looking up hentai, or at least start reading more wholesome ones.

        Or get FUTO keyboard and disable autosuggest

        • AceFuzzLord@lemmy.zip
          link
          fedilink
          arrow-up
          1
          ·
          3 hours ago

          The crazy part about that is I don’t look up hentai. Just yiff and even then, I’m a vanilla kinda guy.

          I may occasionally joke about Alabama and incest out loud, but never really type it.

          Also, I would switch to something like FUTO but I have yet to find a FOSS keyboard that can handle Japanese or Chinese.

      • AceFuzzLord@lemmy.zip
        link
        fedilink
        arrow-up
        1
        ·
        3 hours ago

        I have yet to find one that can properly do Chinese and/or Japanese and I’m too dumb to make one. That’s the only thing holding me back.

      • AceFuzzLord@lemmy.zip
        link
        fedilink
        arrow-up
        2
        ·
        14 hours ago

        I cannot remember what it’s done in the past, but I’ve definitely had much more tame occurrences of this. Same with holding the delete key and having the thing think that the first letter of a word doesn’t exist from time to time.

        Probably a couple of minor bugs that g••gle doesn’t care to fix.

  • dan@upvote.au
    link
    fedilink
    arrow-up
    33
    ·
    18 hours ago

    Some Windows apps do handle it properly. For example, if you have an archive open in 7-zip and try to delete it, Windows Explorer should correctly tell you that it’s open in 7-Zip. I’m not sure why it doesn’t work that way for all apps.

    • fibojoly@sh.itjust.works
      link
      fedilink
      arrow-up
      2
      ·
      edit-2
      6 hours ago

      Shout out to my MVP Notepad++ telling the file has been deleted by another process and letting me decide if I want to keep it open anyway. Fantastic feature. I literally could not do my job without its ability to leave log files alone so they can be written to while I’m still browsing them.

    • xthexder@l.sw0.com
      link
      fedilink
      arrow-up
      11
      arrow-down
      1
      ·
      15 hours ago

      Windows doesn’t even tell you if Explorer itself has a folder open… how the hell does 7-Zip do it?

  • finitebanjo@piefed.world
    link
    fedilink
    English
    arrow-up
    67
    arrow-down
    3
    ·
    edit-2
    20 hours ago

    TBF the task manager and those windows explorer dialogues were programed in like 1996 and it’s probably one of the best functioning feature in Windows so changing it too much carries high risks.

    • Deebster@infosec.pub
      link
      fedilink
      arrow-up
      2
      ·
      7 hours ago

      On my Windows 10 laptop, Task Manager virtually freezes the whole system for about four seconds when you switch tabs.

      • finitebanjo@piefed.world
        link
        fedilink
        English
        arrow-up
        0
        ·
        6 hours ago

        Well the only Windows 10 system still receiving support is Windows 10 Enterprise LTSC, afaik, and I have one which does not have that particular problems. Are you properly scheduling updates so that it doesn’t run automatically?

        • Deebster@infosec.pub
          link
          fedilink
          arrow-up
          2
          ·
          5 hours ago

          It’s a pretty old issue (and you can find others complaining online over the years) and my current machine is running Gentoo Linux, so I’m not trying to fix it any more.

    • Cousin Mose@lemmy.hogru.ch
      link
      fedilink
      arrow-up
      53
      arrow-down
      2
      ·
      19 hours ago

      changing it too much carries high risks

      This is such a Windows way of thinking and I can’t really explain it. Why does every other OS constantly change and evolve but Windows is like “can’t touch this code from a quarter century ago?”

      • fibojoly@sh.itjust.works
        link
        fedilink
        arrow-up
        1
        arrow-down
        1
        ·
        6 hours ago

        You ever worked in like a real job? Have you ever seen the amount of legacy code that depends on some other legacy piece of shit which itself depends on…?
        It’s absolutely maddening, being there, diagnosing the issue and absolutely having no way to do anything about it because no time, not allowed, no need if it ain’t broken, our customers rely on this specific version, etc.

        It’s not a Windows way of thinking, it’s what every single one of the businesses I’ve worked with for the last twenty or so years think like. And changing shit is incredibly expensive.

        • Cousin Mose@lemmy.hogru.ch
          link
          fedilink
          arrow-up
          1
          ·
          1 hour ago

          It just hasn’t been my experience at all as a developer. I’m sorry you’ve been forced to keep legacy code around for the sake of not breaking things.

      • finitebanjo@piefed.world
        link
        fedilink
        English
        arrow-up
        21
        ·
        18 hours ago

        I don’t see the problem with it. Microsoft historically does a great job of making everything worse with updates.

      • Atomic@sh.itjust.works
        link
        fedilink
        arrow-up
        4
        arrow-down
        1
        ·
        13 hours ago

        I dare say, that 90% of all companies in Europe and US, use Windows. And lots of companies relies heavily on software built 20-30 years ago. Microsoft knows this.

        That’s why they are very reluctant to “touch that piece of code from a quarter century ago” because there’s probably a lot of software that would break without it. Software their target audience need.

      • Triumph@fedia.io
        link
        fedilink
        arrow-up
        9
        arrow-down
        1
        ·
        17 hours ago

        Because any time anything changes in Windows, people bitch about it.

      • filcuk@lemmy.zip
        link
        fedilink
        arrow-up
        6
        ·
        edit-2
        12 hours ago

        There is nothing in windows that’s a small tweak.
        Changing anything has implications to a banking business Joe somewhere, who’s program depends on the original feature working as it does, or one of the 16 layers of code is simply tangled in a way such change would require cascade of rewrites.

        I’ve read articles about various developments: working with regex registry*, or just adding a control panel option, and it’s an absolute nightmare.

    • dan@upvote.au
      link
      fedilink
      arrow-up
      3
      arrow-down
      1
      ·
      18 hours ago

      The current UI is very different to the original UI though.

  • ArbitraryValue@sh.itjust.works
    link
    fedilink
    English
    arrow-up
    40
    ·
    19 hours ago

    What gets me is when I’m not allowed to remove an external drive. Deleting a file can be delayed until later but here I am with a physical object that I need to detach from my computer and first I need to play hide and seek with the OS.

    • Quetzalcutlass@lemmy.world
      link
      fedilink
      English
      arrow-up
      28
      ·
      19 hours ago

      If this happens often, you can disable write caching for that drive. It’ll feel slightly slower (since it’s actually operating at the speed of the hardware instead of caching operations in RAM and gradually writing them to disk in the background), but you’ll be able to remove the drive almost instantly.

      • DrMartinu@lemmy.dbzer0.com
        link
        fedilink
        arrow-up
        19
        ·
        18 hours ago

        I used to find it had something to do with the explorer thumbnailer finishing up but sort of not letting go. It would happen if I had pictures or videos on the USB drive, and if I got the error I could go to another folder like my documents, drag a picture into another folder, go look at the pretty new thumbnail, then I could remove the USB drive because the thumbnailer was ‘parked’ back on the C drive. Sounds like I’m making it up but I swear it worked.

      • kattfisk@lemmy.dbzer0.com
        link
        fedilink
        arrow-up
        2
        arrow-down
        1
        ·
        11 hours ago

        Shouldn’t that happen automatically if the drive is identified as removable? And the real solution should be to tell the OS that it’s removable?

        • Quetzalcutlass@lemmy.world
          link
          fedilink
          English
          arrow-up
          1
          ·
          edit-2
          7 hours ago

          I was having terrible performance problems in Windows a while back, and it turned out it had marked every drive as removable, and the write cache was filling up due to an extremely slow external HDD, causing even the internal SSDs to grind to a halt until the buffer was flushed whenever a large amounts of writes were made to the HDD (which was often, since it was used for backups and large Steam games).

    • Cousin Mose@lemmy.hogru.ch
      link
      fedilink
      arrow-up
      18
      ·
      edit-2
      18 hours ago

      And that removable object’s filesystem is probably the most shit, unjournalled filesystem in the world so you’re actually fucked if it becomes corrupted by removing it early.

      • floofloof@lemmy.ca
        link
        fedilink
        arrow-up
        10
        ·
        edit-2
        17 hours ago

        And if you move the drive between operating systems you’re very limited in what filesystems you can use because Windows is very limited in what filesystems it can use. So you can’t just pick a more robust filesystem.

    • affenlehrer@feddit.org
      link
      fedilink
      arrow-up
      2
      ·
      15 hours ago

      You can use this performance view thing that comes with windows to search for file handles and the processes that own them

  • skuzz@discuss.tchncs.de
    link
    fedilink
    arrow-up
    10
    arrow-down
    1
    ·
    16 hours ago

    Mac does the same thing (as others have said) and you can at least sudo lsof and find it, but somehow filesystem access now is worse than Windows 95 era Excel spreadsheet file handles that never worked.

    Here’s what an operating system is peeps: Something that handles files and programs that live on top of it. That’s it.

    How is it none of them can’t do their basic function anymore?