huh I'm curious what dump options you used?
On Thu, Jul 17, 2014 at 3:05 PM, Andy Ingham <[email protected]> wrote: > To close the loop, I *think* I've got things resolved now. > > The gotcha was that I had not properly prepped the new (version 9.3) > database to receive the (8.4) dump file input. > > After some trial and error (and dropping and re-creating the db several > times) and teasing some things out of the online documentation, THIS is > what worked: > > /usr/pgsql-9.3/bin/createdb -O postgres spaceschema > /usr/pgsql-9.3/bin/createlang plpgsql spaceschema > /usr/pgsql-9.3/bin/createlang pltclu spaceschema > > (THEN, read in the dumpfile:) > /usr/pgsql-9.3/bin/psql -U spaceuser spaceschema < > spaceschema_17072014084044.bkup > > > > Andy > > > PS, this was all a preparatory step for upgrading SW itself from 2.0 to > 2.1. That'll have to wait for another day... > > > On 7/17/14, 11:35 AM, "Andy Ingham" <[email protected]> wrote: > > I should add that I've got oodles of THIS type of error: > > 2014/07/17 11:28:06 -04:00 28281 152.3.160.155: > rhnSQL/driver_postgresql.check_connection('ERROR', "DATABASE CONNECTION TO > 'spaceschema' LOST", "Exception information: Database instance has no > attribute 'dbh'") > > > in my rhn_server_xmlrpc.log > > I also have THIS in my rhn_taskomatic_daemon.log: > > STATUS | wrapper | 2014/07/17 11:32:11 | Launching a JVM... > INFO | jvm 5 | 2014/07/17 11:32:11 | Wrapper (Version 3.2.3) > http://wrapper.tanukisoftware.org > INFO | jvm 5 | 2014/07/17 11:32:11 | Copyright 1999-2006 Tanuki > Software, Inc. All Rights Reserved. > INFO | jvm 5 | 2014/07/17 11:32:11 | > ERROR | wrapper | 2014/07/17 11:32:41 | Startup failed: Timed out > waiting for signal from JVM. > ERROR | wrapper | 2014/07/17 11:32:41 | JVM did not exit on request, > terminated > INFO | wrapper | 2014/07/17 11:32:41 | JVM exited on its own while > waiting to kill the application. > STATUS | wrapper | 2014/07/17 11:32:41 | JVM exited in response to signal > SIGKILL (9). > FATAL | wrapper | 2014/07/17 11:32:41 | There were 5 failed launches in > a row, each lasting less than 300 seconds. Giving up. > FATAL | wrapper | 2014/07/17 11:32:41 | There may be a configuration > problem: please check the logs. > STATUS | wrapper | 2014/07/17 11:32:41 | <-- Wrapper Stopped > > > > > Andy > > On 7/17/14, 11:25 AM, "Andy Ingham" <[email protected]> wrote: > > So I attempted the postgres 8.4 > 9.3 upgrade this morning (for the local > db on my SW 2.0 server) > > Everything seemed to go pretty smoothly (thanks, Paul for the tips below!) > > BUT... > > The spacewalk instance is unable to connect to the upgraded database. > > I have confirmed that the pgsql user / password are valid and allow > connecting from the local system (via the psql CLIENT) > > But yet when I try to start spacewalk, it consistently says: > > Starting httpd: [ OK ] > Starting osa-dispatcher: Spacewalk 28090 2014/07/17 11:16:43 -04:00: > ('Error caught:',) > Spacewalk 28090 2014/07/17 11:16:43 -04:00: ('Traceback (most recent call > last):\n File "/usr/share/rhn/osad/jabber_lib.py", line 117, in main\n > self.setup_config(config)\n File "/usr/share/rhn/osad/osa_dispatcher.py", > line 112, in setup_config\n rhnSQL.initDB()\n File > "/usr/lib/python2.6/site-packages/spacewalk/server/rhnSQL/__init__.py", > line 102, in initDB\n __init__DB(backend, host, port, username, > password, database)\n File > "/usr/lib/python2.6/site-packages/spacewalk/server/rhnSQL/__init__.py", > line 55, in __init__DB\n __DB.connect()\n File > "/usr/lib/python2.6/site-packages/spacewalk/server/rhnSQL/driver_postgresql > .py", line 174, in connect\n return self.connect(reconnect=0)\n File > "/usr/lib/python2.6/site-packages/spacewalk/server/rhnSQL/driver_postgresql > .py", line 163, in connect\n password=str(self.password))\n File > "/usr/lib64/python2.6/site-packages/psycopg2/__init__.py", line 164, in > connect\n conn = _connect(dsn, connection_factory=connection_factory, > async=async)\nSQLConnectError: (None, None, \'spaceschema\', \'Attempting > Re-Connect to the database failed\')\n',) > > > > Any particular ideas on what I'm missing? > > TIA, > Andy > > Andy Ingham > IT Infrastructure > Fuqua School of Business > Duke University > > > > > > > > On 7/14/14, 5:01 PM, "Paul Robert Marino" <[email protected]> wrote: > > I Know of a few gotchas > > essentially the database upgrade itself is easy just do a full dump and > reload. > here are the gotchas > > 1) be sure to follow the steps here > http://www.postgresql.org/docs/9.3/static/upgrading.html including the > file system backup first. If there is a failure in the restore it can > be a nightmare to fix if you didn't make a copy of the database files > before you upgrade. > > 2) If you are using custom table spaces like I am make sure you make > backup copies of those as well. also recreate them on the new database > before the restore. I use custom table spaces because I hate putting > entire databases in /var so my journal is in the default location and > my data is on a different partition. if you intend to use custom table > spaces this is probably the best time to make that change its painful > otherwise. > > 3) if you are doing this on EL 6 you need to update a symlink for jdbc. > here is the default > " > ~]# ls -L /usr/share/java/postgresql-jdbc.jar > lrwxrwxrwx. 1 root root 44 Nov 5 2012 > /usr/share/java/postgresql-jdbc.jar -> > /usr/share/java/postgresql-8.4-703.jdbc4.jar > " > you need to make sure you have the correct PostgreSQL 9 jdbc file > installed and /usr/share/java/postgresql-jdbc.jar is pointed to the > one for 9 instead of 8. > This one is critical or you will experience a whole lot of weird > issues and possibly even database corruption especially with > Taskomatic. > > 3) I haven't had time to track this down yet however I did create a > bug ticket. I found that rhnsearchd is still ignoring the IP address > in the configuration and connecting to local host. I do not know if > its due to some remnant someplace left over from upgrades or if it is > a real bug in rhnsearchd itself. > > > > > On Mon, Jul 14, 2014 at 11:35 AM, Boyd, Robert > <[email protected]> wrote: >> Andy, >> >> When you do the upgrade I'd like to hear what if any details you >>discover that you have to work through that deviate from the postgres >>docs. I'd like to make the same upgrade. I looked at it a few months >>ago and decided to wait a while before tackling it. >> >> Thanks, >> >> Robert Boyd >> Sr. Systems Engineer >> PeopleFluent >> e. [email protected] >> >> Visit: www.peoplefluent.com | Read: Peoplefluent Blog | Follow: >>@peoplefluent | Download: iPad App >> >> -----Original Message----- >> From: [email protected] >>[mailto:[email protected]] On Behalf Of Andy Ingham >> Sent: Monday, July 14, 2014 10:02 AM >> To: [email protected] >> Subject: [Spacewalk-list] upgrading postgres (8.4 > 9.x) on the >>spacewalk server ? >> >> Folks -- >> >> Any particular gotchas about attempting to upgrade the postgresql server >>for our spacewalk installation? It's at version 8.4 and we'd like to get >>it into the 9.x series. >> >> I'm assuming it should just be done according to the postgres docs? >> >> TIA, >> Andy >> >> >> Andy Ingham >> IT Infrastructure >> Fuqua School of Business >> Duke University >> >> _______________________________________________ >> Spacewalk-list mailing list >> [email protected] >> https://www.redhat.com/mailman/listinfo/spacewalk-list >> >> _______________________________________________ >> Spacewalk-list mailing list >> [email protected] >> https://www.redhat.com/mailman/listinfo/spacewalk-list > > _______________________________________________ > Spacewalk-list mailing list > [email protected] > https://www.redhat.com/mailman/listinfo/spacewalk-list > > > _______________________________________________ > Spacewalk-list mailing list > [email protected] > https://www.redhat.com/mailman/listinfo/spacewalk-list > > > _______________________________________________ > Spacewalk-list mailing list > [email protected] > https://www.redhat.com/mailman/listinfo/spacewalk-list > > > _______________________________________________ > Spacewalk-list mailing list > [email protected] > https://www.redhat.com/mailman/listinfo/spacewalk-list _______________________________________________ Spacewalk-list mailing list [email protected] https://www.redhat.com/mailman/listinfo/spacewalk-list
