" /> LCA stopped on Red Hat 7.9 server - Genesys CTI User Forum

Author Topic: LCA stopped on Red Hat 7.9 server  (Read 1369 times)

Offline rocio2020

  • Newbie
  • *
  • Posts: 12
  • Karma: 1
LCA stopped on Red Hat 7.9 server
« on: March 29, 2022, 04:22:06 PM »
Advertisement
Hello expert friend, I hope you are well, please your kind help, it happens that I have the LCA installed on a RHEL 7.9 server and when I restart the server, the LCA does not start, I have to do it manually.

Could you help me please, I need it to start automatically.

Thank you very much.

Offline hsujdik

  • Hero Member
  • *****
  • Posts: 541
  • Karma: 30
Re: LCA stopped on Red Hat 7.9 server
« Reply #1 on: March 30, 2022, 03:07:25 AM »
I have been able to achieve it through creating a systemd service:

As root:
1. create a file with the extension ".service" on /etc/systemd/system (for example, /etc/systemd/system/genesys-lca.service)

2. Insert the following on the file:

[code]

[Unit]
Description=Genesys LCA

[Service]
WorkingDirectory=/app/gcti/lca
ExecStart=/app/gcti/lca/lca $SERVICE_ARGS
Environment=SERVICE_ARGS=4999
Restart=always
RestartSec=10
KillSignal=SIGINT
SyslogIdentifier=genesys-lca
User=genesys
Group=genesys

[Install]
WantedBy=multi-user.target

[/code]
(note: on the file above, replace /app/gcti/lca with the directory where your LCA is installed in both "WorkingDirectory" and "ExecStart" lines. Also, replace User=genesys and Group=genesys with the user/group that you want LCA running as)

3. Save this file

4. run the following commands (without the # that I put on the start of each line just to indicate that it should be run as root) - please ensure that LCA is NOT running before you do this.
[code]
#systemctl daemon-reload
#systemctl --now enable genesys-lca.service
[/code]
(replace genesys-lca.service with the name of the file you created on step 1)

5. Confirm if LCA has successfully been started as Service:
[code]
#systemctl status genesys-lca.service
[/code]

If you have SELinux active (check by running "getenforce" and see if it returns "Enforcing" = enabled // or "Permissive" or "Disabled" = inactive).
If SELinux is enabled, you also need a SELinux context for your LCA to be able to run as service. If that is the case, please let me know so I can also provide the steps to create/load the SELinux module for that context.


On a side note, you can add additional "Environment=VARIABLE_NAME=VARIABLE_VALUE" on the genesys-lca.service file in case you need LCA to use specific environment variables (like LD_LIBRARY_PATH, PATH, TNS_ADMIN, etc...).

« Last Edit: March 30, 2022, 03:13:28 AM by hsujdik »

Offline rocio2020

  • Newbie
  • *
  • Posts: 12
  • Karma: 1
Re: LCA stopped on Red Hat 7.9 server
« Reply #2 on: March 30, 2022, 06:36:16 PM »
Hi hsujdik

thank you for your support, I will try to do what is described, thank you, you are a genius

Offline rocio2020

  • Newbie
  • *
  • Posts: 12
  • Karma: 1
Re: LCA stopped on Red Hat 7.9 server
« Reply #3 on: March 30, 2022, 07:33:21 PM »
It worked on the first try, thank you, you're a boss, kisses, thank you