Plateforme
RedHat Linux 9.5
ArcGIS Monitor 2024.1.1
Problème
ArcGIS Monitor 2024.1.1 - Échec de la récupération des informations de licence
Description
Je peux installer monitor sans aucun problème.
su - root
--installer le logiciel en mode silencieux
cd /data/installers/monitor/Monitor_Server_rpm
./ArcGIS-Monitor-server-2024.1.1.704-rpm.bin -l yes --nox11
Ensuite, je peux autoriser monitor. Voir la documentation pour "Autoriser Monitor Server en mode silencieux".
https://doc.arcgis.com/en/monitor/latest/install/linux/authorize-arcgis-monitor-server.htm
su - root
# /usr/lib/arcgis/monitor/server/tools/authorizeSoftware
-f /data/installers/license/Monitor.ecp
Je peux vérifier que la licence est correcte.
Je peux terminer la configuration de monitor.
su - root
--créer le compte administrateur initial
# /usr/lib/arcgis/monitor/server/bin/arcgis-monitor-server
admin:security:users:add --username agsmonadmin --password "*****"
--name-first AGSMON --name-last ADMIN --email alertmon@acme.com --role admin
--connecter Monitor Server au référentiel de base de données
# /usr/lib/arcgis/monitor/server/bin/arcgis-monitor-server admin:database:register
--address mondbpg.acme.com:5432 --database agsmondb2
--username agmon --password "*******" --encrypt false
# systemctl status arcgis-monitor-server
Je peux ensuite me connecter à l'URL de monitor
https://PS026033:30443/arcgis/monitor
Mais un message d'avertissement continue d'apparaître"Échec de la récupération des informations de licence"
Dépannage
Les journaux d'ArcGIS Monitor affichent le message"installdir n'existe pas".
J'aiactivé le niveau de journalisation en mode débogage dans ArcGIS Monitor et essayé de rafraîchir la licence depuis l'application web Monitor.
J'ai obtenu quelques messages supplémentaires qui m'ont aidé à cerner le problème.
"Vérification de la licence 240 à /usr/lib/arcgis/monitor/server/framework/ESRI/License24.0"
Cause du problème
Le service ArcGIS Monitor s'exécute sous l'utilisateur "arcgis".
Par conséquent, l'utilisateur "arcgis" doit posséder le fichier/usr/lib/arcgis/monitor/server/framework/ESRI/License24.0/sysgen/keycodes.
Mais lorsque nous autorisons, nous utilisons le compte root, car l'utilisateur "arcgis'est un compte de service uniquement pour exécuter le service arcgis-monitor-server, et nous ne pouvons pas nous connecter en tant qu'utilisateur "arcgis.
su - root
/usr/lib/arcgis/monitor/server/tools/authorizeSoftware
-f /data/installers/license/Monitor.ecp
Par conséquent, tout le dossier "framework" et ses sous-dossiers sont possédés par root:root.
Therefore the "arcgis" user could not read the "keycodes" file.
Workaround
The workaround was quite simple.
I changed the owner of the "framework" folder and subfoders and files to be arcgis:arcgis.
su - root
chown -R arcgis:arcgis /usr/lib/arcgis/monitor/server/framework
Now, ArcGIS Monitor can validate the license just fine.
The "arcgis" user is the service account, we cannot log in as "arcgis" user, but we can run the authorization tool as "arcgis" using "sudo -u arcgis"
su - root
# sudo -u arcgis /usr/lib/arcgis/monitor/server/tools/authorizeSoftware
-f /data/installers/license/Monitor.ecp
I hope this helps if you encounter the same issue.