Mantis Bug Tracker

View Issue Details Jump to Notes ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0008875opensim[GRID] Other Servicepublic2021-03-09 13:562021-03-19 07:19
ReporterWesWorld 
Assigned To 
PrioritynormalSeverityminorReproducibilityalways
StatusnewResolutionopen 
PlatformOS 0.9.1.1Operating SystemUbuntuOperating System Version20.04
Product Version0.9.1.0 
Target VersionFixed in Version 
Summary0008875: Errors when logging client into server with groups enabled.
DescriptionI have enabled Groups V2 on my standalone hypergrid server and am able to launch OpenSim server with no issues. When I attempt to login to the server with the Firestorm OS client, I get an error on the console and the client hangs. I have put the text of the error in "Additional Information". I have masked my IP, port, and database information in the log. The table that the error is asking for is clearly missing from the database, but the instructions don't say anything about creating these tables ahead of time.
Steps To ReproduceLogin to Firestorm Viewer.
Additional Information13:50:44 - [LLUDPSERVER]: UseCircuitCode handling from endpoint {IPADDRESS]}:{PORT}, client unknown unknown failed. Exception Table '{DATABASE}.os_groups_membership' doesn't exist at MySql.Data.MySqlClient.MySqlStream.ReadPacket () [0x00096] in <0004ab8b375b422f9000ac25a68089d9>:0
  at MySql.Data.MySqlClient.NativeDriver.GetResult (System.Int32& affectedRow, System.Int64& insertedId) [0x00026] in <0004ab8b375b422f9000ac25a68089d9>:0
  at MySql.Data.MySqlClient.Driver.GetResult (System.Int32 statementId, System.Int32& affectedRows, System.Int64& insertedId) [0x00000] in <0004ab8b375b422f9000ac25a68089d9>:0
  at MySql.Data.MySqlClient.Driver.NextResult (System.Int32 statementId, System.Boolean force) [0x00023] in <0004ab8b375b422f9000ac25a68089d9>:0
  at MySql.Data.MySqlClient.MySqlDataReader.NextResult () [0x00205] in <0004ab8b375b422f9000ac25a68089d9>:0
  at MySql.Data.MySqlClient.MySqlCommand.ExecuteReader (System.Data.CommandBehavior behavior) [0x00315] in <0004ab8b375b422f9000ac25a68089d9>:0
  at MySql.Data.MySqlClient.MySqlCommand.ExecuteReader () [0x00000] in <0004ab8b375b422f9000ac25a68089d9>:0
  at (wrapper remoting-invoke-with-check) MySql.Data.MySqlClient.MySqlCommand.ExecuteReader()
  at OpenSim.Data.MySQL.MySQLGenericTableHandler`1[T].DoQueryWithConnection (MySql.Data.MySqlClient.MySqlCommand cmd, MySql.Data.MySqlClient.MySqlConnection dbcon) [0x0000d] in <e8223c686f534fcfbb8f82618e6d0c9d>:0
  at OpenSim.Data.MySQL.MySQLGenericTableHandler`1[T].DoQuery (MySql.Data.MySqlClient.MySqlCommand cmd) [0x0001a] in <e8223c686f534fcfbb8f82618e6d0c9d>:0
  at OpenSim.Data.MySQL.MySQLGenericTableHandler`1[T].Get (System.String field, System.String key) [0x0002b] in <e8223c686f534fcfbb8f82618e6d0c9d>:0
  at OpenSim.Data.MySQL.MySQLGroupsData.RetrieveMemberships (System.String pricipalID) [0x00011] in <e8223c686f534fcfbb8f82618e6d0c9d>:0
  at OpenSim.Groups.GroupsService.GetAgentGroupMemberships (System.String RequestingAgentID, System.String AgentID) [0x00006] in <c1b56a2b50564c37b2e66d012780259e>:0
  at OpenSim.Groups.GroupsServiceLocalConnectorModule.GetAgentGroupMemberships (System.String RequestingAgentID, System.String AgentID) [0x00000] in <c1b56a2b50564c37b2e66d012780259e>:0
  at OpenSim.Groups.GroupsServiceHGConnectorModule.GetAgentGroupMemberships (System.String RequestingAgentID, System.String AgentID) [0x00014] in <c1b56a2b50564c37b2e66d012780259e>:0
  at OpenSim.Groups.GroupsModule.GetMembershipData (OpenMetaverse.UUID agentID) [0x00047] in <c1b56a2b50564c37b2e66d012780259e>:0
  at OpenSim.Region.ClientStack.LindenUDP.LLClientView.RefreshGroupMembership () [0x0002a] in <c0064cecb52845b2bd2dc9b926e4e98f>:0
  at OpenSim.Region.Framework.Scenes.ScenePresence..ctor (OpenSim.Framework.IClientAPI client, OpenSim.Region.Framework.Scenes.Scene world, OpenSim.Framework.AvatarAppearance appearance, OpenSim.Framework.PresenceType type) [0x004ad] in <b8e0c941b5e14649a5e27e0125c0588c>:0
  at OpenSim.Region.Framework.Scenes.SceneGraph.CreateAndAddChildScenePresence (OpenSim.Framework.IClientAPI client, OpenSim.Framework.AvatarAppearance appearance, OpenSim.Framework.PresenceType type) [0x00000] in <b8e0c941b5e14649a5e27e0125c0588c>:0
  at OpenSim.Region.Framework.Scenes.Scene.AddNewAgent (OpenSim.Framework.IClientAPI client, OpenSim.Framework.PresenceType type) [0x000dd] in <b8e0c941b5e14649a5e27e0125c0588c>:0
  at OpenSim.Region.ClientStack.LindenUDP.LLClientView.Start () [0x0000b] in <c0064cecb52845b2bd2dc9b926e4e98f>:0
  at OpenSim.Region.ClientStack.LindenUDP.LLUDPServer.AddClient (System.UInt32 circuitCode, OpenMetaverse.UUID agentID, OpenMetaverse.UUID sessionID, System.Net.IPEndPoint remoteEndPoint, OpenSim.Framework.AuthenticateResponse sessionInfo) [0x000e5] in <c0064cecb52845b2bd2dc9b926e4e98f>:0
  at OpenSim.Region.ClientStack.LindenUDP.LLUDPServer.HandleUseCircuitCode (System.Object o) [0x00076] in <c0064cecb52845b2bd2dc9b926e4e98f>:0
TagsNo tags attached.
Git Revision or version number
Run Mode Standalone (Multiple Regions)
Physics EngineBulletSim
Script EngineXEngine
EnvironmentUnknown
Mono Version6.x
ViewerFirestorm OS 6.4.12.62831
Attached Files? file icon OpenSim.ini [^] (61,179 bytes) 2021-03-09 14:59
? file icon StandaloneCommon.ini [^] (17,621 bytes) 2021-03-09 14:59

- Relationships

-  Notes
(0037615)
tampa (reporter)
2021-03-09 14:15
edited on: 2021-03-09 14:16

Exception Table '{DATABASE}.os_groups_membership' doesn't exist at

You misconfigured the database connection to it, reading errors usually state what's wrong :)

Set the database connection parameters properly and the tables will be created via migrations, if you added it later you may have to manually add them, the migrations are available in source, you can run them as queries in the database server.

(0037616)
WesWorld (reporter)
2021-03-09 14:44

Thanks for your reply. I obviously read the error, otherwise I couldn't have told you in my original comment that the table doesn't exist. ;) As I said previously, I have looked in the database and that table is not there. The program connects to the database as there are no errors on startup of the server and other tables are present. I never created the table in question and the documentation never called for it.
(0037617)
WesWorld (reporter)
2021-03-09 15:01

I have attached versions of my OpenSim.ini and StandaloneCommon.ini for your review to determine if I have misconfigured my database connection. I have replaced IP's, ports, db names, etc. with generic text.
(0037618)
WesWorld (reporter)
2021-03-09 15:05

Wait, I notice you said "migrations", but I'm not migrating from any other version. I have never had groups installed before and this is a new installation. What am I migrating from?
(0037619)
WesWorld (reporter)
2021-03-09 15:57

So as an experiment, I created a database using the XmlRpcGroups instructions and then tried using the migration queries to copy to the main database, but as expected, this did not work as the tables do not exist in my main database. So obviously the issue is that the tables need to be created in my database and that the instructions don't say anywhere how to do that or what character set should be used.
(0037620)
BillBlight (developer)
2021-03-09 17:16
edited on: 2021-03-09 17:18

migrations is simply the term used when creating/updating the DB tables ..

It is kind of a known issue if your mysql collation is not mb3 the migration may fail to create that table.

You can attempt to create that table with the following sql query ..

CREATE TABLE os_groups_membership(
  GroupID char(36) NOT NULL DEFAULT '',
  PrincipalID VARCHAR(255) NOT NULL default '',
  SelectedRoleID char(36) NOT NULL default '',
  Contribution int(11) NOT NULL default '0',
  ListInProfile int(4) NOT NULL default '1',
  AcceptNotices int(4) NOT NULL default '1',
  AccessToken char(36) NOT NULL default '',
  PRIMARY KEY (GroupID,PrincipalID),
  KEY PrincipalID (PrincipalID)
)ENGINE=InnoDB DEFAULT CHARSET=latin1;

(0037621)
WesWorld (reporter)
2021-03-09 17:46

Thank you again for the reply. I am going to ask a few questions and make a few comments because I am going to be updating the existing documentation, which is currently incomplete and misleading in some cases.
1) So there was never a problem with my database connection configuration. The problem was that the database tables were never created. The documentation makes no mention of this. Even the migration script will not work, because it requires the tables to exist for it to work.
2) Above, Tampa said "if you added it later you may have to manually add them,". Is this true? I understand this to mean that if you enable groups after your first run, the tables will not be created. If so I will add this to the documentation. The way the documentation currently reads is that Groups should be enabled AFTER your first run, so something should be included instructing users how to create the necessary tables if they do not exist or were not created. I can supply all of that as I am writing queries to create all of the tables right now to get my installation to work.
3) Using the term migration to refer to new installations or database creations is misleading. That terminology should be dropped in favor of something that obviously refers to a new installation. Again. I will include that in my update of the documentation.
4) Does the V2 groups page assume you are using MySQl/ MariaDB or will the Flotsam migration script work with other database types? Should documentation be included for the other supported database types as well?
(0037622)
WesWorld (reporter)
2021-03-09 17:58

Also, I believe you have syntax errors in the SQL query you posted.
(0037623)
BillBlight (developer)
2021-03-09 18:01

The term migration is universally used so you don't use two separate terms/commands for creation and migration, would just add something that is not actually needed. So not sure what to tell you, it is not a hard thing to wrap your head around, migrating from nothing to something.

Well the issue of not creating the table, is only present with NEWER versions of mysql/MariaDB, because they changed their default collation, so no not added yet.

Yes it assumes you are using MySQL/MariaDB, the syntax is so.


The DB's should be created if you enable the internal module at a later date, but again with newer mysql and their default collation, also from the wiki concerning MariaDB,

"MariaDB (fully supported) - A compatible alternative to MySQL. You need to make sure the selected charset is utf8mb3 (ie 3 bytes). Some installations default to uft8mb4 (4 bytes) and that will fail"
(0037624)
BillBlight (developer)
2021-03-09 18:01
edited on: 2021-03-09 18:03

I ran the query against my DB it ran fine ...

Might try it this way ..

CREATE TABLE os_groups_membership(
  GroupID char(36) NOT NULL DEFAULT '',
  PrincipalID VARCHAR(255) NOT NULL default '',
  SelectedRoleID char(36) NOT NULL default '',
  Contribution int(11) NOT NULL default '0',
  ListInProfile int(4) NOT NULL default '1',
  AcceptNotices int(4) NOT NULL default '1',
  AccessToken char(36) NOT NULL default '',
  PRIMARY KEY (GroupID,PrincipalID),
  KEY PrincipalID (PrincipalID)
);

Also I ran it from phpmyadmin not command line , so you would have to adjust the query if running it from command line.

(0037625)
WesWorld (reporter)
2021-03-09 18:17
edited on: 2021-03-09 18:23

I'm not going to argue this point with you, but in my 20+ years in IT, I have NEVER heard the term migration used for a NEW database and either way, it's misleading for the DOCUMENTATION to refer to it that way.

Also from the wiki: http://opensimulator.org/wiki/Database_Settings [^]
MySQL must be configured to use UTF8 as its default character set. In the config file /etc/my.cnf (Linux) or my.ini (Windows), add these settings:

 [mysqld]
 character-set-server=utf8

 [client]
 default-character-set=utf8

It doesn't specifically mention utf8mb3 there which is misleading.

"Well the issue of not creating the table, is only present with NEWER versions of mysql/MariaDB, because they changed their default collation, so no not added yet." Why would anyone be using older versions? Shouldn't the documentation assume they are using newer versions?

"Yes it assumes you are using MySQL/MariaDB, the syntax is so." It doesn't specifically say so. Should language be included for the other supported database types?

(0037626)
WesWorld (reporter)
2021-03-09 18:22

It looks like it would be easier to dig my eyeballs out than to convert all of my existing tables to utf8mb3. Can I get by simply by ensuring all of the Groups V2 tables are latin1 when I create them manually?
(0037627)
UbitUmarov (administrator)
2021-03-10 01:50

Every thing changes with time, including software "standards"

- MySql defined uft8 as 3 bytes only.
- A lot of opensim base code was made for MySql of the day.

then others said No, it is 4 bytes (and that possible when is was actually 6 bytes).
So fanatic tech religion linux distributions maintainers forced 4 bytes, when the default was compatibility 3 bytes. (yes same stupid fanatics that did not allow nvidia drivers to install bc they where not openbugssource)

with that..
PrincipalID VARCHAR(255) NOT NULL default '',
...

PRIMARY KEY (GroupID,PrincipalID),
  KEY PrincipalID (PrincipalID)
will just blowup with the rest of the DB engine defaults, at least same versions.

meanwhile that particular table SHOULD work fine on 0.9.2, even with utf8mb4, since it does spec single byte latin1.
(0037628)
WesWorld (reporter)
2021-03-10 07:14

Sorry, I'm unclear what you are saying. Are you saying that I will be okay without converting my ENTIRE main 0.9.1.1 database to utf8mb3 as long as I use latin for the groups tables?

"with that..
PrincipalID VARCHAR(255) NOT NULL default '',
...

PRIMARY KEY (GroupID,PrincipalID),
  KEY PrincipalID (PrincipalID)
will just blowup with the rest of the DB engine defaults, at least same versions.

meanwhile that particular table SHOULD work fine on 0.9.2, even with utf8mb4, since it does spec single byte latin1."
(0037629)
UbitUmarov (administrator)
2021-03-10 07:36

0.9.1.1 spec is to use original mysql, that means its original utf8 type (that was also mariaDB default on its original code)

The correct fix is change the definition of the tables to the correct types
Most char columns are and always will be, plain ASCII (like uuid strings, for example)
That was we started on 0.9.2 (hopefully did)

At least until those fanatics don't remove all charsets other than unicode.
(0037630)
WesWorld (reporter)
2021-03-10 07:52

Dang. I think I may just blow the whole thing out and start over then. I just reinstalled and it's easier than trying to convert each table. This way I can also test whether the Groups V2 tables generate automatically as well. Thanks again for your replies.
(0037631)
WesWorld (reporter)
2021-03-10 12:48

Thanks again for your help on this. I wiped out my installation and databases and reinstalled OpenSim. I ensured that the default character set for MariaDB was UTF8 and recreated my main database. I performed an initial run to create the main tables and then enable the Groups V2 module and ran it again. All of the correct tables were created with no issue. I appreciate all of your replies.
(0037633)
Manni (reporter)
2021-03-11 05:15
edited on: 2021-03-11 05:40

Ubuntu Server 18:
Standard latin1_swedish_ci (I've been using this since the beginning and have no problems.)
Choices Ubuntu Server 18 mysql:
uft8
uft8mb4

utf8mb3 ?

Error: Groups of no longer existing grids cannot be deleted.

http://opensimulator.org/wiki/V2_Groups [^] wiki is out of date.

(0037678)
WesWorld (reporter)
2021-03-19 07:19

Hey Manni. I'm working on updating the documentation. utf8 = utf8mb3. Some newer versions of MySQL ship with utf8mb4 as the default.

- Issue History
Date Modified Username Field Change
2021-03-09 13:56 WesWorld New Issue
2021-03-09 14:15 tampa Note Added: 0037615
2021-03-09 14:16 tampa Note Edited: 0037615 View Revisions
2021-03-09 14:44 WesWorld Note Added: 0037616
2021-03-09 14:59 WesWorld File Added: OpenSim.ini
2021-03-09 14:59 WesWorld File Added: StandaloneCommon.ini
2021-03-09 15:01 WesWorld Note Added: 0037617
2021-03-09 15:05 WesWorld Note Added: 0037618
2021-03-09 15:57 WesWorld Note Added: 0037619
2021-03-09 17:16 BillBlight Note Added: 0037620
2021-03-09 17:18 BillBlight Note Edited: 0037620 View Revisions
2021-03-09 17:46 WesWorld Note Added: 0037621
2021-03-09 17:58 WesWorld Note Added: 0037622
2021-03-09 18:01 BillBlight Note Added: 0037623
2021-03-09 18:01 BillBlight Note Added: 0037624
2021-03-09 18:03 BillBlight Note Edited: 0037624 View Revisions
2021-03-09 18:17 WesWorld Note Added: 0037625
2021-03-09 18:22 WesWorld Note Added: 0037626
2021-03-09 18:23 WesWorld Note Edited: 0037625 View Revisions
2021-03-10 01:50 UbitUmarov Note Added: 0037627
2021-03-10 07:14 WesWorld Note Added: 0037628
2021-03-10 07:36 UbitUmarov Note Added: 0037629
2021-03-10 07:52 WesWorld Note Added: 0037630
2021-03-10 12:48 WesWorld Note Added: 0037631
2021-03-11 05:15 Manni Note Added: 0037633
2021-03-11 05:31 Manni Note Edited: 0037633 View Revisions
2021-03-11 05:40 Manni Note Edited: 0037633 View Revisions
2021-03-19 07:19 WesWorld Note Added: 0037678


Copyright © 2000 - 2012 MantisBT Group
Powered by Mantis Bugtracker