I have my self-hosted instance now, but there are some issues / open questions:

  • When going to my admin-page, I see tons of banned users I never banned myself. Who banned them, why do I need to know about it?
  • Concerned I might have left my instance too open and they might have used my instance for spamming, I tried to look for all users on my instance. By directly accessing postgres:lemmy and checking the user-ids, I saw it’s just the expected ones, however, I wasn’t able to find the usernames, neither easily in postgres nor on the lemmy admin page. Any ideas?
  • I see timeouts when accessing my lemmy instance, however, the host doesn’t show high cpu-, memory- or network-load and I don’t see anything immediately suspicious in the logs. According to iftop, there aren’t insane amounts of connections, either. Sometimes it seems to help temporarily to restart my apache server. Any ideas, what to look out for?
  • Senicar@social.cyb3r.dog
    link
    fedilink
    English
    arrow-up
    1
    ·
    1 year ago

    I’ve been running a private instance for about a week and would like to know some of these too. My understanding is the banned users are users that other instances ban, and that information also federates to you. For the other two questions, afaik dumping the db is the only way to check users? And I’m not sure about the timeouts. I find it helps to periodically restart the lemmy service(s) on a cron.

    • twitterfluechtling@lemmy.pathoris.deOP
      link
      fedilink
      English
      arrow-up
      1
      ·
      1 year ago

      I found out how to get the list of users registered on my instance. Assuming docker-compose based installation, to access the database via CLI:

      cd LEMMY_FOLDER
      docker-compose exec postgres bash
      psql -d lemmy -U lemmy
      select name from person where local=true;
      

      The db also contains all users known from federated instances; you can look for one e.g. via

      select name,actor_id,instance_id from person where actor_id='https://social.cyb3r.dog/u/senicar';
        name   |              actor_id              | instance_id 
      ---------+------------------------------------+-------------
       senicar | https://social.cyb3r.dog/u/senicar |         398
      (1 row)
      

      and look for other users on that same instance:

      select name,actor_id,instance_id from person where instance_id=398;
      

      There are plenty of other queries you can do on the db, e.g. to figure out which instances have most banned users, which instances are presumably private (have less than 5 users known to you), max instance_id to see to how many instances you are connected, etc.