Cleanup Redmine users

· 1 min read

Startup MySQL tool

    # mysql -u root -p redmine

Maybe first use below queries with SELECT to see what matches there are,
before running with DELETE.
These will show records with state register from 7 days or older.

    DELETE FROM tokens WHERE action='register' and created_on < now() - INTERVAL 7 DAY;

    DELETE FROM users WHERE status=2 and created_on < now() - INTERVAL 7 DAY;

    DELETE FROM tokens WHERE action='register';
    DELETE FROM users WHERE status=2;