Ugh, apparently yesterday a bot visited my Forgejo instance and queried everything, which caused Forgejo to create repo archives for everything. Git on the instance is 2.1 GB in size, but the repo archive filled up everything and is 120 GB. I really didn’t expect such a spike.

That meant that it filled up the whole hard drive and the server and all the services and websites on it went down while I was sleeping.

Luckily it seems that just deleting that directory fixes the problem temporarily. I also disabled the possibility of downloading archived from the UI but I’m not sure if this will prevent bots from generating those archives again. I also can’t just make the directory read only because it uses it for other things like mirroring, etc too.

For small instances like mine those archives are quite a headache.

  • Possibly linux@lemmy.zip
    link
    fedilink
    English
    arrow-up
    9
    ·
    1 day ago

    You should limit the amount of storage available to a single service.

    Also, set up Anubis or restrict access

      • Foster Hangdaan@lemmy.hangdaan.com
        link
        fedilink
        English
        arrow-up
        2
        ·
        edit-2
        22 hours ago

        If you have a Linux server, you can try partitioning your drive using LVM. You can prevent services from consuming all disk space by giving each one their own logical volume.

        • Jeena@piefed.jeena.netOP
          link
          fedilink
          English
          arrow-up
          2
          ·
          22 hours ago

          I already have LVM but I was using it to combine drives. But it’s not a bad idea, if I can’t do it with Docker, at least that would be a different solution.