InfotelGLPI / accounts

Plugin accounts for GLPI
http://blogglpi.infotel.com
GNU General Public License v2.0
21 stars 15 forks source link

Link between database and account #101

Open naif0s opened 9 months ago

naif0s commented 9 months ago

3.0.3

GLPI 10.0.11

In GLPI 9.5.x . It have a link between database and account like this :

screen1glpi

After migration, i don't have the account :

screen2glpi

Here's how I did the migration:

I installed a GLPI from strach and imported the database, then I used the migration wizard. I exported the table structure to see the differences. Here's an example:

screenglpi3

The data inside the tables are the same

naif0s commented 9 months ago

MAJ : After extensive research on the subject, Here's my conclusion :

You would need to deploy a migration procedure like the database plugin.

First of all, I started by looking at the request via the GLPI debug mod. Here's what I got:

SELECT COUNT(*) AS cpt FROMglpi_plugin_accounts_accounts_itemsWHEREitemtype= 'DatabaseInstance' ANDitems_id= '1'

This makes a query where itemtype is = DatabaseInstance. The problem is that DatabaseInstance is the new plugin integrated into GLPI 10, Because if you migrate from glpi 9.5.x > 10, the databases are migrated to the database instance.

So I decided to make a diff of the "glpi_plugin_accounts_items" table between the GLPI 9.5.x and 10.0.11 database.

image

left glpi 9.5 and right glpi 10

So this has the wrong name. I ran a query to change all the names in the "itemtype" column of the "glpi_plugin_accounts_items" table in DatabaseInstance

I ran a diff between the two again and the IDs didn't move.

image

Then I wanted to check it out. The link is good, but the problem is that they're not the same. It's all mixed up. I have several databases with accounts that have nothing to do with the one requested. Not the same password and it's the same for applicatif, the ids have been lost

Basic IDs were lost during migration. This is blocking my complete migration to GLPI 10. So I have to wait for this to be fixed.

PS : Also just to check I'm right, I installed a GLPI from scratch and install the account plugin and here's the result. We have "DatabaseInstance" as itemtype name

image

naif0s commented 3 months ago

?