It's all about the answers!

Ask a question

How to auto-start CLM(Jazz) on RHEL7?

Masatoshi Nogo (524) | asked Dec 04 '16, 9:38 p.m.
I tried to search articles but couldn't find. Please help.
I'm struggling to start Jazz on RHEL7 which support systemd.

Followings are what I tried.
1.1.Create new file, named clm.service with following contents
Description = CLM Server

ExecStart = /opt/IBM/JazzTeamServer/server/server.startup

Restart = always
Type = simple

WantedBy =
As root,
# systemctl enable clm
# systemctl start clm

Then, CLM service started, but could connect from Web browser (login window not shown)
  - Trial of OS reboot resulted same
  - If I type start command manually with root user, CLM started correctly.
       # ./server.startup

I added following lines to the end of server.startup
echo JAVA_OPTS=$JAVA_OPTS > /tmp/test.txt
echo CATALINA_HOME=$CATALINA_HOME >> /tmp/test.txt

As result diff of manual command(./server.startup) and auto-start (systemctl start clm) , environments were same.

Accepted answer

permanent link
Donald Nong (14.5k414) | answered Dec 08 '16, 4:38 a.m.
You should use "Type=forking" in the unit file, as explained in the Red Hat document.
forking – The process started with ExecStart spawns a child process that becomes the main process of the service. The parent process exits when the startup is complete.

So in my environment the unit file will look like this
Description = CLM Server

ExecStart = /opt/IBM/JazzTeamServer602/server/server.startup
ExecStop = /opt/IBM/JazzTeamServer602/server/server.shutdown

Restart = always
Type = forking

WantedBy =
After the service is started, if you run the command "systemctl status clm", you should see something like below:

clm.service - CLM Server
   Loaded: loaded (/usr/lib/systemd/system/clm.service; enabled)
   Active: active (running) since Thu 2016-12-08 20:30:42 AEDT; 13s ago
  Process: 17891 ExecStart=/opt/IBM/JazzTeamServer602/server/server.startup (code=exited, status=0/SUCCESS)
 Main PID: 17923 (java)
   CGroup: /system.slice/clm.service
           └─17923 /opt/IBM/JazzTeamServer602/server/jre/bin/java -javaagent:/opt/IBM/JazzTeamServer602/server/liberty/wlp/bin/tools/ws-javaagent.jar -Djava.awt.headless=true -XX:MaxPermSize=256m -Djazz.connector.sslEnabledProtocols=...

Dec 08 20:29:46 systemd[1]: Starting CLM Server...
Dec 08 20:29:48 server.startup[17891]: 12 08, 2016 8:29:47 午後 <init>
Dec 08 20:29:48 server.startup[17891]: 情報: Agent version ""
Dec 08 20:29:49 server.startup[17891]: 12 08, 2016 8:29:49 午後 createJMXConnector
Dec 08 20:29:49 server.startup[17891]: 情報: IIOP will be listening on the next available system assigned port. Use to specify a port
Dec 08 20:29:50 server.startup[17891]: 12 08, 2016 8:29:50 午後 startAgent
Dec 08 20:29:50 server.startup[17891]: 情報: Health Center agent started on port 1972.
Dec 08 20:29:50 server.startup[17891]: サーバー clm を始動中です。
Dec 08 20:30:41 server.startup[17891]: サーバー clm がプロセス ID 17923 で始動しました。
Dec 08 20:30:42 systemd[1]: Started CLM Server.
(Sorry about the Japanese as I didn't spend time to change it, but you should get the idea.
Ralph Schoon selected this answer as the correct answer

One other answer

permanent link
Shimon Lipiner Nir (132) | answered Sep 22 '20, 7:11 a.m.

 Hi Donald

I followed your example but received the following error upon reboot
my file is named /lib/systemd/system.jazz.service

Jazz.service <o:p> </o:p>

Active failed (result start-limit) <o:p> </o:p>

Failed tos tart clm server <o:p> </o:p>

Unit jazz.service entered failed state <o:p> </o:p>

Jazz.service holdoff time over scheduling restart <o:p> </o:p>

Start request repeated too quickly for jazz.service <o:p> </o:p>

Failed tos tart clm server <o:p> </o:p>

Unit jazz.service entered failed state <o:p> </o:p>

Jazz.service failed <o:p> </o:p>

Any insight ?

Ralph Schoon commented Sep 22 '20, 7:56 a.m.

It should be obvious that posting a question as an answer to a 4 year old question is a bad idea, yet so many do it. 

Consider creating your own question. 

While you are at it, you might want to try to collect some actionable data and provide it in your question. There is pretty much nothing I can see, except maybe "Start request repeated too quickly"

Your answer

Register or to post your answer.

Dashboards and work items are no longer publicly available, so some links may be invalid. We now provide similar information through other means. Learn more here.