Mantis Bug Tracker

View Issue Details Jump to Notes ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0007344opensim[GRID] Robust Serverpublic2014-10-08 02:282015-08-18 09:34
ReporterGavin Hird 
Assigned ToBlueWall 
PrioritynormalSeveritymajorReproducibilityalways
StatusclosedResolutionfixed 
PlatformOSOS Version
Product Versionmaster (dev code) 
Target VersionFixed in Version0.8.1-rc2 
Summary0007344: Error loading profile data with PGSQL for UserProfilesData in Robust
DescriptionWhen configuring the PGSL data connection method for Robust, it fails to load Profile data with the error message logged on the Robust console:

DEBUG - OpenSim.Data.PGSQL.UserProfilesData [PROFILES_DATA]: No data for 97d02b42-9119-4708-804e-4c7d699162ae
DEBUG - OpenSim.Data.PGSQL.UserProfilesData [PROFILES_DATA]: Requst properties exception ERROR: 42703: column "profilepartner" of relation "userprofile" does not exist

The following is logged on the OpenSim console:

2014-10-08 10:58:26,015 DEBUG - OpenSim.Framework.Servers.HttpServer.JsonRpcRequestManager JsonRpc request 'avatar_properties_request' to http://grid.xmir.org:8002 [^] returned an error: {"code":-32604,"message":"ERROR: 42703: column \"profilepartner\" of relation \"userprofile\" does not exist"}
2014-10-08 10:58:26,016 DEBUG - OpenSim.Region.CoreModules.Avatar.UserProfiles.UserProfileModule Error getting profile for 97d02b42-9119-4708-804e-4c7d699162ae: JsonRpcRequest to http://grid.xmir.org:8002 [^] failed
Steps To Reproduce1. Configure a postgres database with the PGSL data connection in Robust.HG.ini
2. Log on with a viewer and request the avatar profile, and fails to load the data. Singularity / Replex / Cool VL viewer will present a blank profile for everything but the groups, avatar name and key. The OK button is dimmed.

The error message are logged on the Robust and OpenSim consoles and in the Robust.log and OpenSim.log files.
Additional InformationIt can temporarily be circumvented by configuring a separate (MySQL) database in the [UserProfilesService] section of Robust.HG.ini

For this to work, an additional configuration line must be added to this section to override the PGSQL connector selected:

StorageProvider = "OpenSim.Data.MySQL.dll"
ConnectionString = "Data Source=hostname;Database=profiledb;User ID=opensim;Password=***;Old Guids=true;"
TagsNo tags attached.
Git Revision or version number
Run Mode Grid (Multiple Regions per Sim)
Physics EngineODE
EnvironmentMono / OSX
Mono Version3.6
Viewer
Attached Files

- Relationships
related to 0007398closedorenh PGSQL module - typecasting issues 

-  Notes
(0027021)
Gavin Hird (reporter)
2014-11-25 03:00
edited on: 2014-11-25 03:02

I think you have fixed this in commits 25465 and 25466 as I pulled the fixes and reconfigured Robust.HG.ini to now use the PostgreSQL database.

The database migration failed with errors, but I found where it erred so you would want to fix this in the code. After I manually fixed the database tables everything runs fine.

This line:

ALTER TABLE classifieds ADD CONSTRAINT classifiedspk PRIMARY KEY (classifieduuid); should be
ALTER TABLE classifieds ADD CONSTRAINT classifieds PRIMARY KEY (classifieduuid);

This line (which is duplicated):

ALTER TABLE userpicks ALTER COLUMN parceluuid SET DATA TYPE uuid USING parceluuid::uuid; should be
ALTER TABLE userpicks ALTER COLUMN snapshotuuid SET DATA TYPE uuid USING snapshotuuid::uuid;


The error it produced is this:

Cmd was ERROR: 42704: constraint "classifiedspk" of relation "classifieds" does not exist in SQL:
 BEGIN;
 -- Classifieds ALTER TABLE classifieds DROP CONSTRAINT classifiedspk;
 ALTER TABLE classifieds ALTER COLUMN classifieduuid SET DATA TYPE uuid using classifieduuid::uuid;
 ALTER TABLE classifieds ALTER COLUMN creatoruuid SETDATA TYPE uuid using creatoruuid::uuid;
 ALTER TABLE classifieds ALTER COLUMN parceluuid SET DATA TYPE uuid using parceluuid::uuid;
 ALTER TABLE classifieds ALTER COLUMN snapshotuuid SET DATA TYPE uuid using snapshotuuid::uuid;
 ALTER TABLE classifieds ADD CONSTRAINT classifiedspk PRIMARY KEY (classifieduuid);
 -- Notes ALTER TABLE usernotes DROP CONSTRAINT usernoteuk;
 ALTER TABLE usernotes ALTER COLUMN useruuid SET DATA TYPE uuid USING useruuid::uuid;
 ALTER TABLE usernotes ALTER COLUMN targetuuid SET DATA TYPE uuid USING targetuuid::uuid;
 ALTER TABLE usernotes ADD CONSTRAINT usernoteuk UNIQUE (useruuid,targetuuid);
 -- Userpicks ALTER TABLE userpicks DROP CONSTRAINT userpicks_pkey;
 ALTER TABLE userpicks ALTER COLUMN pickuuid SET DATA TYPE uuid USING pickuuid::uuid;
 ALTER TABLE userpicks ALTER COLUMN creatoruuid SET DATA TYPE uuid USING creatoruuid::uuid;
 ALTER TABLE userpicks ALTER COLUMN parceluuid SET DATA TYPE uuid USING parceluuid::uuid;
 ALTER TABLE userpicks ALTER COLUMN parceluuid SET DATA TYPE uuid USING parceluuid::uuid;
 ALTER TABLE userpicks ADD PRIMARY KEY (pickuuid);
 -- Userprofile ALTER TABLE userprofile DROP CONSTRAINT userprofile_pkey;
 ALTER TABLE userprofile ALTER COLUMN useruuid SET DATA TYPE uuid USING useruuid::uuid;
 ALTER TABLE userprofile ALTER COLUMN "profilePartner" SET DATA TYPE uuid USING "profilePartner"::uuid;
 -- Force column conversions ALTER TABLE userprofile ALTER COLUMN "profileAllowPublish" SET DATA TYPE boolean USING CASE WHEN false THEN false ELSE true END;
 ALTER TABLE userprofile ALTER COLUMN "profileMaturePublish" SET DATA TYPE boolean USING CASE WHEN false THEN false ELSE true END;
 ALTER TABLE userprofile ALTER COLUMN "profileImage" SET DATA TYPE uuid USING "profileImage"::uuid;
 ALTER TABLE userprofile ALTER COLUMN "profileFirstImage" SET DATA TYPE uuid USING "profileFirstImage"::uuid;
 ALTER TABLE userprofile ADD PRIMARY KEY (useruuid);
 -- Userdata ALTER TABLE userdata DROP CONSTRAINT userdata_pkey;
 ALTER TABLE userdata ALTER COLUMN "UserId" SET DATA TYPE uuid USING "UserId"::uuid;
 ALTER TABLE userdata ALTER COLUMN "UserId" SET DATA TYPE uuid USING "UserId"::uuid;
 ALTER TABLE userdata ADD PRIMARY KEY ("UserId","TagId");
 -- Usersettings ALTER TABLE usersettings DROP CONSTRAINT usersettings_pkey;
 ALTER TABLE usersettings ALTER COLUMN useruuid SET DATA TYPE uuid USING useruuid::uuid;
 ALTER TABLE usersettings ALTER COLUMN visible SET DATA TYPE boolean USING CASE WHEN false THEN false ELSE true END;
 ALTER TABLE usersettings ADD COLUMN email varchar(254) NOT NULL;
 ALTER TABLE usersettings ADD PRIMARY KEY (useruuid);
 COMMIT;
 
2014-11-25 10:15:49,293 DEBUG - OpenSim.Data.Migration [MIGRATIONS]: An error has occurred in the migration. If you're running OpenSim for the first time then you can probably safely ignore this, since certain migration commands attempt to fetch data out of old tables. However, if you're using an existing database and you see database related errors while running OpenSim then you will need to fix these problems manually.

(0027022)
Gavin Hird (reporter)
2014-11-25 04:25

It also now logs the following error when pulling up the viewer preferences dialog in any viewer. This is logged in Robust.log

13:23:09 - [PROFILES_DATA]: AgentInterestsUpdate exception Argument cannot be null.
Parameter name: obj
13:23:09 - [PROFILES_DATA]: Get preferences exception Cannot cast from source type to destination type.
(0028803)
Gavin Hird (reporter)
2015-06-25 03:38

The remaining issue is described in 7398, so will address the specifics there. Closing this one as resolved.
(0029213)
aiaustin (developer)
2015-08-18 09:34

Resolved issue marked as closed. Please open a new issue and refer to this one if problems arise.

- Issue History
Date Modified Username Field Change
2014-10-08 02:28 Gavin Hird New Issue
2014-10-08 03:40 BlueWall Assigned To => BlueWall
2014-10-08 03:40 BlueWall Status new => assigned
2014-11-25 03:00 Gavin Hird Note Added: 0027021
2014-11-25 03:02 Gavin Hird Note Edited: 0027021 View Revisions
2014-11-25 04:25 Gavin Hird Note Added: 0027022
2015-06-25 03:37 Gavin Hird Relationship added related to 0007398
2015-06-25 03:38 Gavin Hird Note Added: 0028803
2015-06-25 03:38 Gavin Hird Status assigned => resolved
2015-06-25 03:38 Gavin Hird Fixed in Version => 0.8.1-rc2
2015-06-25 03:38 Gavin Hird Resolution open => fixed
2015-08-18 09:34 aiaustin Note Added: 0029213
2015-08-18 09:34 aiaustin Status resolved => closed


Copyright © 2000 - 2012 MantisBT Group
Powered by Mantis Bugtracker