Hi, We run it as a systemd process and use the template function on Centos7. We run each handle server under a different user. And we start it in a production mode. [Unit] Description=Primary Handle Server for user: %I Requires=multi-user.target After=multi-user.target StopWhenUnneeded=yes [Service] User=%I ExecStart=/opt/hsj/bin/hdl-server /home/%i/etc ExecStop=/usr/bin/rm /home/%i/etc/delete_this_to_stop_server ExecStop=/usr/bin/sleep 1 Environment=HANDLE_SVR=/home/%i/etc [Install] WantedBy=production.target And for a process it is: systemctl status handle\@handle1 ● handle@handle1.service - Primary Handle Server for user: handle1 Loaded: loaded (/etc/systemd/system/handle@.service; enabled; vendor preset: disabled) Active: active (running) since Tue 2019-04-23 09:20:46 CEST; 3 weeks 3 days ago Process: 212375 ExecStop=/usr/bin/sleep 1 (code=exited, status=0/SUCCESS) Process: 212373 ExecStop=/usr/bin/rm /home/%i/etc/delete_this_to_stop_server (code=exited, status=0/SUCCESS) Main PID: 212411 (java) └─212411 java -Xmx4G -server -cp :/opt/hsj/bin/../lib/admintool-9.0.3.jar:/opt/hsj/bin/../lib/bcpkix-jdk15on-1.59.jar:/opt/hsj/bin/../lib/bcprov-jdk15on-1.59.jar:/opt/hsj/bin/../lib/cnriutil-2.0.jar:/op... Apr 23 09:20:51 epic6.m-service.surfsara.nl hdl-server[212411]: address: x.y.z.t Apr 23 09:20:51 epic6.m-service.surfsara.nl hdl-server[212411]: port: 2642 Apr 23 09:20:51 epic6.m-service.surfsara.nl hdl-server[212411]: UDP handle Request Listener: Apr 23 09:20:51 epic6.m-service.surfsara.nl hdl-server[212411]: address: x.y.z.t Apr 23 09:20:51 epic6.m-service.surfsara.nl hdl-server[212411]: port: 2642 Apr 23 09:20:51 epic6.m-service.surfsara.nl hdl-server[212411]: Starting TCP request handlers... Apr 23 09:20:51 epic6.m-service.surfsara.nl hdl-server[212411]: Starting UDP request handlers... Apr 23 09:20:53 epic6.m-service.surfsara.nl hdl-server[212411]: 2019-04-23 09:20:53,982 [de.dkrz.handlereverselookupservlet.HRLSApplication] INFO de.dkrz.handlereverselookupservlet.HRLSApplication - ...t starting... Apr 23 09:20:54 epic6.m-service.surfsara.nl hdl-server[212411]: 2019-04-23 09:20:54,083 [com.mchange.v2.log.MLog] INFO com.mchange.v2.log.MLog - MLog clients using slf4j logging. Apr 23 09:20:54 epic6.m-service.surfsara.nl hdl-server[212411]: 2019-04-23 09:20:54,145 [com.mchange.v2.c3p0.C3P0Registry] INFO com.mchange.v2.c3p0.C3P0Registry - Initializing c3p0-0.9.5.2 [built 08-...e; trace: 10] Hint: Some lines were ellipsized, use -l to show in full. -- Met vriendelijke groet, Robert Verkerk
|
_______________________________________________ Handle-Info mailing list Handle-Info@cnri.reston.va.us http://www.handle.net/mailman/listinfo/handle-info