Hello Xiaomin
1 - We had the same issue, at CEA when we use systemctl to start alarm server as a service.
The reason was that the environment variable such as $EPICS_CA_ADDR_LIST is not defined when the service is started.
So we solve the problem in calling source /etc/bashrc to set all the variable environment.
2 – Phoebus client only know Kafka server, on there is no connexion betwenn phoebus alarm service and Phoebus client.
You have to check that Kafka is running on server side.
>> systemctl status kafka
I hope it will help you.
Katy
De : Tech-talk <tech-talk-bounces at aps.anl.gov>
De la part de ??? via Tech-talk
Envoyé : jeudi 16 novembre 2023 08:23
À : tech-talk at aps.anl.gov
Objet : Alarms.services in Phoebus Alarms
Hi,
I'm having a problem with alarm-servers. I've attached the error. Phoebus shows normal when I execute the ./alarm-server.sh
directly in the terminal, but it shows ‘No Alarm Server Connection’ when I use the alarms.service file for autostart. At the same time, I find it strange that the alarm config file can be imported successfully. It seems that the alarm-server can connect to
Phoebus, but PV cannot. The PV data is incorrect, and what is the reason for this?
The alarms.server file is as follows:
[Unit]
After=network.target kafka.target
Requires=zookeeper.service
Requires=kafka.service
[Service]
User=sysadmin
Type=simple
ExecStart=/opt/alarm/phoebus/services/alarm-server/alarm-service.sh -settings /opt/alarm/phoebus/services/alarm-server/settings.ini
WorkingDirectory=/opt/alarm/phoebus/services/alarm-server/
RemainAfterExit=true
[Install]
WantedBy=multi-user.target
![](pngem0JXQt0QK.png)
Thanks,
xiaomin