Error while running post installation for tor
Created by: jyotishp
I was installing tor using plinth and received a "500" internal error. log.txt
[2016-09-20 16:24:06,109] plinth.module_loader INFO Importing plinth.modules.system
[2016-09-20 16:24:06,112] plinth.module_loader INFO Importing plinth.modules.tor
[2016-09-20 16:24:06,121] plinth.module_loader INFO Importing plinth.modules.transmission
[2016-09-20 16:24:06,132] plinth.module_loader INFO Importing plinth.modules.ttrss
[2016-09-20 16:24:06,134] plinth.module_loader INFO Importing plinth.modules.upgrades
[2016-09-20 16:24:06,142] plinth.module_loader INFO Importing plinth.modules.users
[2016-09-20 16:24:06,180] plinth.module_loader INFO Importing plinth.modules.xmpp
[2016-09-20 16:24:06,182] plinth.module_loader INFO Importing plinth.modules.disks
[2016-09-20 16:24:06,188] plinth.module_loader INFO Importing plinth.modules.security
[2016-09-20 16:24:06,193] plinth.module_loader INFO Importing plinth.modules.snapshot
[2016-09-20 16:24:06,290] plinth.actions INFO Executing command - ['sudo', '-n', '/usr/share/plinth/actions/tor', 'get-status']
[2016-09-20 16:24:07,610] plinth.actions INFO Executing command - ['sudo', '-n', '/usr/share/plinth/actions/pagekite', 'is-disabled']
[2016-09-20 16:24:08,643] plinth.actions INFO Executing command - ['sudo', '-n', '/usr/share/plinth/actions/pagekite', 'get-kite']
[2016-09-20 16:24:09,655] plinth.__main__ INFO Setting up CherryPy server
[20/Sep/2016:16:24:09] ENGINE Listening for SIGUSR1.
[20/Sep/2016:16:24:09] ENGINE Listening for SIGTERM.
[20/Sep/2016:16:24:09] ENGINE Listening for SIGHUP.
[20/Sep/2016:16:24:09] ENGINE Bus STARTING
[20/Sep/2016:16:24:09] ENGINE Started monitor thread '_TimeoutMonitor'.
[20/Sep/2016:16:24:09] ENGINE Serving on http://127.0.0.1:8000
[20/Sep/2016:16:24:09] ENGINE Bus STARTED
[2016-09-20 16:33:19,188] plinth.setup INFO Running module setup - tor
[2016-09-20 16:33:19,190] plinth.setup INFO Running install for module - tor, packages - ['tor', 'tor-geoipdb', 'torsocks', 'obfs4proxy', 'apt-transport-tor']
[2016-09-20 16:33:19,191] plinth.actions INFO Executing command - ['sudo', '-n', '/usr/share/plinth/actions/packages', 'update']
[2016-09-20 16:33:28,862] plinth.actions INFO Executing command - ['sudo', '-n', '/usr/share/plinth/actions/packages', 'install', 'tor', 'tor', 'tor-geoipdb', 'torsocks', 'obfs4proxy', 'apt-transport-tor']
[2016-09-20 16:43:03,522] plinth.setup INFO Running step for module - tor, step - post
[2016-09-20 16:43:03,523] plinth.actions INFO Executing command - ['sudo', '-n', '/usr/share/plinth/actions/tor', 'setup']
[2016-09-20 16:43:36,976] plinth.setup INFO Running step for module - tor, step - post
[2016-09-20 16:43:36,977] plinth.actions INFO Executing command - ['sudo', '-n', '/usr/share/plinth/actions/tor', 'configure', '--apt-transport-tor', 'enable']
[2016-09-20 16:43:38,170] plinth.setup INFO Running step for module - tor, step - post
[2016-09-20 16:43:38,171] plinth.actions INFO Executing command - ['sudo', '-n', '/usr/share/plinth/actions/firewall', 'get-enabled-services', '--zone', 'internal']
[2016-09-20 16:43:39,984] plinth.actions INFO Executing command - ['sudo', '-n', '/usr/share/plinth/actions/firewall', 'get-enabled-services', '--zone', 'external']
[2016-09-20 16:43:41,773] plinth.modules.firewall INFO Service enabled - tor-socks, True
[2016-09-20 16:43:41,774] plinth.setup INFO Running step for module - tor, step - post
[2016-09-20 16:43:41,775] plinth.actions INFO Executing command - ['sudo', '-n', '/usr/share/plinth/actions/firewall', 'get-enabled-services', '--zone', 'internal']
[2016-09-20 16:43:43,498] plinth.actions INFO Executing command - ['sudo', '-n', '/usr/share/plinth/actions/firewall', 'get-enabled-services', '--zone', 'external']
[2016-09-20 16:43:45,217] plinth.modules.firewall INFO Service enabled - tor-bridge, True
[2016-09-20 16:43:45,219] plinth.actions INFO Executing command - ['sudo', '-n', '/usr/share/plinth/actions/firewall', 'add-service', 'tor-orport', '--zone', 'internal']
[2016-09-20 16:43:48,611] plinth.actions INFO Executing command - ['sudo', '-n', '/usr/share/plinth/actions/firewall', 'add-service', 'tor-orport', '--zone', 'external']
[2016-09-20 16:43:51,975] plinth.actions INFO Executing command - ['sudo', '-n', '/usr/share/plinth/actions/firewall', 'add-service', 'tor-obfs3', '--zone', 'internal']
[2016-09-20 16:43:55,376] plinth.actions INFO Executing command - ['sudo', '-n', '/usr/share/plinth/actions/firewall', 'add-service', 'tor-obfs3', '--zone', 'external']
[2016-09-20 16:43:58,756] plinth.actions INFO Executing command - ['sudo', '-n', '/usr/share/plinth/actions/firewall', 'add-service', 'tor-obfs4', '--zone', 'internal']
[2016-09-20 16:44:02,130] plinth.actions INFO Executing command - ['sudo', '-n', '/usr/share/plinth/actions/firewall', 'add-service', 'tor-obfs4', '--zone', 'external']
[2016-09-20 16:44:05,454] plinth.setup INFO Running step for module - tor, step - post
[2016-09-20 16:44:05,455] plinth.actions INFO Executing command - ['sudo', '-n', '/usr/share/plinth/actions/tor', 'get-status']
[2016-09-20 16:44:06,465] plinth.modules.names INFO Added domain rbxbkiuwts4n3h5q.onion of type hiddenservice with services ['http', 'https', 'ssh']
[2016-09-20 16:44:17,183] django.request ERROR Internal Server Error: /plinth/firstboot/state0/
Traceback (most recent call last):
File "/usr/lib/python3/dist-packages/django/db/backends/utils.py", line 64, in execute
return self.cursor.execute(sql, params)
File "/usr/lib/python3/dist-packages/django/db/backends/sqlite3/base.py", line 337, in execute
return Database.Cursor.execute(self, query, params)
sqlite3.OperationalError: database is locked
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "/usr/lib/python3/dist-packages/django/core/handlers/exception.py", line 39, in inner
response = get_response(request)
File "/usr/lib/python3/dist-packages/django/core/handlers/base.py", line 249, in _legacy_get_response
response = self._get_response(request)
File "/usr/lib/python3/dist-packages/django/core/handlers/base.py", line 178, in _get_response
response = middleware_method(request, callback, callback_args, callback_kwargs)
File "/usr/lib/python3/dist-packages/stronghold/middleware.py", line 22, in process_view
if request.user.is_authenticated() or utils.is_view_func_public(view_func) \
File "/usr/lib/python3/dist-packages/django/utils/functional.py", line 234, in inner
self._setup()
File "/usr/lib/python3/dist-packages/django/utils/functional.py", line 380, in _setup
self._wrapped = self._setupfunc()
File "/usr/lib/python3/dist-packages/django/contrib/auth/middleware.py", line 24, in <lambda>
request.user = SimpleLazyObject(lambda: get_user(request))
File "/usr/lib/python3/dist-packages/django/contrib/auth/middleware.py", line 12, in get_user
request._cached_user = auth.get_user(request)
File "/usr/lib/python3/dist-packages/django/contrib/auth/__init__.py", line 187, in get_user
user = backend.get_user(user_id)
File "/usr/lib/python3/dist-packages/django/contrib/auth/backends.py", line 102, in get_user
user = UserModel._default_manager.get(pk=user_id)
File "/usr/lib/python3/dist-packages/django/db/models/manager.py", line 85, in manager_method
return getattr(self.get_queryset(), name)(*args, **kwargs)
File "/usr/lib/python3/dist-packages/django/db/models/query.py", line 379, in get
num = len(clone)
File "/usr/lib/python3/dist-packages/django/db/models/query.py", line 238, in __len__
self._fetch_all()
File "/usr/lib/python3/dist-packages/django/db/models/query.py", line 1087, in _fetch_all
self._result_cache = list(self.iterator())
File "/usr/lib/python3/dist-packages/django/db/models/query.py", line 54, in __iter__
results = compiler.execute_sql()
File "/usr/lib/python3/dist-packages/django/db/models/sql/compiler.py", line 835, in execute_sql
cursor.execute(sql, params)
File "/usr/lib/python3/dist-packages/django/db/backends/utils.py", line 64, in execute
return self.cursor.execute(sql, params)
File "/usr/lib/python3/dist-packages/django/db/utils.py", line 94, in __exit__
six.reraise(dj_exc_type, dj_exc_value, traceback)
File "/usr/lib/python3/dist-packages/django/utils/six.py", line 685, in reraise
raise value.with_traceback(tb)
File "/usr/lib/python3/dist-packages/django/db/backends/utils.py", line 64, in execute
return self.cursor.execute(sql, params)
File "/usr/lib/python3/dist-packages/django/db/backends/sqlite3/base.py", line 337, in execute
return Database.Cursor.execute(self, query, params)
django.db.utils.OperationalError: database is locked