https://www.redmine.org/
https://www.redmine.org/favicon.ico?1679302129
2008-08-13T13:41:31Z
Redmine
Redmine - Feature #1572: Delete Users and automatically ticket change
https://www.redmine.org/issues/1572?journal_id=4336
2008-08-13T13:41:31Z
Thomas Lecavelier
<ul><li><strong>Assignee</strong> deleted (<del><i>Jean-Philippe Lang</i></del>)</li><li><strong>Target version</strong> deleted (<del><i>0.8</i></del>)</li></ul><p>The target version field has to be set when it will <strong>actually</strong> part of the target release.</p>
Redmine - Feature #1572: Delete Users and automatically ticket change
https://www.redmine.org/issues/1572?journal_id=4645
2008-09-06T02:19:14Z
Chris Miller
<ul><li><strong>Target version</strong> set to <i>0.9.0</i></li></ul><p>Thomas Lecavelier wrote:</p>
<blockquote>
<p>The target version field has to be set when it will <strong>actually</strong> part of the target release.</p>
</blockquote>
<p>I see no reason this can't be done in 0.9. It's really needed - right now the only way to truly obliterate the trace of bots that have registered themselves is to go through the SQL database yourself - not fun.</p>
Redmine - Feature #1572: Delete Users and automatically ticket change
https://www.redmine.org/issues/1572?journal_id=4646
2008-09-06T02:32:05Z
Chris Miller
<ul></ul><p>Just for your information so you can work around it, I figured out a few SQL queries to help you manually delete people from your database (MySQL). This is best done from a shell.</p>
<p>Get a list of all users and their ID. I suggest you delete by ID, since that's far less likely to mess things up.<br /><pre>
SELECT id, login FROM users;
</pre></p>
<p>Test the ID just to be sure, otherwise you could accidentally delete the wrong user!<br /><pre>
SELECT id, login FROM users WHERE id = #;
</pre></p>
<p>Finally, be careful when you do this!<br /><pre>
DELETE FROM users WHERE id = #;
</pre></p>
Redmine - Feature #1572: Delete Users and automatically ticket change
https://www.redmine.org/issues/1572?journal_id=5592
2008-11-11T16:36:09Z
Jean-Philippe Lang
jp_lang@yahoo.fr
<ul><li><strong>Target version</strong> deleted (<del><i>0.9.0</i></del>)</li></ul>
Redmine - Feature #1572: Delete Users and automatically ticket change
https://www.redmine.org/issues/1572?journal_id=8463
2009-04-04T18:59:15Z
colin moock
<ul></ul><p>+1</p>
Redmine - Feature #1572: Delete Users and automatically ticket change
https://www.redmine.org/issues/1572?journal_id=8464
2009-04-04T19:01:04Z
colin moock
<ul></ul><p>sorry, that previous comment should have been:<br />+1 (killing spam users is an important issue for us)</p>
<p>is there a way to edit your own comment?</p>
Redmine - Feature #1572: Delete Users and automatically ticket change
https://www.redmine.org/issues/1572?journal_id=14581
2010-02-21T22:28:26Z
Antoine Beaupré
<ul></ul><p>Just clearing up the user table may not be a good idea, if the user has been in use for a while. There are entries keyed on the userid in a bunch of other tables.</p>
<p>If the user has <strong>not</strong> logged in or did anything, the following tables need to be cleared:</p>
<ul>
<li>tokens (user_id)</li>
<li>user_preferences (user_id)</li>
</ul>
<p>On top of that, a user id may also be found in the following tables:</p>
<ul>
<li>attachements (author_id)</li>
<li>changesets (user_id)</li>
<li>groups_users (user_id)</li>
<li>issues (assigned_to_id, author_id)</li>
<li>issue_category (assigned_to_id)</li>
<li>journals (user_id)</li>
<li>members (user_id)</li>
<li>member_roles (member_id)</li>
<li>messages (author_id)</li>
<li>news (author_id)</li>
<li>queries (user_id)</li>
<li>time_entries (user_id)</li>
<li>watchers</li>
<li>wiki_contents (author_id)</li>
<li>wiki_content_versions (author_id)</li>
</ul>
<p>Looks like it would be quite messy to cleanup all this stuff. For example: what do we do with an issue owned by a deleted user? Do we revert back to anonymous?</p>
<p>I'm not sure that deleting the users is a good idea.</p>
Redmine - Feature #1572: Delete Users and automatically ticket change
https://www.redmine.org/issues/1572?journal_id=14582
2010-02-21T23:23:49Z
colin moock
<ul></ul><p>"I'm not sure that deleting the users is a good idea." <br />--<br />please don't let implementation considerations obscure the actual issue here: spam bots are registering users in redmine projects all over the world, and redmine owners have no way to delete them. we have over 100 spam users in our db now. we need a way to delete them.</p>
Redmine - Feature #1572: Delete Users and automatically ticket change
https://www.redmine.org/issues/1572?journal_id=14922
2010-03-05T08:17:41Z
Eric Cope
<ul></ul><p>If assigned tasks, etc. are the only issue, a step for deleting users should be to reassign all related data to another user, an administrator for example.</p>
Redmine - Feature #1572: Delete Users and automatically ticket change
https://www.redmine.org/issues/1572?journal_id=16122
2010-04-23T15:23:37Z
Ben Blanco
<ul></ul><p>+1 We have the same problem, and have been manually cleaning the SQL DB since 0.7x</p>
<p>Maybe this could be split into two mini-features:</p>
<ol>
<li>Add <code>Delete</code> choice to the <strong>Registered</strong> page view (today the only option remains: <em>Activate</em>)</li>
<li>Add <code>Delete + Reassign Issues/Wiki edits/etc...</code> on the <strong>Locked</strong> page view</li>
</ol>
<p>In this case, the higher priority, and likely easier to do, would be on the <strong>Registered</strong> page.</p>
Redmine - Feature #1572: Delete Users and automatically ticket change
https://www.redmine.org/issues/1572?journal_id=17280
2010-06-11T08:24:40Z
Ivan Zotov
<ul></ul><p>Deleting users ( simply from DB ) works normal. Issues change field "assigned to" to "---".</p>
Redmine - Feature #1572: Delete Users and automatically ticket change
https://www.redmine.org/issues/1572?journal_id=17281
2010-06-11T08:25:32Z
Ivan Zotov
<ul></ul><p>In shotgun software it is works same. ( shotgunsoftware.com )</p>
Redmine - Feature #1572: Delete Users and automatically ticket change
https://www.redmine.org/issues/1572?journal_id=24583
2011-01-27T22:53:15Z
Mark Anderson
<ul></ul><p>Ben Blanco wrote:</p>
<blockquote>
<p>+1 We have the same problem, and have been manually cleaning the SQL DB since 0.7x</p>
<p>Maybe this could be split into two mini-features:</p>
<ol>
<li>Add <code>Delete</code> choice to the <strong>Registered</strong> page view (today the only option remains: <em>Activate</em>)</li>
<li>Add <code>Delete + Reassign Issues/Wiki edits/etc...</code> on the <strong>Locked</strong> page view</li>
</ol>
<p>In this case, the higher priority, and likely easier to do, would be on the <strong>Registered</strong> page.</p>
</blockquote>
<p>+! at least for a bogus registered user - they have left no traces in the DB yet.<br />Mark</p>
Redmine - Feature #1572: Delete Users and automatically ticket change
https://www.redmine.org/issues/1572?journal_id=60629
2014-12-31T03:12:23Z
Anonymous
<ul></ul><p>FYI - you can put this in cron and it'll lock any accounts older than two months.</p>
<pre>
psql redmine -c "UPDATE users SET status = 3 WHERE last_login_on BETWEEN '2000-01-01' and '$(date +%Y-%m-%d --date="2 months ago")' and status != 3;"
</pre>