Index: django/core/management.py
===================================================================
--- django/core/management.py	(revision 4504)
+++ django/core/management.py	(working copy)
@@ -1174,6 +1174,12 @@
 
 def run_shell(use_plain=False):
     "Runs a Python interactive interpreter. Tries to use IPython, if it's available."
+    # Force loading all the models in the installed apps. Otherwise, we
+    # can get into some weird problems where many_to_many relations fail because
+    # field options differ (perhaps due to permisions):
+    from django.db.models.loading import get_models
+    loaded_models = get_models()
+
     try:
         if use_plain:
             # Don't bother loading IPython, because the user wants plain Python.
