systemd unit for WebSphere Liberty (wlp)

This is the for-dummies cheatsheet for creating a basic WLP systemd unit. Note that the paths here use a separate WLP_USER_DIR directory specified in etc/server.env

Step 1: Create /etc/systemd/system/wlp.service:

[Unit] Description=wlp After=network-online.target Wants=network-online.target [Service] ExecStart=/home/covener/data/apps/wlp-bin/bin/server start ExecStop=/home/covener/data/apps/wlp-bin/bin/server stop User=covener Environment=JAVA_HOME=/home/covener/java Type=forking Restart = always PIDFile=/home/covener/data/apps/wlp-usr/servers/.pid/defaultServer.pid [Install] WantedBy=multi-user.target


Step 2: Stop your server manually (systemd gets confused by a define service that was started outside of systemd)

Step 3: Get systemctl to pick up the new unit:
systemctl daemon-reload

Step 4: Start server with systemctl:
systemctl start wlp

Step 5: Enable for starting on reboot:
systemd enable wlp

Other Hints:
systemctl --no-pager status wlp

Comments

Popular posts from this blog

Showing HTTP requests with no HTTP responses in wireshark

openssl and atexit