Installing MAAS in Trusty fails to restart apache2 (traceback about the maas user when restarting apache2)

Bug #1547311 reported by Jeff Lane 
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
maas (Ubuntu)
New
Undecided
Unassigned

Bug Description

Installed a VM with 14.04.3, did a full dist-upgrade and then installed maas from the Trusty repos.

Since no newer maas has been SRUd yet, 1.7.6 is the only MAAS available to trusty unless you know about the PPAs. So normal users would end up with 1.7.6, not 1.9 by default.

Installed maas and the restart of Apache failed. Looking in the apache error logs and I see the following trace:
[Thu Feb 18 22:01:44.412117 2016] [:error] [pid 9747:tid 140636476237696] mod_wsgi (pid=9747): Target WSGI script '/usr/share/maas/wsgi.py' cannot be loaded as Python module.
[Thu Feb 18 22:01:44.412255 2016] [:error] [pid 9747:tid 140636476237696] mod_wsgi (pid=9747): Exception occurred processing WSGI script '/usr/share/maas/wsgi.py'.
[Thu Feb 18 22:01:44.412371 2016] [:error] [pid 9747:tid 140636476237696] Traceback (most recent call last):
[Thu Feb 18 22:01:44.412411 2016] [:error] [pid 9747:tid 140636476237696] File "/usr/share/maas/wsgi.py", line 39, in <module>
[Thu Feb 18 22:01:44.412567 2016] [:error] [pid 9747:tid 140636476237696] start_up()
[Thu Feb 18 22:01:44.412624 2016] [:error] [pid 9747:tid 140636476237696] File "/usr/lib/python2.7/dist-packages/maasserver/start_up.py", line 62, in start_up
[Thu Feb 18 22:01:44.412752 2016] [:error] [pid 9747:tid 140636476237696] security.get_shared_secret()
[Thu Feb 18 22:01:44.412771 2016] [:error] [pid 9747:tid 140636476237696] File "/usr/lib/python2.7/dist-packages/provisioningserver/utils/twisted.py", line 113, in wrapper
[Thu Feb 18 22:01:44.412961 2016] [:error] [pid 9747:tid 140636476237696] return func_in_reactor(*args, **kwargs).wait(timeout)
[Thu Feb 18 22:01:44.412986 2016] [:error] [pid 9747:tid 140636476237696] File "/usr/lib/python2.7/dist-packages/crochet/_eventloop.py", line 219, in wait
[Thu Feb 18 22:01:44.413210 2016] [:error] [pid 9747:tid 140636476237696] result.raiseException()
[Thu Feb 18 22:01:44.413253 2016] [:error] [pid 9747:tid 140636476237696] File "/usr/lib/python2.7/dist-packages/twisted/python/threadpool.py", line 191, in _worker
[Thu Feb 18 22:01:44.414141 2016] [:error] [pid 9747:tid 140636476237696] result = context.call(ctx, function, *args, **kwargs)
[Thu Feb 18 22:01:44.414166 2016] [:error] [pid 9747:tid 140636476237696] File "/usr/lib/python2.7/dist-packages/twisted/python/context.py", line 118, in callWithContext
[Thu Feb 18 22:01:44.414482 2016] [:error] [pid 9747:tid 140636476237696] return self.currentContext().callWithContext(ctx, func, *args, **kw)
[Thu Feb 18 22:01:44.414502 2016] [:error] [pid 9747:tid 140636476237696] File "/usr/lib/python2.7/dist-packages/twisted/python/context.py", line 81, in callWithContext
[Thu Feb 18 22:01:44.414528 2016] [:error] [pid 9747:tid 140636476237696] return func(*args,**kw)
[Thu Feb 18 22:01:44.414541 2016] [:error] [pid 9747:tid 140636476237696] File "/usr/lib/python2.7/dist-packages/provisioningserver/utils/twisted.py", line 148, in wrapper
[Thu Feb 18 22:01:44.414559 2016] [:error] [pid 9747:tid 140636476237696] return func(*args, **kwargs)
[Thu Feb 18 22:01:44.414571 2016] [:error] [pid 9747:tid 140636476237696] File "/usr/lib/python2.7/dist-packages/maasserver/utils/async.py", line 152, in call_within_transaction
[Thu Feb 18 22:01:44.414705 2016] [:error] [pid 9747:tid 140636476237696] with transaction.atomic():
[Thu Feb 18 22:01:44.414724 2016] [:error] [pid 9747:tid 140636476237696] File "/usr/lib/python2.7/dist-packages/django/db/transaction.py", line 237, in __enter__
[Thu Feb 18 22:01:44.415039 2016] [:error] [pid 9747:tid 140636476237696] if not connection.get_autocommit():
[Thu Feb 18 22:01:44.415058 2016] [:error] [pid 9747:tid 140636476237696] File "/usr/lib/python2.7/dist-packages/django/db/backends/__init__.py", line 324, in get_autocommit
[Thu Feb 18 22:01:44.415670 2016] [:error] [pid 9747:tid 140636476237696] self.ensure_connection()
[Thu Feb 18 22:01:44.415690 2016] [:error] [pid 9747:tid 140636476237696] File "/usr/lib/python2.7/dist-packages/django/db/backends/__init__.py", line 124, in ensure_connection
[Thu Feb 18 22:01:44.415713 2016] [:error] [pid 9747:tid 140636476237696] self.connect()
[Thu Feb 18 22:01:44.415725 2016] [:error] [pid 9747:tid 140636476237696] File "/usr/lib/python2.7/dist-packages/django/db/utils.py", line 99, in __exit__
[Thu Feb 18 22:01:44.416023 2016] [:error] [pid 9747:tid 140636476237696] six.reraise(dj_exc_type, dj_exc_value, traceback)
[Thu Feb 18 22:01:44.416042 2016] [:error] [pid 9747:tid 140636476237696] File "/usr/lib/python2.7/dist-packages/django/db/backends/__init__.py", line 124, in ensure_connection
[Thu Feb 18 22:01:44.416065 2016] [:error] [pid 9747:tid 140636476237696] self.connect()
[Thu Feb 18 22:01:44.416113 2016] [:error] [pid 9747:tid 140636476237696] File "/usr/lib/python2.7/dist-packages/django/db/backends/__init__.py", line 112, in connect
[Thu Feb 18 22:01:44.416137 2016] [:error] [pid 9747:tid 140636476237696] self.connection = self.get_new_connection(conn_params)
[Thu Feb 18 22:01:44.416151 2016] [:error] [pid 9747:tid 140636476237696] File "/usr/lib/python2.7/dist-packages/django/db/backends/postgresql_psycopg2/base.py", line 116, in get_new_connection
[Thu Feb 18 22:01:44.416314 2016] [:error] [pid 9747:tid 140636476237696] return Database.connect(**conn_params)
[Thu Feb 18 22:01:44.416334 2016] [:error] [pid 9747:tid 140636476237696] File "/usr/lib/python2.7/dist-packages/psycopg2/__init__.py", line 179, in connect
[Thu Feb 18 22:01:44.416485 2016] [:error] [pid 9747:tid 140636476237696] connection_factory=connection_factory, async=async)
[Thu Feb 18 22:01:44.416526 2016] [:error] [pid 9747:tid 140636476237696] OperationalError: FATAL: password authentication failed for user "maas"
[Thu Feb 18 22:01:44.416533 2016] [:error] [pid 9747:tid 140636476237696] FATAL: password authentication failed for user "maas"
[Thu Feb 18 22:01:44.416537 2016] [:error] [pid 9747:tid 140636476237696]
[Thu Feb 18 22:01:44.865399 2016] [:error] [pid 9748:tid 140636476237696] mod_wsgi (pid=9748): Target WSGI script '/usr/share/maas/wsgi.py' cannot be loaded as Python module.
[Thu Feb 18 22:01:44.865493 2016] [:error] [pid 9748:tid 140636476237696] mod_wsgi (pid=9748): Exception occurred processing WSGI script '/usr/share/maas/wsgi.py'.
[Thu Feb 18 22:01:44.865583 2016] [:error] [pid 9748:tid 140636476237696] Traceback (most recent call last):
[Thu Feb 18 22:01:44.865627 2016] [:error] [pid 9748:tid 140636476237696] File "/usr/share/maas/wsgi.py", line 39, in <module>
[Thu Feb 18 22:01:44.865790 2016] [:error] [pid 9748:tid 140636476237696] start_up()
[Thu Feb 18 22:01:44.865812 2016] [:error] [pid 9748:tid 140636476237696] File "/usr/lib/python2.7/dist-packages/maasserver/start_up.py", line 62, in start_up
[Thu Feb 18 22:01:44.865920 2016] [:error] [pid 9748:tid 140636476237696] security.get_shared_secret()
[Thu Feb 18 22:01:44.865937 2016] [:error] [pid 9748:tid 140636476237696] File "/usr/lib/python2.7/dist-packages/provisioningserver/utils/twisted.py", line 113, in wrapper
[Thu Feb 18 22:01:44.866086 2016] [:error] [pid 9748:tid 140636476237696] return func_in_reactor(*args, **kwargs).wait(timeout)
[Thu Feb 18 22:01:44.866109 2016] [:error] [pid 9748:tid 140636476237696] File "/usr/lib/python2.7/dist-packages/crochet/_eventloop.py", line 219, in wait
[Thu Feb 18 22:01:44.866248 2016] [:error] [pid 9748:tid 140636476237696] result.raiseException()
[Thu Feb 18 22:01:44.866286 2016] [:error] [pid 9748:tid 140636476237696] File "/usr/lib/python2.7/dist-packages/twisted/python/threadpool.py", line 191, in _worker
[Thu Feb 18 22:01:44.866432 2016] [:error] [pid 9748:tid 140636476237696] result = context.call(ctx, function, *args, **kwargs)
[Thu Feb 18 22:01:44.866450 2016] [:error] [pid 9748:tid 140636476237696] File "/usr/lib/python2.7/dist-packages/twisted/python/context.py", line 118, in callWithContext
[Thu Feb 18 22:01:44.866533 2016] [:error] [pid 9748:tid 140636476237696] return self.currentContext().callWithContext(ctx, func, *args, **kw)
[Thu Feb 18 22:01:44.866550 2016] [:error] [pid 9748:tid 140636476237696] File "/usr/lib/python2.7/dist-packages/twisted/python/context.py", line 81, in callWithContext
[Thu Feb 18 22:01:44.866575 2016] [:error] [pid 9748:tid 140636476237696] return func(*args,**kw)
[Thu Feb 18 22:01:44.866587 2016] [:error] [pid 9748:tid 140636476237696] File "/usr/lib/python2.7/dist-packages/provisioningserver/utils/twisted.py", line 148, in wrapper
[Thu Feb 18 22:01:44.866604 2016] [:error] [pid 9748:tid 140636476237696] return func(*args, **kwargs)
[Thu Feb 18 22:01:44.866616 2016] [:error] [pid 9748:tid 140636476237696] File "/usr/lib/python2.7/dist-packages/maasserver/utils/async.py", line 152, in call_within_transaction
[Thu Feb 18 22:01:44.866712 2016] [:error] [pid 9748:tid 140636476237696] with transaction.atomic():
[Thu Feb 18 22:01:44.866729 2016] [:error] [pid 9748:tid 140636476237696] File "/usr/lib/python2.7/dist-packages/django/db/transaction.py", line 237, in __enter__
[Thu Feb 18 22:01:44.866954 2016] [:error] [pid 9748:tid 140636476237696] if not connection.get_autocommit():
[Thu Feb 18 22:01:44.866972 2016] [:error] [pid 9748:tid 140636476237696] File "/usr/lib/python2.7/dist-packages/django/db/backends/__init__.py", line 324, in get_autocommit
[Thu Feb 18 22:01:44.867708 2016] [:error] [pid 9748:tid 140636476237696] self.ensure_connection()
[Thu Feb 18 22:01:44.867765 2016] [:error] [pid 9748:tid 140636476237696] File "/usr/lib/python2.7/dist-packages/django/db/backends/__init__.py", line 124, in ensure_connection
[Thu Feb 18 22:01:44.867802 2016] [:error] [pid 9748:tid 140636476237696] self.connect()
[Thu Feb 18 22:01:44.867816 2016] [:error] [pid 9748:tid 140636476237696] File "/usr/lib/python2.7/dist-packages/django/db/utils.py", line 99, in __exit__
[Thu Feb 18 22:01:44.867995 2016] [:error] [pid 9748:tid 140636476237696] six.reraise(dj_exc_type, dj_exc_value, traceback)
[Thu Feb 18 22:01:44.868013 2016] [:error] [pid 9748:tid 140636476237696] File "/usr/lib/python2.7/dist-packages/django/db/backends/__init__.py", line 124, in ensure_connection
[Thu Feb 18 22:01:44.868034 2016] [:error] [pid 9748:tid 140636476237696] self.connect()
[Thu Feb 18 22:01:44.868046 2016] [:error] [pid 9748:tid 140636476237696] File "/usr/lib/python2.7/dist-packages/django/db/backends/__init__.py", line 112, in connect
[Thu Feb 18 22:01:44.868062 2016] [:error] [pid 9748:tid 140636476237696] self.connection = self.get_new_connection(conn_params)
[Thu Feb 18 22:01:44.868074 2016] [:error] [pid 9748:tid 140636476237696] File "/usr/lib/python2.7/dist-packages/django/db/backends/postgresql_psycopg2/base.py", line 116, in get_new_connection
[Thu Feb 18 22:01:44.868176 2016] [:error] [pid 9748:tid 140636476237696] return Database.connect(**conn_params)
[Thu Feb 18 22:01:44.868193 2016] [:error] [pid 9748:tid 140636476237696] File "/usr/lib/python2.7/dist-packages/psycopg2/__init__.py", line 179, in connect
[Thu Feb 18 22:01:44.868339 2016] [:error] [pid 9748:tid 140636476237696] connection_factory=connection_factory, async=async)
[Thu Feb 18 22:01:44.868395 2016] [:error] [pid 9748:tid 140636476237696] OperationalError: FATAL: password authentication failed for user "maas"
[Thu Feb 18 22:01:44.868403 2016] [:error] [pid 9748:tid 140636476237696] FATAL: password authentication failed for user "maas"
[Thu Feb 18 22:01:44.868407 2016] [:error] [pid 9748:tid 140636476237696]
[Thu Feb 18 22:02:12.609204 2016] [mpm_event:notice] [pid 9746:tid 140636476237696] AH00491: caught SIGTERM, shutting down

if I manually restart apache2 (sudo service apache2 restart) it seems to work fine.

ProblemType: Bug
DistroRelease: Ubuntu 14.04
Package: maas 1.7.6+bzr3376-0ubuntu2~14.04.1
ProcVersionSignature: Ubuntu 3.13.0-77.121-generic 3.13.11-ckt32
Uname: Linux 3.13.0-77-generic x86_64
ApportVersion: 2.14.1-0ubuntu3.19
Architecture: amd64
Date: Thu Feb 18 22:04:28 2016
InstallationDate: Installed on 2014-04-18 (671 days ago)
InstallationMedia:

PackageArchitecture: all
ProcEnviron:
 TERM=xterm
 PATH=(custom, no user)
 LANG=en_US.UTF-8
 SHELL=/bin/bash
SourcePackage: maas
UpgradeStatus: No upgrade log present (probably fresh install)

Revision history for this message
Jeff Lane  (bladernr) wrote :
summary: - Installing MAAS in Trusty breaks apache (traceback about the maas user
- when restarting apache2)
+ Installing MAAS in Trusty fails to restart apache2 (traceback about the
+ maas user when restarting apache2)
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.