tocmat 을 CentOS 7.XX 에 서비스 등록 하는 법을 해보자.
앞서 apache 와 동일 하다고 할 수 있다.
크게 어렵지 않다.
" Tomcat CentOS7.xx systemctl 서비스 등록 "
" /usr/lib/systemctl/system "
위치에 서비스 등록 할 파일을 생성 한다.
" vim tomcat.service "
아래 내용을 입력 후 저장
-----------------------------------------------------------
[Unit]
Description=node20
After=network.target syslog.target
[Service]
Type=forking
User=tomcat
Group=tomcat
ExecStart=/톰캣경로/bin/start.sh
ExecStop=/톰캣경로/bin/stop.sh
[Install]
WantedBy=multi-user.target
------------------------------------------------------------
저장 후 데몬 리로드 후 서비스 드옭
" systemctl dae-mon-reload "
" systemctl enable tomcat.service "
" systemctl start tomcat.service "
끝이다.
'시스템 소프트웨어 > 미들웨어(MidleWare)' 카테고리의 다른 글
Apache SSL 비밀번호(passwd) 자동 입력 방법 (0) | 2023.06.27 |
---|---|
WEB/WAS 구성 중 CPU, Core 확인 방법 (0) | 2023.06.27 |
Apache CentOS 7.XX systemctl 서비스 등록 (0) | 2023.06.26 |