[Spce-user] Errror while upgrading from mr4.5.3 to mr5.5.2

Alex Lutay alutay at sipwise.com
Thu Jan 25 06:13:55 EST 2018


Hi,

First of all you should not share the sensitive content of constants.yml
(you have just shared your DB passwords with Internet).
You have better change them and sync with DB using ngcp-sync-constants
(or just apply new configuration: ngcpcfg apply 'changed passwords' ).

For sure there can be some undiscovered issue somewhere,
lets try to localize it. I have just checked clean mr5.5.2 CE vagrant VM
and both users are in DB there. You can repeat my test using manual:
> https://www.sipwise.org/doc/mr5.5.2/spce/ar01s03.html#_vagrant_box_for_virtualbox


Can you please share the content of /etc/sipwise_ngcp_version
it will show us the VM life path (when it was installed, where it was
upgraded to and when).

You can check the consistency of YML files executing:
> ngcpcfg --validate check
It should report no errors.

In a validation template I see both marked as mandatory:
/usr/share/ngcp-cfg-schema/validate/constants.yml
>          "rtcengine":
>              type: map
>              required: yes
>              mapping:
>               "u": { type: text, required: yes }
>               "p": { type: text, required: yes }
>          "rtpengine":
>              type: map
>              required: yes
>              mapping:
>               "u": { type: text, required: yes }
>               "p": { type: text, required: yes }

If you have some issues with configuration you should address them.

Also 'ngcp-status' might share some auto-detected issues with you.

On 01/24/2018 10:58 PM, Raúl Alexis Betancor Santana wrote:
> If both users must exist ... then there are a bug elsewhere ...
> 
> MariaDB [(none)]> select Host , User from mysql.user where User like '%engine';
> +-----------+-----------+
> | Host      | User      |
> +-----------+-----------+
> | localhost | rtpengine |
> +-----------+-----------+
> 1 row in set (0.00 sec)
> 
> I did not created any grants or users ... just run ngcp-upgrade, than it stops where I told.
> 
> Whoe constants.yml should look like ? ...
> 
> [...]
> mysql:
>     asterisk:
>       p: qwrssbnAdrrMcyoyLg4C
>       u: asterisk
>     cdrexport:
>       p: AUTnuv4y7AmRdYhcRJ7x
>       u: exporter
>     checktools:
>       p: hfgdqnu47EhHdxCgVWfE
>       u: nagios
>     cleanuptools:
>       p: WAzfabycjnHFrCg7bXCC
>       u: dbcleaner
>     debian:
>       p: erAAaB0oMoOSEvxQ
>       u: debian-sys-maint
>     fileshare:
>       p: prp3nEozpecw7JqwPmaH
>       u: fileshare
>     kamailio:
>       p: MMLyTk39jWn7CvhmMExE
>       u: kamailio
>     kamailioro:
>       p: sKMeARwN7a9sejpLcNeo
>       u: kamailioro
>     ldap:
>       p: jkXXmjYT3XkyvNUgumJp
>       u: ldap
>     mediator:
>       p: nw4hzLjwrstPtoUsxjpN
>       u: mediator
>     prosody:
>       p: nriaWcKFPrp4JmKEo4rv
>       u: prosody
>     provisioning:
>       p: KPqeCapEuVEja4VgU9UE
>       u: soap
>     rateomat:
>       p: vfRiHfTzCnR9eqavryed
>       u: rateomat
>     replicator:
>       p: vtyWeAfugHkPqPzC39Tc
>       u: replicator
>     rsyslog:
>       p: VV4opnyfmMAbUFJkHpC7
>       u: rsyslog
>     rtpengine:
>       p: Ptcsi9JgH7ug4aANEPhV
>       u: rtpengine
>     sems:
>       p: XknajiJLqqF4vJVKYoWx
>       u: sems_prepaid
>     voisniff:
>       p: gnJruwHPytowiR7taRxR
>       u: visniff
> [...]
> 
> I changed rtcengine by rtpengine there
> 
> ----- Mensaje original -----
>> De: "Alex Lutay" <alutay at sipwise.com>
>> Para: spce-user at lists.sipwise.com
>> Enviados: Miércoles, 24 de Enero 2018 11:13:37
>> Asunto: Re: [Spce-user] Errror while upgrading from mr4.5.3 to mr5.5.2
> 
>> Hi,
>>
>> I am strongly believe you are right. You must have both users (since
>> they are for the different component):
>>
>>> MariaDB [mysql]> select Host , User from user where User like '%engine';
>>> +-----------+-----------+
>>> | Host      | User      |
>>> +-----------+-----------+
>>> | localhost | rtcengine |
>>> | localhost | rtpengine |
>>> +-----------+-----------+
>>> 2 rows in set (0.00 sec)
>>
>> When you restore 'rtpengine' you have to check and re-execute
>> '15324.up', I believe the necessary part is only:
>>
>>> grant all on provisioning.recording_calls to 'rtpengine'@'localhost';
>>> grant all on provisioning.recording_streams to 'rtpengine'@'localhost';
>>
>> and remove unnecessary grants from 'rtCengine' you have created.
>>
>> When you finish, repeat: ngcpcfg apply "reapplying to sync rtPengine"
>>
>> On 01/23/2018 01:05 PM, Raúl Alexis Betancor Santana wrote:
>>> Blaming that rtpengine user was not found on the user mysql table ... I
>>> checked and thats whats true, the user there was rtCengine, so I
>>> upgraded the user table, deleted the 2 recording related tables, fixed
>>> the constans.yml file that also points to rtcengine user and run
>>> ngcp-upgrade again ... it continues till the mentioned error about the
>>> grants/credentials ... that I have the feeling that its related to that
>>> previous error.

-- 
Alex Lutay



More information about the Spce-user mailing list