You are not logged in.

Announcement

 Téléchargez la dernière version stable de GLPI      -     Et vous, que pouvez vous faire pour le projet GLPI ? :  Contribuer
 Download last stable version of GLPI                      -     What can you do for GLPI ? :  Contribute

#1 2023-08-31 11:01:59

Aurel44
Member
Registered: 2016-05-12
Posts: 23

[SOLVED] GLPI 10.0.9 \ ESX Remote inventory - 500 Internal Error

Hi everyone,

Since many GLPI versions, I try to execute an ESX inventory from WEB UI of glpi server but I keep getting an error :

500 Internal Server Error: \nError returned by expat parser: not well-formed (invalid token)\n\nwhile parsing serialized value of type string\nat line 7, column 33\n\nwhile parsing call information for method Login\nat line 6, column 8\n\nwhile p

When I try with the command line, it returns json file with correct data : glpi-esx --host myvcenter.mydomain.com --user myuserglpi --password mypasswordglpi --path /tmp --json

So, why with WEB UI, I keep getting this error ?

Thanks for your help.

Last edited by Aurel44 (2023-09-26 14:44:48)

Offline

#2 2023-09-25 16:23:43

aachour
Member
Registered: 2020-01-23
Posts: 10

Re: [SOLVED] GLPI 10.0.9 \ ESX Remote inventory - 500 Internal Error

Sounds like a classic case of "works in CLI, but not in the web UI", huh? Since the command line is working fine, it's probably not an issue with your credentials or ESX settings.

You might wanna check your web server logs; it could give you more details on the 500 error. Also, this could be a permissions thing. Make sure that the web server user has the right permissions to execute the glpi-esx script and write to the /tmp directory.

Offline

#3 2023-09-26 14:44:16

Aurel44
Member
Registered: 2016-05-12
Posts: 23

Re: [SOLVED] GLPI 10.0.9 \ ESX Remote inventory - 500 Internal Error

Thanks for your answer aachour !

I've checked my php logs and I saw this error :

[2023-09-26 13:48:42] glpiphplog.WARNING:   *** PHP User Warning (512): 500 Internal Server Error: \\nError returned by expat parser: not well-formed (invalid token)\\n\\nwhile parsing serialized value of type string\\nat line 7, column 33\\n\\nwhile parsing call information for method Login\\nat line 6, column 8\\n\\nwhile parsing SOAP body\\nat line 5, column 8\\n\\nwhile parsing SOAP envelope\\nat line 2, column 8\\n\\nwhile parsing HTTP request for method login\\non object of type vim.SessionManager\\nat line 1, column 0 exceed 255 characters long (458), it will be truncated. in /var/www/html/glpi/src/CommonDBTM.php at line 4285
  Backtrace :
  src/CommonDBTM.php:4285                            trigger_error()
  src/CommonDBTM.php:1289                            CommonDBTM->filterValues()
  ...ce/glpiinventory/inc/taskjobstate.class.php:399 CommonDBTM->add()
  ...piinventory/inc/communicationrest.class.php:260 PluginGlpiinventoryTaskjobstate->changeStatusFinish()
  marketplace/glpiinventory/b/esx/index.php:86       PluginGlpiinventoryCommunicationRest::updateLog()

It's the same error but a little more detailed as you said.

I've checked right on /tmp directory and it's ok : drwxrwxrwt  14 root root 4,0K 26 sept. 14:01 tmp
I've also checked right on glpi-esx script and it's ok : -rwxr-xr-x 1 root root 5,1K 21 juin  15:59 /usr/bin/glpi-esx


Is there a limitation with password's characters ?
So I've decided to try to change "mypasswordglpi" on VMWARE
AND I've found what was the problem.

It's this character : °

Don't use it with glpi-esx through WEB UI.
Since I have change my password, all run like a charm !

So, I think it will be great to add information about forbidden characters on password for glpi-esx through Web UI.

Thanks for your help aachour

Offline

Board footer

Powered by FluxBB