Hello everyone!

Recently my instance have become a target of community subscribers bots, which subscribed my instance to hundreds of communities. I’ve deleted all those bot accounts manually and enabled captcha and application for registration.

Then I stopped all containers except for lemmy-postgres and ran a following query to purge all empty communities

delete from community where id in (select community_id from community_aggregates ca where ca.subscribers = 0 for update skip locked);

At first I thought that it worked because all communities and related posts have disappeared, but when I started all the other containers, lemmy for some reason again started adding back those communities with 0 subscribers to my database.

What am I doing wrong? How do I purge them? Also, I would appreciate on any guide how to remove all dangling images (which don’t have any reference from db) in pict-rs.

Thanks!

  • BlackEco@lemmy.blackeco.com
    link
    fedilink
    English
    arrow-up
    1
    ·
    1 year ago

    My guess is remote instances still consider the bots to be subscribed and thus kept sending new posts and comments. I don’t know how to fix this situation though.