Awx: Error upgrading from 1.0.2.337 to 1.0.2.356

Created on 15 Jan 2018  路  3Comments  路  Source: ansible/awx

ISSUE TYPE
  • Bug Report
COMPONENT NAME
  • Installer
SUMMARY

Upgrade from 1.0.2.337 to 1.0.2.356 fails

ENVIRONMENT
  • AWX version: 1.0.2.337
  • AWX install method: docker on linux
  • Ansible version: 2.4.2.0
  • Operating System: Centos 7
  • Web Browser: Chrome/Firefox on Ubuntu
STEPS TO REPRODUCE

Remove awx_task and awx_web container. Relaunch inventory installer with dockerhub_version=1.0.2.356.

EXPECTED RESULTS

The migration completes and UI is accessible again.

ACTUAL RESULTS

Migration hangs. Ansible playbook successfully ends but UI is not accessible (it tells "AWX is upgrading" and refreshes). I have waited for about 30 minutes..
No error in awx_task logs.
awx-manage showmigrations from awx_task container tells:

auth
 [X] 0001_initial
 [X] 0002_alter_permission_name_max_length
 [X] 0003_alter_user_email_max_length
 [X] 0004_alter_user_username_opts
 [X] 0005_alter_user_last_login_null
 [X] 0006_require_contenttypes_0002
 [X] 0007_alter_validators_add_error_messages
 [X] 0008_alter_user_username_max_length
conf
 [X] 0001_initial
 [X] 0002_v310_copy_tower_settings
 [X] 0003_v310_JSONField_changes
 [X] 0004_v320_reencrypt
contenttypes
 [X] 0001_initial
 [X] 0002_remove_content_type_name
django_celery_results
 [X] 0001_initial
main
 [X] 0001_initial
 [X] 0002_squashed_v300_release (18 squashed migrations)
 [X] 0003_squashed_v300_v303_updates (9 squashed migrations)
 [X] 0004_squashed_v310_release (6 squashed migrations)
 [X] 0005_squashed_v310_v313_updates (3 squashed migrations)
 [X] 0006_v320_release
 [X] 0007_v320_data_migrations
 [X] 0008_v320_drop_v1_credential_fields
 [X] 0009_v322_add_setting_field_for_activity_stream
 [X] 0010_v322_add_ovirt4_tower_inventory
 [X] 0011_v322_encrypt_survey_passwords
 [X] 0012_v322_update_cred_types
 [X] 0013_v330_multi_credential
 [X] 0014_v330_saved_launchtime_configs
 [X] 0015_v330_blank_start_args
 [X] 0016_v330_non_blank_workflow
 [X] 0017_v330_move_deprecated_stdout
 [ ] 0018_v330_add_additional_stdout_events    <--------------
 [ ] 0019_v330_custom_virtualenv                       <--------------
sessions
 [X] 0001_initial
sites
 [X] 0001_initial
 [X] 0002_alter_domain_unique
social_django
 [X] 0001_initial (2 squashed migrations)
 [X] 0002_add_related_name (2 squashed migrations)
 [X] 0003_alter_email_max_length (2 squashed migrations)
 [X] 0004_auto_20160423_0400 (2 squashed migrations)
 [X] 0005_auto_20160727_2333 (1 squashed migrations)
 [X] 0006_partial
 [X] 0007_code_timestamp
 [X] 0008_partial_timestamp
sso
 [X] 0001_initial
 [X] 0002_expand_provider_options
taggit
 [X] 0001_initial
 [X] 0002_auto_20150616_2121
ADDITIONAL INFORMATION

I was initially upgrading from 335 directly to 372, but I had this same error.
I thought it was a "too big jump". So I restored 335 dump and reinstalled it, and decided to do the upgrade steb by step.
335 to 337 : ok
337 to 356 : this issue

installer bug

All 3 comments

This issue is also apparent on other version upgrades #138
Quite a serious issue, Forced into either reverting to a backup and staying on that version indefinitely or wiping the postgres database and upgrading

I'm running into a similar issue upgrading from 1.0.2.327 -> 1.0.2.372. It's trying to insert a duplicate record?

django.db.utils.IntegrityError: duplicate key value violates unique constraint "auth_user_username_key"
DETAIL: Key (username)=(admin) already exists.

Try removing removing the postgres container and re-creating the database.

There is no upgrade path for awx/devel. If you are tracking the HEAD of awx you will never be able to reliably upgrade. Sometimes it might work, sometimes it might now. That is a result of how the devel branch is used.

See: https://groups.google.com/forum/#!topic/awx-project/is60aeikbVs

Was this page helpful?
0 / 5 - 0 ratings