Upgrade from CE to EE fails

I am evaluating an upgrade from 9.2.5-ce to 9.2.5-ee. It looks like the DB migrate after the package installation is failing. After the upgrade it returns an error 500 and in the sidekiq log I see:

2017-06-26_09:23:44.32860 PG::UndefinedTable: ERROR:  relation "geo_nodes" does not exist
2017-06-26_09:23:44.32861 LINE 5:                WHERE a.attrelid = '"geo_nodes"'::regclass
2017-06-26_09:23:44.32862                                           ^
2017-06-26_09:23:44.32862 :               SELECT a.attname, format_type(a.atttypid, a.atttypmod),
2017-06-26_09:23:44.32862                      pg_get_expr(d.adbin, d.adrelid), a.attnotnull, a.atttypid, a.atttypmod
2017-06-26_09:23:44.32862                 FROM pg_attribute a LEFT JOIN pg_attrdef d
2017-06-26_09:23:44.32862                   ON a.attrelid = d.adrelid AND a.attnum = d.adnum
2017-06-26_09:23:44.32862                WHERE a.attrelid = '"geo_nodes"'::regclass
2017-06-26_09:23:44.32862                  AND a.attnum > 0 AND NOT a.attisdropped
2017-06-26_09:23:44.32863                ORDER BY a.attnum

Other than that, no other errors are leaping out at me.

Both the app host and DB host are running CentOS 7, with PostgreSQL 9.2 (as packaged by CentOS) on the DB host.

Quoting my reply from here http://forum.gitlab.com/t/migration-from-ce-to-ee/26635/5

This probably indicates that the database schema was not upgraded properly. One way to do this is to import a community edition backup into an enterprise instance, but I’m sure there are others.

Look at your db migration status:

# gitlab-rake db:migrate:status RAILS_ENV=production

You’ll probably find that some of those are down. So fire them up:

# gitlab-rake db:migrate RAILS_ENV=production

Then do the usual to get things going again:

# gitlab-ctl reconfigure
# gitlab-ctl restart
# gitlab-rake gitlab:check SANITIZE=true

Figured this out by going here: