Skip to content
This repository has been archived by the owner on Apr 26, 2024. It is now read-only.
supagu edited this page Apr 19, 2018 · 32 revisions

What servers are my server talking to?

Run this sql query on your db:

SELECT * FROM destinations;

What servers are currently participating in this room?

Run this sql query on your db:

SELECT DISTINCT split_part(state_key, ':', 2)
    FROM current_state_events AS c
    INNER JOIN room_memberships AS m USING (room_id, event_id)
    WHERE room_id = '!cURbafjkfsMDVwdRDQ:matrix.org' AND membership = 'join';

What users are registered on my server?

SELECT NAME from users;

Manually resetting passwords:

See https://github.com/matrix-org/synapse/blob/master/README.rst#password-reset

I have a problem with my server. Can I just delete my database and start again?

Deleting your database is unlikely to make anything better.

It's easy to make the mistake of thinking that you can start again from a clean slate by dropping your database, but things don't work like that in a federated network: lots of other servers have information about your server.

For example: other servers might think that you are in a room, your server will think that you are not, and you'll probably be unable to interact with that room in a sensible way ever again.

In general, there are better solutions to any problem than dropping the database. Come and seek help in https://matrix.to/#/#matrix:matrix.org or https://matrix.to/#/#matrix-dev:matrix.org.

There are two exceptions when it might be sensible to delete your database and start again:

  • You have never joined any rooms which are federated with other servers. For instance, a local deployment which the outside world can't talk to.
  • You are changing the server_name in the homeserver configuration. In effect this makes your server a completely new one from the point of view of the network, so in this case it makes sense to start with a clean database. (In both cases you probably also want to clear out the media_store.)

I've stuffed up access to my room, how can I delete it to free up the alias?

Using the following curl command:

curl -H 'Authorization: Bearer \<access-token\>' -X DELETE https://matrix.org/_matrix/client/r0/directory/room/\<room-alias\>

access-token - can be obtained in riot by looking in the riot settings, down the bottom is: Access Token:<click to reveal>