Dear Dave:
If you have 9 million inactive users, then I would also evaluate the current inactive users so even after you clean up the DB, this issue does not happen again.
Best bet is to open a case to get a script from Engineering to do this after a database review
Thanks
Hal German