0

Can I delete users from the mysql auth_user table with no bad side effects?
 

We have had a rash of spam postings and I looked into the database to see if I could find information about the users.

Can I delete all the undesired users or is there a way to do this with some mysql command/script? Are there related tables I need to update as well?

To enter a block of code:

  • enter empty line after your previous text
  • paste or type the code
  • select the code and press the button above
Preview: (hide)
tim's avatar
51
tim
asked 10 years ago, updated 10 years ago

Comments

see more comments

1 Answer

0

Instead of doing it from mysql I did it from the django admin page:

YourSiteUrl/admin

and

.../admin/auth/user/

however, I don't believe this is recommended by the implementors of the software - it is recommended to block them, however this is a tedious task if there are more than a few (and when the spammers sign up it usually means trouble...)

To enter a block of code:

  • enter empty line after your previous text
  • paste or type the code
  • select the code and press the button above
Preview: (hide)
tim's avatar
51
tim
answered 10 years ago, updated 10 years ago
link

Comments

This is ok, but the side effect will be a deletion of all user's content. Better might be changing status of the user account to blocked or merging it to some other account by the command `merge_users`.

Evgeny's avatar Evgeny (10 years ago)

thanks. we actually want to delete all the users content in these instances - these were spam accounts.

tim's avatar tim (10 years ago)
see more comments