Unable to re-install maas after truncating/flushing database

Bug #979630 reported by Kevin Jackson
40
This bug affects 9 people
Affects Status Importance Assigned to Milestone
maas (Ubuntu)
Confirmed
Medium
Andres Rodriguez

Bug Description

Hi,
I'm having difficulty with my MAAS set up 0.1+bzr415+dfsg-0ubuntu2 on 12.04 B2).
I wanted to flush/purge my settings and start again - but now I've lost the ability to re-install the application - I get a --configure error:

Setting up maas (0.1+bzr415+dfsg-0ubuntu2) ...
 * Stopping web server apache2 [ OK ]
Syncing...
Traceback (most recent call last):
  File "/usr/bin/django-admin", line 5, in <module>
    management.execute_from_command_line()
  File "/usr/lib/python2.7/dist-packages/django/core/management/__init__.py", line 429, in execute_from_command_line
    utility.execute()
  File "/usr/lib/python2.7/dist-packages/django/core/management/__init__.py", line 379, in execute
    self.fetch_command(subcommand).run_from_argv(self.argv)
  File "/usr/lib/python2.7/dist-packages/django/core/management/base.py", line 191, in run_from_argv
    self.execute(*args, **options.__dict__)
  File "/usr/lib/python2.7/dist-packages/django/core/management/base.py", line 220, in execute
    output = self.handle(*args, **options)
  File "/usr/lib/python2.7/dist-packages/django/core/management/base.py", line 351, in handle
    return self.handle_noargs(**options)
  File "/usr/lib/python2.7/dist-packages/south/management/commands/syncdb.py", line 90, in handle_noargs
    syncdb.Command().execute(**options)
  File "/usr/lib/python2.7/dist-packages/django/core/management/base.py", line 220, in execute
    output = self.handle(*args, **options)
  File "/usr/lib/python2.7/dist-packages/django/core/management/base.py", line 351, in handle
    return self.handle_noargs(**options)
  File "/usr/lib/python2.7/dist-packages/django/core/management/commands/syncdb.py", line 56, in handle_noargs
    cursor = connection.cursor()
  File "/usr/lib/python2.7/dist-packages/django/db/backends/__init__.py", line 252, in cursor
    cursor = util.CursorWrapper(self._cursor(), self)
  File "/usr/lib/python2.7/dist-packages/django/db/backends/postgresql_psycopg2/base.py", line 140, in _cursor
    self.connection = Database.connect(**conn_params)
  File "/usr/lib/python2.7/dist-packages/psycopg2/__init__.py", line 179, in connect
    connection_factory=connection_factory, async=async)
psycopg2.OperationalError: FATAL: password authentication failed for user "maas"
FATAL: password authentication failed for user "maas"

My install was quite basic - just following the steps verbatim from wiki.ubuntu.com/ServerTeam/MAAS

I wanted to modify a node and was unable to delete this (I've raised a bug on this [978706]) but as it was a lab set up I thought I'd try and purge the database:

maas flush

This prompted me to delete the database, then I thought I could recreate this using the syncdb command.

I'm now at the stage where I can't re-install maas.

Cheers,

Kev

Changed in maas (Ubuntu):
assignee: nobody → Andres Rodriguez (andreserl)
James Page (james-page)
Changed in maas (Ubuntu):
importance: Undecided → Medium
Changed in maas (Ubuntu):
status: New → Confirmed
Revision history for this message
Jian Wen (wenjianhn) wrote :

Need to recreate the postgresql user manually with the info in
/etc/maas/maas_local_settings.py before re-install.

Revision history for this message
Newell Jensen (newell-jensen) wrote :
Download full text (4.5 KiB)

I ran into the problem mentioned (on install) and I also ran into the same problem when trying to remove maas packages:

ubuntu@maas:~$ sudo apt-get autoremove maas maas-dhcp maas-dns
[sudo] password for ubuntu:
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages will be REMOVED:
  maas maas-cluster-controller maas-dhcp maas-dns
0 upgraded, 0 newly installed, 4 to remove and 0 not upgraded.
2 not fully installed or removed.
After this operation, 352 kB disk space will be freed.
Do you want to continue? [Y/n] y
(Reading database ... 50526 files and directories currently installed.)
Removing maas (1.5.1+bzr2269-0ubuntu0.1) ...
Removing maas-cluster-controller (1.5.1+bzr2269-0ubuntu0.1) ...
maas-cluster-celery stop/waiting
maas-pserv stop/waiting
Removing maas-dhcp (1.5.1+bzr2269-0ubuntu0.1) ...
Removing maas-dns (1.5.1+bzr2269-0ubuntu0.1) ...
 * Stopping domain name service... bind9 waiting for pid 661 to die
                                                                         [ OK ]
 * Starting domain name service... bind9 [ OK ]
Processing triggers for man-db (2.6.7.1-1) ...
Setting up maas-region-controller (1.5.1+bzr2269-0ubuntu0.1) ...
 * Stopping web server apache2 *
 * Restarting PostgreSQL 9.3 database server [ OK ]
Considering dependency proxy for proxy_http:
Module proxy already enabled
Module proxy_http already enabled
Module expires already enabled
Module wsgi already enabled
 * Restarting message broker rabbitmq-server [ OK ]
Changing password for user "maas_longpoll" ...
...done.
Changing password for user "maas_workers" ...
...done.
Syncing...
Traceback (most recent call last):
  File "/usr/bin/django-admin", line 5, in <module>
    management.execute_from_command_line()
  File "/usr/lib/python2.7/dist-packages/django/core/management/__init__.py", line 399, in execute_from_command_line
    utility.execute()
  File "/usr/lib/python2.7/dist-packages/django/core/management/__init__.py", line 392, in execute
    self.fetch_command(subcommand).run_from_argv(self.argv)
  File "/usr/lib/python2.7/dist-packages/django/core/management/base.py", line 242, in run_from_argv
    self.execute(*args, **options.__dict__)
  File "/usr/lib/python2.7/dist-packages/django/core/management/base.py", line 285, in execute
    output = self.handle(*args, **options)
  File "/usr/lib/python2.7/dist-packages/django/core/management/base.py", line 415, in handle
    return self.handle_noargs(**options)
  File "/usr/lib/python2.7/dist-packages/south/management/commands/syncdb.py", line 90, in handle_noargs
    syncdb.Command().execute(**options)
  File "/usr/lib/python2.7/dist-packages/django/core/management/base.py", line 285, in execute
    output = self.handle(*args, **options)
  File "/usr/lib/python2.7/dist-packages/django/core/management/base.py", line 415, in handle
    return self.handle_noargs(**options)
  File "/usr/lib/python2.7/dist-packages/django/core/management/commands/syncdb.py", line 57, in han...

Read more...

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Related questions

Remote bug watches

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