Upgrading data from 0.5 to 0.8 Not Working
Forum » WikiPBX / Technical Support » Upgrading data from 0.5 to 0.8 Not Working
Started by: sstefflerssteffler
On: 1266513940|%e %b %Y, %H:%M %Z|agohover
Number of posts: 7
rss icon RSS: New posts
Summary:
Migration instructions not clear enough?
Upgrading data from 0.5 to 0.8 Not Working
sstefflerssteffler 1266513940|%e %b %Y, %H:%M %Z|agohover

After a lengthy difficult process upgrading my WikiPBX to 0.8, I have finally gotten the new version working with a lot of help from tleyden and stas_shtin. Thanks guys! :)

I now see the WikiPBX [ ADD ROOT ] option on the main page of WikiPBX after I load it in my browser. I click Add Root, and I fill in all the information required. I use the same info I had on my root login on the old version of WikiPBX.

I'm confused about the migration instructions from here onward. The website says "Create a sip profile if you have not done so already". Does this mean I create a SIP Profile which matches the information of the profiles from the old WikiPBX I need to import? Should I name it the same? Because I did name it the same as my old profile in WikiPBX 0.5, and it seems to work correctly to do so, with no complaints.

However, after I select the XML file I put into /tmp, and select the new profile I created, then click the Initiate Import button, it says "Import Successful" or something like that, and that I should be able to see the information in the GUI now. However, I don't see any information at all, and WikiPBX is still blank of other users (that were in the XML export) as well as blank of the stuff I imported (either as a new profile or as part of the one that I created).

Dialplan, users, etc, all seem to be blank as if they are new, without any info successfully imported. Here is what I saw in the Apache logfile during the import process (edited for privacy concerns):

[Thu Feb 18 16:55:47 2010] [notice] Apache/2.2.11 (FreeBSD) mod_ssl/2.2.11 OpenSSL/0.9.8e mod_wsgi/3.1 Python/2.5.4 PHP/5.2.9 configured -- resuming normal operations
[Thu Feb 18 16:56:54 2010] [error] restart_profiles called
[Thu Feb 18 16:56:54 2010] [error] get_fs_connections()
[Thu Feb 18 16:56:54 2010] [error] no eventsockets
[Thu Feb 18 16:56:54 2010] [error] get_fs_connections() done
[Thu Feb 18 16:57:20 2010] [error] restart_profiles called
[Thu Feb 18 16:57:20 2010] [error] get_fs_connections()
[Thu Feb 18 16:57:20 2010] [error] 1 eventsockets
[Thu Feb 18 16:57:20 2010] [error] creating eslconnection
[Thu Feb 18 16:57:58 2010] [error] Will use sip profile: sip profile: MY.IP.IS.HERE:5060
[Thu Feb 18 16:57:58 2010] [error] elt: wikipbx
[Thu Feb 18 16:57:58 2010] [error] account: <account accept_blind_reg="False" domain="" enabled="True" ext_rtp_ip="MY.IP.IS.HERE" ext_sip_ip="MY.IP.IS.HERE" name="MYPROFILENAME"/>
[Thu Feb 18 16:57:58 2010] [error] account name: MYPROFILENAME
[Thu Feb 18 16:57:58 2010] [error] Warning: no domain for profile, using name.  You will need to fix this
[Thu Feb 18 16:57:58 2010] [error] userprofile: <userprofile account="MYPROFILENAME" email="email@address.here" first_name="MyFirst" is_account_admin="False" is_active="True" is_superuser="False" last_name="MyLast" password="sha1$ENCRYPTEDSTRINGHERE"/>
[Thu Feb 18 16:57:58 2010] [error] email: email@address.here
[Thu Feb 18 16:57:58 2010] [error] account: MYPROFILENAME
[Thu Feb 18 16:57:58 2010] [error] userprofile: <userprofile account="MYPROFILENAME" email="myname@admin.account.com" first_name="ME" is_account_admin="True" is_active="True" is_superuser="False" last_name="MINE" password="sha1$ENCRYPTEDSTRINGHERE"/>
[Thu Feb 18 16:57:58 2010] [error] email: myname@admin.account.com
[Thu Feb 18 16:57:58 2010] [error] account: MYPROFILENAME
[Thu Feb 18 16:57:58 2010] [error] userprofile: <userprofile account="MYPROFILENAME" email="friend@gmail.com" first_name="FRIENDNAME" is_account_admin="True" is_active="True" is_superuser="False" last_name="LASTNAME" password="sha1$ENCRYPTEDSTRINGHERE"/>
[Thu Feb 18 16:57:58 2010] [error] email: friend@gmail.com
[Thu Feb 18 16:57:58 2010] [error] account: MYPROFILENAME
[Thu Feb 18 16:57:58 2010] [error] endpoint: <endpoint account="MYPROFILENAME" password="pass" userid="1000" userprofile="myname@admin.account.com"/>
[Thu Feb 18 16:57:58 2010] [error] account: MYPROFILENAME
[Thu Feb 18 16:57:58 2010] [error] endpoint: <endpoint account="MYPROFILENAME" password="pass" userid="USERIDHERE" userprofile="myname@admin.account.com"/>
[Thu Feb 18 16:57:58 2010] [error] account: MYPROFILENAME
[Thu Feb 18 16:57:58 2010] [error] endpoint: <endpoint account="MYPROFILENAME" password="pass" userid="USERIDHERE"/>
[Thu Feb 18 16:57:58 2010] [error] account: MYPROFILENAME
[Thu Feb 18 16:57:58 2010] [error] User matching query does not exist.
[Thu Feb 18 16:57:58 2010] [error] Got exception, rolling back
[Thu Feb 18 16:59:04 2010] [error] restart_profiles called
[Thu Feb 18 16:59:04 2010] [error] get_fs_connections()
[Thu Feb 18 16:59:04 2010] [error] 1 eventsockets
[Thu Feb 18 16:59:04 2010] [error] creating eslconnection
[Thu Feb 18 17:00:30 2010] [error] restart_profiles called
[Thu Feb 18 17:00:30 2010] [error] get_fs_connections()
[Thu Feb 18 17:00:30 2010] [error] 1 eventsockets
[Thu Feb 18 17:00:30 2010] [error] creating eslconnection
[Thu Feb 18 17:00:46 2010] [notice] caught SIGTERM, shutting down

Is there yet another glaring thing I am doing wrong here? :-) I have confirmed that the export file does in fact contain the XML from the old installation, and it is in the correct location. Furthermore, I receive no errors or complaints during the import procedure except if I turn Apache debug logging on, just blank end results. Help would be greatly appreciated.

Last edited on 1266514826|%e %b %Y, %H:%M %Z|agohover By ssteffler + Show more
Reply  |  Options
Unfold Upgrading data from 0.5 to 0.8 Not Working by sstefflerssteffler, 1266513940|%e %b %Y, %H:%M %Z|agohover
Re: Upgrading data from 0.5 to 0.8 Not Working
tleydentleyden 1266532719|%e %b %Y, %H:%M %Z|agohover

Ah … here's the key line:

Got exception, rolling back

I think we should have made that a little louder ;)

Give us credit though .. everything was done in a transaction, and so when it encountered an error, it rolled back the transaction and did NOT leave you in a half-upgraded, half-working state. Instead everything got rolled back so its as if the failed import attempt had never happened. (Why don't more coders do this?)

And thank you for posting the installation log! It's nice having smart users, sure makes our job easier. I have to say, having such a heinous installation process has such a nice side effect!

Anyway .. to get to the bottom of this error we will need to update the code to print out the detailed error message. How did you install the code?

  • 0.8 zip file
  • 0.8 branch
  • Other branch (trunk?)

Let me know and we'll go from there

Reply  |  Options
Unfold Re: Upgrading data from 0.5 to 0.8 Not Working by tleydentleyden, 1266532719|%e %b %Y, %H:%M %Z|agohover
Re: Upgrading data from 0.5 to 0.8 Not Working
tleydentleyden 1266634574|%e %b %Y, %H:%M %Z|agohover

Please switch to the 0.8 branch using these instructions: zip2branch

Then retry your test and post the log output. Hopefully from that it will be apparent.

Are there any statements that say: "looking up user with email: x" with no corresponding
statements: "creating user with email: x" (eg, user with email x was never created and so lookups fail).

The "creating user with email" statements should appear earlier in the log file

Reply  |  Options
Unfold Re: Upgrading data from 0.5 to 0.8 Not Working by tleydentleyden, 1266634574|%e %b %Y, %H:%M %Z|agohover
Re: Upgrading data from 0.5 to 0.8 Not Working
tleydentleyden 1266634628|%e %b %Y, %H:%M %Z|agohover

If you were already using the 0.8 branch, then you'll just need to svn up to r251

Reply  |  Options
Unfold Re: Upgrading data from 0.5 to 0.8 Not Working by tleydentleyden, 1266634628|%e %b %Y, %H:%M %Z|agohover
Re: Upgrading data from 0.5 to 0.8 Not Working
stefflersteffler 1267061067|%e %b %Y, %H:%M %Z|agohover

Hi again,

Sorry for the delay. I updated to svn r251 now.

Here is the new log snip. I believe it is not liking the endpoints that I have that do not have a web user associated with them. It goes through with the import and dies with the following:

[Fri Feb 19 08:38:56 2010] [error] Will use sip profile: sip profile: MY.IP.IS.HERE:5060
[Fri Feb 19 08:38:56 2010] [error] elt: wikipbx
[Fri Feb 19 08:38:56 2010] [error] account: <account accept_blind_reg="False" domain="" enabled="True" ext_rtp_ip="MY.IP.IS.HERE" ext_sip_ip="MY.IP.IS.HERE" name="MyAccountNameHere"/>
[Fri Feb 19 08:38:56 2010] [error] account name: MyAccountNameHere
[Fri Feb 19 08:38:56 2010] [error] Warning: no domain for profile, using name.  You will need to fix this
[Fri Feb 19 08:38:56 2010] [error] userprofile: <userprofile account="MyAccountNameHere" email="info@example.com" first_name="MyName" is_account_admin="False" is_active="True" is_superuser="False" last_name="MyLast" password="sha1$hashishere"/>
[Fri Feb 19 08:38:56 2010] [error] email: info@example.com
[Fri Feb 19 08:38:56 2010] [error] account: MyAccountNameHere
[Fri Feb 19 08:38:56 2010] [error] userprofile: <userprofile account="MyAccountNameHere" email="steffler@example.com" first_name="Steve" is_account_admin="True" is_active="True" is_superuser="False" last_name="Steffler" password="sha1$hashishere"/>
[Fri Feb 19 08:38:56 2010] [error] email: steffler@example.com
[Fri Feb 19 08:38:56 2010] [error] account: MyAccountNameHere
[Fri Feb 19 08:38:56 2010] [error] userprofile: <userprofile account="MyAccountNameHere" email="barry@example.com" first_name="barry" is_account_admin="True" is_active="True" is_superuser="False" last_name="kat" password="sha1$hashishere"/>
[Fri Feb 19 08:38:56 2010] [error] email: barry@example.com
[Fri Feb 19 08:38:56 2010] [error] account: MyAccountNameHere
[Fri Feb 19 08:38:56 2010] [error] endpoint: <endpoint account="MyAccountNameHere" password="pwhere" userid="1005" userprofile="steffler@example.com"/>
[Fri Feb 19 08:38:56 2010] [error] account: MyAccountNameHere
[Fri Feb 19 08:38:56 2010] [error] endpoint: <endpoint account="MyAccountNameHere" password="pwhere" userid="7805551212" userprofile="steffler@example.com"/>
[Fri Feb 19 08:38:56 2010] [error] account: MyAccountNameHere
[Fri Feb 19 08:38:56 2010] [error] endpoint: <endpoint account="MyAccountNameHere" password="pwhere" userid="4035551212" userprofile="info@example.com"/>
[Fri Feb 19 08:38:56 2010] [error] account: MyAccountNameHere
[Fri Feb 19 08:38:56 2010] [error] endpoint: <endpoint account="MyAccountNameHere" password="1234" userid="8775550199"/>
[Fri Feb 19 08:38:56 2010] [error] account: MyAccountNameHere
[Fri Feb 19 08:38:56 2010] [error] User matching query does not exist.
[Fri Feb 19 08:38:56 2010] [error] Got exception, rolling back
[Fri Feb 19 08:44:26 2010] [notice] caught SIGTERM, shutting down
Last edited on 1267061099|%e %b %Y, %H:%M %Z|agohover By steffler + Show more
Reply  |  Options
Unfold Re: Upgrading data from 0.5 to 0.8 Not Working by stefflersteffler, 1267061067|%e %b %Y, %H:%M %Z|agohover
Re: Upgrading data from 0.5 to 0.8 Not Working
tleydentleyden 1267078354|%e %b %Y, %H:%M %Z|agohover

OK it looks like the export had a bug and didn't include the userprofile attribute for one endpoint.

The easiest thing would be to delete this endpoint:

<endpoint account="MyAccountNameHere" password="1234" userid="8775550199"/>

or hack in a userprofile, eg:

<endpoint account="MyAccountNameHere" password="1234" userid="8775550199" userprofile="barry@example.com"/>

Does that fix it?

Also don't miss this warning — "Warning: no domain for profile, using name. You will need to fix this" — you should add a domain name for your account (tenant). It's possible to use the ip as the domain name, but that's discouraged.

Reply  |  Options
Unfold Re: Upgrading data from 0.5 to 0.8 Not Working by tleydentleyden, 1267078354|%e %b %Y, %H:%M %Z|agohover
Re: Upgrading data from 0.5 to 0.8 Not Working
tleydentleyden 1267123761|%e %b %Y, %H:%M %Z|agohover

you should add a domain name for your account (tenant). It's possible to use the ip as the domain name, but that's discouraged.

By the way this can/should be done after the successful import

Reply  |  Options
Unfold Re: Upgrading data from 0.5 to 0.8 Not Working by tleydentleyden, 1267123761|%e %b %Y, %H:%M %Z|agohover
New Post
page_revision: 0, last_edited: 1226259295|%e %b %Y, %H:%M %Z (%O ago)
Unless otherwise stated, the content of this page is licensed under Creative Commons Attribution-ShareAlike 3.0 License