[Spacewalk-list] Failed schema upgrade to 2.5
Steve Kent
skent at noblesystems.com
Thu Jun 16 10:04:24 UTC 2016
I resolved the issue a few days ago by modifying
/usr/share/spacewalk/setup/defaults.d/embedded-postgresql.conf and change
from rhn to spacewalk.
I was then able to run the spacewalk-setup upgrade option.
Is there a database entry somewhere or a config file somewhere that should
be telling it to use postgresql as the database? Could that be the reason it’s
not populating rhn.conf correctly?
Steve
From: spacewalk-list-bounces at redhat.com
[mailto:spacewalk-list-bounces at redhat.com] On Behalf Of Steve Kent
Sent: Monday, June 13, 2016 5:42 AM
To: Konstantin Raskoshnyi <konrasko at gmail.com>; spacewalk-list at redhat.com
Subject: Re: [Spacewalk-list] Failed schema upgrade to 2.5
The question is why it’s using the default options when I am running
postgresql. At one point I switched from oracle to postgresql and I am not
sure if something got missed in a table or something, but all my upgrades
prior to 2.4 all worked properly, and populated the rhn.conf file with the
proper spacewalk postgresql information. When I did the upgrade from 2.3 to
2.4, that is when it stopped populating the rhn.conf correctly, and used the
default configuration. Now as I have done the 2.4 to 2.5 upgrade, I have run
into the same problem again. I would love to know why it’s not using the
spacewalk postgresql settings and choosing the defaults.
Steve
From: kraskoshnyy at gmail.com <mailto:kraskoshnyy at gmail.com>
[mailto:kraskoshnyy at gmail.com] On Behalf Of Konstantin Raskoshnyi
Sent: Friday, June 10, 2016 1:59 PM
To: Steve Kent <skent at noblesystems.com>; spacewalk-list at redhat.com
<mailto:spacewalk-list at redhat.com>
Subject: Re: [Spacewalk-list] Failed schema upgrade to 2.5
Default credentials should be these ones
db_backend = postgresql
db_user = rhnuser
db_password = rhnpw
db_name = rhnschema
I updated from 2.3 to 2.4 a couple weeks ago, everything was fine
On Fri, Jun 10, 2016 at 10:34 AM, Steve Kent <skent at noblesystems.com
<mailto:skent at noblesystems.com> > wrote:
I restored my database, tried it, and everything worked great.
Now I am back to the same issue I had from upgrading 2.3 to 2.4.
I go ahead and run "spacewalk-setup" and it fails. It fails because the
rhn.conf file is not properly created for the database settings.
I am expecting to have this in my rhn.conf file:
db_backend = postgresql
db_user = spaceuser
db_password = spacepw
db_name = spaceschema
Instead I get:
db_backend = postgresql
db_user = rhnuser
db_password = rhnpw
db_name = rhnschema
I am not sure why it's not picking up the proper spacewalk setup. Last
time I went ahead and modified the spacewalk-setup file to overwrite the
rhn.conf file after it was created. I would love to know what I am missing
or what's not configured correctly that is causing that issue. It never
happened on my upgrades prior to 2.4.
Steve
-----Original Message-----
From: Steve Kent [mailto:skent at noblesystems.com
<mailto:skent at noblesystems.com> ]
Sent: Friday, June 10, 2016 8:19 AM
To: Jan Dobes <jdobes at redhat.com <mailto:jdobes at redhat.com> >;
spacewalk-list at redhat.com <mailto:spacewalk-list at redhat.com>
Subject: RE: [Spacewalk-list] Failed schema upgrade to 2.5
Thanks. I will give it a shot.
Steve
-----Original Message-----
From: Jan Dobes [mailto:jdobes at redhat.com <mailto:jdobes at redhat.com> ]
Sent: Friday, June 10, 2016 8:06 AM
To: Steve Kent <skent at noblesystems.com <mailto:skent at noblesystems.com> >;
spacewalk-list at redhat.com <mailto:spacewalk-list at redhat.com>
Subject: Re: [Spacewalk-list] Failed schema upgrade to 2.5
The upgrade should be fixed now in spacewalk-schema-2.5.23-1.
Regards,
--
Jan Dobes
Satellite Engineering, Red Hat
On 9.6.2016 19:41 Steve Kent wrote:
> Thanks for the update!
>
> Steve
>
> -----Original Message-----
> From: Jan Dobes [mailto:jdobes at redhat.com <mailto:jdobes at redhat.com> ]
> Sent: Thursday, June 09, 2016 1:37 PM
> To: Steve Kent <skent at noblesystems.com <mailto:skent at noblesystems.com> >;
> spacewalk-list at redhat.com <mailto:spacewalk-list at redhat.com>
> Subject: Re: [Spacewalk-list] Failed schema upgrade to 2.5
>
> We know about it. It's bug in upgrades scripts which occurs when there
> are multiple organization on Spacewalk. We will try to release fixed
> spacewalk-schema package as soon as possible. Sorry for inconvenience.
>
> Regards,
> --
> Jan Dobes
> Satellite Engineering, Red Hat
>
> On 9.6.2016 18:47 Steve Kent wrote:
>> I attempted to upgrade from 2.4 to 2.5 and ran into this issue:
>>
>> clear_log_id
>>
>> --------------
>>
>> (1 row)
>>
>> psql:/var/log/spacewalk/schema-upgrade/20160609-124047-script.sql:4470:
>> ERROR: more than one row returned by a subquery used as an
>> expression
>>
>> Here is the sql statement:
>>
>> SELECT logging.clear_log_id();
>>
>> DELETE FROM rhnOrgExtGroupMapping
>>
>> WHERE server_group_id = (
>>
>> SELECT id
>>
>> FROM rhnServerGroup
>>
>> WHERE group_type = (
>>
>> SELECT id
>>
>> FROM rhnServerGroupType
>>
>> WHERE label = 'provisioning_entitled'
>>
>> )
>>
>> );
>>
>> spaceschema=# select * from rhnOrgExtGroupMapping;
>>
>> id | ext_group_id | server_group_id | created | modified
>>
>> ----+--------------+-----------------+---------+----------
>>
>> (0 rows)
>>
>> spaceschema=#
>>
>>
>>
>> Thanks,
>>
>> *Steve Kent*
>> /Director, Platform R&D/
>> *Noble Systems Corporation*
>> (o) 1.404.851.1331 x1305
>> (e)skent at noblesystems.com <mailto:skent at noblesystems.com>
>> <mailto:skent at noblesystems.com <mailto:skent at noblesystems.com> >
>> (w)www.noblesystems.com <http://www.noblesystems.com>
>> <http://www.noblesystems.com/>
>>
>>
>>
>> _______________________________________________
>> Spacewalk-list mailing list
>> Spacewalk-list at redhat.com <mailto:Spacewalk-list at redhat.com>
>> https://www.redhat.com/mailman/listinfo/spacewalk-list
_______________________________________________
Spacewalk-list mailing list
Spacewalk-list at redhat.com <mailto:Spacewalk-list at redhat.com>
https://www.redhat.com/mailman/listinfo/spacewalk-list
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://listman.redhat.com/archives/spacewalk-list/attachments/20160616/269cf803/attachment.htm>
More information about the Spacewalk-list
mailing list