본문 바로가기
Jenkins

windows 서비스 등록 오류

by IT History 2023. 1. 18.
728x90
반응형

Jenkins_cline_Agent 를 윈도우 서비스에 등록시

오류 1053: 서비스가 시작이나 제어 요청에 빠르게 응답하지 않았습니다.

오류로 윈도우 서비스가 등록되지 않아 

결국 nssm 사용

nssm 다운로드 : https://nssm.cc/download

 

NSSM - the Non-Sucking Service Manager

NSSM - the Non-Sucking Service Manager Windows 10, Server 2016 and newer 2017-04-26: Users of Windows 10 Creators Update or newer should use prelease build 2.24-101 or any newer build to avoid an issue with services failing to start. If for some reason you

nssm.cc

* nssm 이란

nssm 은 실행 중인 서비스를 모니터링하고 중지되면 다시 시작합니다 . nssm을 사용하면 서비스가 실행 중이라고 표시되면 실제로 실행 중임을 알 수 있습니다. 또는 응용 프로그램이 제대로 작동하는 경우 응용 프로그램을 다시 시작하는 모든 책임을 면제하고 Windows가 복구 작업을 처리하도록 nssm을 구성할 수 있습니다.

 

 

1. nssm-2.24.zip 압축 해제

2. cmd 관리자모드 cd..  c:\nssm-2.24\win32 or win64  콘솔로 이동

3. nssm install [서비스명] [bat파일경로]

ex) nssm install jenkins_client_Agent D:\jenkins_clinet\agent.bat

4. 작업 관리자 > 서비스 > jenkins_client_Agent 실행

**참고 사이트

https://yjh5369.tistory.com/entry/%EB%B0%B0%EC%B9%98%ED%8C%8C%EC%9D%BCbat-%ED%8C%8C%EC%9D%BC%EC%9D%84-%EC%84%9C%EB%B9%84%EC%8A%A4%EB%A1%9C-%EB%93%B1%EB%A1%9D%ED%95%98%EB%8A%94-%EB%B0%A9%EB%B2%95

 

배치파일(bat 파일)을 서비스로 등록하는 방법

jar 파일을 서비스로 등록하는 방법을 찾던 중 아래와 같이 해서 성공했음 sc create 명령어로 서비스를 등록하면 "서비스를 시작하지 못했습니다: 서비스가 시작이나 제어 요청에 시기 적절하게

yjh5369.tistory.com

 

728x90
반응형

댓글