JEUS 서버 기동 및 종료

본 부록에서는 JEUS 서버를 기동하고 종료하는 과정에 대해서 설명한다.

시스템이나 사용자 입력 오류에 따른 비정상 설치하는 경우나 애플리케이션을 사용자가 수동으로 기동(MS를 수동으로 기동)하고 종료하는 경우에 본 부록의 설명을 참고한다.

JEUS의 기동이나 종료는 WebAdmin이나 jeusadmin 명령어를 사용한다. 자세한 사항은 "JEUS Domain 안내서" 또는 "JEUS WebAdmin 안내서"를 참고한다. 본 안내서에서는 UNIX 환경에서 jeusadmin 명령어를 사용한 기동, 종료에 과정만 기술한다.

1. JEUS 서버 기동

다음은 JEUS 서버를 기동하는 과정에 대한 설명이다. OpenFrame Manager를 기동하기 위해서는 OpenFrame Manager가 디플로이되어 있는 JEUS 서버(MS)를 기동해야 한다.

  1. 다음의 스크립트 파일을 실행해서 JEUS의 DAS와 MS를 기동한다. DAS를 먼저 기동하고, 정상 기동 확인 후 MS를 기동한다.

    스크립트를 실행하기 위해서 도메인 이름, JEUS를 시작할 수 있는 권한을 가진 사용자명과 패스워드가 필요하다. JEUS_HOME/bin 하위에서 실행할 경우에는 이 모든 값이 필요하지만, DOMAIN_HOME 하위에서 실행할 때에는 도메인 이름을 생략할 수 있다.

    • DAS 기동

      $JEUS_HOME/bin/startDomainAdminServer -domain <domain_name> -u <user_name> -p <password>

      또는

      $JEUS_HOME/domains/<domain_name>/bin/startDomainAdminServer -u <user_name> -p <password>
    • MS 기동

      $JEUS_HOME/bin/startManagedServer -domain <domain_name> -server <server_name> -u <user_name> -p <password> -dasurl <das_ip:das_baseport>

      또는

      $JEUS_HOME/domains/<domain_name>/servers/<server_name>/bin/startManagedServer -s <server_name> -u <user_name> -p <password>

    다음은 MS를 기동하는 예제이다.

    [oframejeus1@ofLinux64 bin]$ startManagedServer -domain jeus_domain -server server1 -u administrator -p 1111111 -dasurl 192.168.105.207:9736
    ***************************************************************
      - JEUS Home         : /home/oframe10/jeus8_5
      - JEUS Base Port    :
      - Java Vendor       : etc
      - Added Java Option : -d64 -Djeus.vm.bits=64 -Djeus.io.buffer.size-per-pool=81920 -Djeus.cdi.enabled=false -Djeus.jms.server.manager.produce-wait-strategy-type=blocking -Djeus.servlet.sortWebinfLibraries=name_asc
    ***************************************************************
    
    ... 생략 ...
    
    ================== PATCH INFORMATION ===================
    PATCHES :
    jlext/jlext_v8500_202211_unified.jar
       - [ims-273350] fix: Managed server is not booted if domains directory does not exist. Initialize configuration synchronizer domain name using domain context.
       - [ims-275051] [JEUSVIII-3606] Improvement of Log FileHandler's file permission and owner configuration.
       - [ims-280827] IMS-187715, IMS-170995, IMS-133377 patch porting to JEUS 8.5 and merged IMS-273350 patch
       - [ims-290821] Subject serialize/deserialize backwards compatibility.
       - [ims-294392] Enable bootstrap patch
       - [ims-294506] Merged : IMS-2934392, IMS-280827 patch
    =========================================================
    
    =============== JEUS LICENSE INFORMATION ================
    == VERSION : JEUS 8.5 (8.5.0.0-b266025)
    == EDITION: Enterprise (Trial License)
    == NOTICE: This license restricts the number of allowed clients.
    == Max. Number of Clients: 5
    ==========================================================
    ================== PATCH INFORMATION ===================
    BOOTSTRAP PATCH :
    jbext/jbext_v8500_202211_unified.jar
       -  [ims-285417] [JEUSVIII-3543] Add JeusLogManager to bootstrap module.
    =========================================================
    [2023.06.20 18:35:21][2] [launcher-1] [SERVER-0201] Successfully connected to the Domain Administration Server(192.168.105.207:9736).
    [2023.06.20 18:35:21][2] [launcher-1] [Launcher-0058] All local configurations are up-to-date.
    This license is not appropriate for product runtime mode. Replace the license with an appropriate one.
    [2023.06.20 18:35:22][2] [launcher-1] [Launcher-0012] Starting the server [server1] with the command
    
    ... 생략 ...
    
    [2023.06.20 18:35:22][2] [launcher-1] [Launcher-0014] The server[server1] is being started ...
    Listening for transport dt_socket at address: 5060
    ================== PATCH INFORMATION ===================
    PATCHES :
    jext/jext_v8500_202211_unified.jar
       - [ims-272275] fix the bug that Whenever threadpool monitor try to check threadpool's condition, it prints out the dump
       - [ims-272371] There is no command to query the entire server group when in standalone mode.
       - [ims-272590] Add ask for user confirm to suspend-domain, stop-domain, and local-shutdown commands.
       - [ims-273141] Fix the problem that Managed Server cannot start through SSH NodeManager.
       - [ims-273803] Fix an issue that a redeployment fails on windows platform when new application file name is the same as the old one.
       - [ims-274040] Change ClusterLinkName Structure
       - [ims-274047] selector loop seems to have tight spin problem.
       - [ims-274148] modify-session-configuration command is not working for sticky encoding rule.
       - [ims-274268] add the average number of threadpool usage and the max usage of threadpool per every hour in the threadinfo
       - [ims-274643] when datasource's user and password are both dynamically change error appear. when setting datasource without vendor and wrong password and then later correct the password server couldn't recongnize the change
       - [ims-274777] Check whether the intermediate response for the Expect Header is properly flushed, and need to consider the situation when both expect header and request body come within the first packet
       - [ims-274818] diff from svn repository [JEUSVIII-2475][IMS-250040][JDBC] + error fixing code for compatibility
       - [ims-274949] NPE occurred 'cause policy is not initialized yet when transport starts.
       - [ims-275051] [JEUSVIII-3606] Improvement of Log FileHandler's file permission and owner configuration. [JEUSVIII-3607] Add file permission and owner config commands for Domain Log files in jeusadmin. - set-domain-log-config - remove-domain-log-config - show-domain-log-config
       - [ims-275352] When Client send Request with contentLength = -1 and close the outputStream, Jeus try to read next packet and get EOFExcpetion that leads to close the connection.
       - [ims-276122] Compression response for HTTP
       - [ims-276401] merge patch ims-274777 and ims-275352
       - [ims-276531] When scanning jar files, all subdirectories of /WEB-INF/lib/ are scanned.
       - [ims-276572] Use fast-deploy when the deployment image of an application is reusable.
       - [ims-276582] When jsp file is compiled with TLD, it searches all of WEB-INF subdirectories So, scanning tld listener when deploying is time-consuming job
       - [ims-277004] Too many print "Found the session which is copied temporarily." log
       - [ims-277036] Supports the boot-time auto deployment feature. Can use jeus.server.enable.auto-deploy system property to enable/disable the feature per server and Can use jeus.server.auto-deploy.dir system property to set location for applications to be auto deployed. Default is DOMAIN_HOME/auto-deploy.
       - [ims-277246] Merge-file: IMS-276531, IMS-276582
       - [ims-277745] hazelcast NPE issue when maxInactiveInterval is 0.
       - [ims-278067] putting session is not possible If timeout is 0.
       - [ims-278391] when calling, default port show up in the URL
       - [ims-278750] name of web fragment can be null
       - [ims-278929] Provides jeus.deploy.ignore-persistence-descriptor to ignore persistence.xml when deploying an application.
       - [ims-279045] jeus.session.redis.connection logger
       - [ims-279061] Protect concurrency vulnerability in JNDI authentication service.
       - [ims-279105] Fix the problem of filling XML defaults without considering the choice tag, Fix the problem that the NullPointerException is caused by Obtaining an incorrect item from the list-log-handlers command.
       - [ims-279182] When QueryString is null, it shows Empty String. Also, provide option named "jeus.servlet.response.sendRedirect_ignoreXForwardedProtoHeaderWhenRedirected" in order to ignore X-Forwarded-Proto when make url string of Location Header. Move the time to logging after find context.
       - [ims-279973] Fix an issue that jeus.cdi.enabled system property is not working for an ejb-in-war.
       - [ims-280827] IMS-187715, IMS-170995, IMS-133377 patch porting to JEUS 8.5.
       - [ims-280857] When processing an ssl request with a body exceeding 16k, decryption is not possible due to a pending read.
       - [ims-283453] XaEmulation cause error when calling Tx resume, suspend api.
       - [ims-283888] The NPE occurs when RequestLine exceeds 8K.
       - [ims-284872] Fixed a bug that responds with keep-alive to Connection:Close request through WebtoB Connector.
       - [ims-285036] Improves performance when loading classes from JARs including META-INF/Manifest.MF.
       - [ims-285412] Change the logger level for FileNotFoundException occurred during the processing request
       - [ims-285415] add service channel into service channel util when initializing jms engine.
       - [ims-285941] Service is unexpectedly delayed when SSL certification is applied in http-listener. This issue happens when the inbound buffer is processed improperly to handle the 'BUFFER_UNDERFLOW' result of SSL message decryption.
       - [ims-286680] If the AJP13 header exceeds 8192, the request cannot be processed.
       - [ims-286918] the session manager received error packet.
       - [ims-286971] Inconsistent response between JEUS and WebtoB when a request comes to an invalid virtual host.
       - [ims-287932] Prevents the NPE that occurred in some condition where the leader has not been determined.
       - [ims-289255] Fix bug that could send a message to the JMSLocalServerEntry that was already closed.
       - [ims-290033] Allow Multiple defining pageEncoding.
       - [ims-290396] backup table is not created when application name and server name are the same.
       - [ims-290821] Subject serialize/deserialize backwards compatibility.
       - [ims-291311] When graceful-shutdowning server, JEUS accept new request after blocking new request and write 404 response.
       - [ims-291639] Do not update attribute to redis when getAttribute, Issue that do not ensure the concurrence of attributes to be updated and update attribute to redis when getAttribute is null.
       - [ims-291919] When write text message with RemoteEndpoint.Async, the size of ByteBuffer is initialized with 8k size and reused that makes overflow when encoding with CharBuffer. So, it needs to write buffer more than once that leads to nioStreamHandler blocked. Also, When connection is closed within network layer, webSocket Container must be notified that the connection is closed and make sure that websocketSession is closed.
       - [ims-292369] When it takes some time to processing request after read long body contents, it causes post data read timeout even if it has read all body.
       - [ims-292813] Fixed a violation of servlet specification 8.2.3.4.
       - [ims-293310] java.lang.OutOfMemoryError: Direct buffer memory occurs when using HTTPS
       - [ims-293754] Merged Patch : ims-274777, ims-275352, ims-276122, ims-278391, ims-279182, ims-272275, ims-276531, ims-276582, ims-283888, ims-285412, ims-286971
       - [ims-293757] Merged Patch : ims-291919, ims-291311, ims-292369
       - [ims-293758] Merged patch : ims-292813, ims-278750
       - [ims-293759] Merged patch : ims-280857, ims-285941, ims-293310
       - [ims-293760] Merged patch : ims-280827, ims-277036
       - [ims-293767] Merged patch : ims-278067, ims-279045, ims-291639
    jext/jext_v8000_i140563_a887701.jar
       - Fix the InjecteeSkippingAnalyzer to use repacked classes.Should be used with repacked weld-core.jar
    =========================================================
    [2023.06.20 18:35:24][2] [server1-1] [SERVER-0248] The JEUS server is STARTING.
    [2023.06.20 18:35:24:492][0] [server1-1] [SERVER-0000] Version information - JEUS 8.5 (8.5.0.0-b266026).
    [2023.06.20 18:35:24:492][0] [server1-1] [SERVER-0001] java.specification.version=[1.8], java.runtime.version=[1.8.0_275-b01], vendor=[Red Hat, Inc.]
    [2023.06.20 18:35:24:493][2] [server1-1] [SERVER-0002] Domain=[jeus_domain], Server=[server1], baseport=[6936], pid=[20574]
    [2023.06.20 18:35:24:498][2] [server1-1] [SERVER-0004] The current system time zone : ؍W
    [2023.06.20 18:35:24:520][2] [server1-1] [SERVER-0570] Check [jeus.jms.server.manager.produce-wait-strategy-type]. It may be incorrect.
    [2023.06.20 18:35:24:520][2] [server1-1] [SERVER-0570] Check [jeus.io.buffer.size-per-pool]. It may be incorrect.
    [2023.06.20 18:35:24:520][2] [server1-1] [SERVER-0570] Check [jeus.vm.bits]. It may be incorrect.
    [2023.06.20 18:35:24:527][2] [server1-1] [SERVER-0568] Service address='ofLinux64:6936', hostname='ofLinux64', representation ip='127.0.0.1'
    [2023.06.20 18:35:24:539][2] [server1-1] [SERVER-0561] The default RMI export port = 6943 and bind address = ofLinux64/127.0.0.1.
    [2023.06.20 18:35:24:577][2] [server1-1] [NET-0002] Beginning to listen to NonBlockingChannelAcceptor: ofLinux64:6936.
    [2023.06.20 18:35:24:677][1] [server1-1] [CloudSupport-0114] CloudServiceProvider is com.tmax.jeus.cloud.provider.JeusNonCloudDefaultProvider.
    [2023.06.20 18:35:24:702][2] [server1-1] [SCF-0120] Virtual Multicast Transport has been successfully initialized.
    [2023.06.20 18:35:24:704][2] [server1-1] [SCF-0126] Addresses of whole group for virtual multicast.
                                           192.168.105.207:9336(SCF)
                                           192.168.105.207:9436(SCF)
                                                 127.0.0.1:9536(SCF)
                                                 127.0.0.1:9636(SCF)
                                                 127.0.0.1:9736(SCF)
                                                 127.0.0.1:6936(SCF)
                                                 127.0.0.1:9936(SCF)
    
    [2023.06.20 18:35:24:709][2] [server1-1] [SCF-0001] System Clustering Framework has been successfully initialized.
    [2023.06.20 18:35:24:789][2] [server1-1] [JNSS-0009] The JNDI naming server has been successfully initialized.
    [2023.06.20 18:35:24:795][2] [server1-1] [JNDI.Local-0001] Starting JNDI Local Client...
    [2023.06.20 18:35:24:815][2] [server1-1] [JMXR-0138] JMXConnector service URL : service:jmx:jmxmp://127.0.0.1:6936/JeusMBeanServer
    [2023.06.20 18:35:24:816][2] [server1-1] [JMXR-0138] JMXConnector service URL : service:jmx:jmxmp://127.0.0.1:6936/JEUSMP_server1
    [2023.06.20 18:35:24:832][2] [server1-1] [JMX-0051] JMXConnector started with the JNDI name [mgmt/rmbs/server1].
    [2023.06.20 18:35:24:894][2] [server1-16] [SCF-0122] SCF Connection to server1 has been accepted. Handler is SocketStream@3dcb285(127.0.0.1:6936(SCF) -> 127.0.0.1:9936(SCF)).
    [2023.06.20 18:35:24:897][2] [server1-16] [SCF-0122] SCF Connection to server3 has been accepted. Handler is SocketStream@3277be4c(127.0.0.1:6936(SCF) -> 127.0.0.1:9636(SCF)).
    [2023.06.20 18:35:24:898][2] [server1-16] [SCF-0122] SCF Connection to server4 has been accepted. Handler is SocketStream@6c00055d(127.0.0.1:6936(SCF) -> 127.0.0.1:9536(SCF)).
    [2023.06.20 18:35:24:899][2] [server1-16] [SCF-0122] SCF Connection to server6 has been accepted. Handler is SocketStream@6c797b2(127.0.0.1:6936(SCF) -> 192.168.105.207:9336(SCF)).
    [2023.06.20 18:35:24:900][2] [server1-16] [SCF-0122] SCF Connection to adminServer has been accepted. Handler is SocketStream@2278a835(127.0.0.1:6936(SCF) -> 127.0.0.1:9736(SCF)).
    [2023.06.20 18:35:24:901][2] [server1-16] [SCF-0122] SCF Connection to server5 has been accepted. Handler is SocketStream@5baf09f7(127.0.0.1:6936(SCF) -> 192.168.105.207:9436(SCF)).
    [2023.06.20 18:35:24:902][2] [server1-1] [SCF-0210] Leader election state has been changed from 'UNKNOWN' to 'ELECTING'.
    [2023.06.20 18:35:24:913][2] [server1-32] [SCF-0210] Leader election state has been changed from 'ELECTING' to 'ASSIGNED'.
    [2023.06.20 18:35:25:014][2] [server1-1] [Scheduler-0022] The JEUS scheduler has been exported as jeus_service/Scheduler.
    [2023.06.20 18:35:25:014][2] [server1-1] [SERVER-0182] The SchedulerService started.
    [2023.06.20 18:35:25:030][2] [server1-38] [Domain-0113] Processing a resynchronization request from adminServer[127.0.0.1:9736(SCF)]
    [2023.06.20 18:35:25:046][2] [server1-38] [Domain-0101] Domain Administration Server recovered. server1 is communicating with the domain administration server.
    [2023.06.20 18:35:25:359][2] [server1-38] [SERVER-0201] Successfully connected to the Domain Administration Server(127.0.0.1:9736).
    [2023.06.20 18:35:25:367][2] [server1-38] [SERVER-0308] Resynchronized the configuration with Domain Administration Server.
    [2023.06.20 18:35:25:511][2] [server1-1] [JMS-7374] The persistence store manager for the JMS server 'server1' has been started.
    [2023.06.20 18:35:25:515][2] [server1-1] [JMS-6843] Adding a destination: type=81, name=JEUSMQ_DLQ, export name=JEUSMQ_DLQ.
    [2023.06.20 18:35:25:565][2] [server1-1] [JMS-6843] Adding a destination: type=81, name=JEUSMQ_AMQPQ, export name=JEUSMQ_AMQPQ.
    [2023.06.20 18:35:25:592][2] [server1-1] [JMS-6822] The JMS engine with the server named server1 has started.
    [2023.06.20 18:35:25:610][2] [server1-1] [EJB-5501] EJB engine started successfully.
    [2023.06.20 18:35:25:622][2] [server1-1] [WEB-1003] Socket send buffer size of this operating system = [8192], JEUS default output buffer size = [8192]
    [2023.06.20 18:35:26:058][2] [server1-1] [WEB-1030] The web engine has started successfully.
    [2023.06.20 18:35:26:090][2] [server1-1] [SERVER-0248] The JEUS server is STANDBY.
    [2023.06.20 18:35:26:091][2] [server1-1] [SERVER-0248] The JEUS server is STARTING.
    [2023.06.20 18:35:26:152][2] [server1-26] [Deploy-0095] Distributing the application[ofmanager2].
    [2023.06.20 18:35:27:011][2] [server1-26] [WEB-3857] <Session information of Context(ofmanager2)>
    - session descriptor -
        - timeout           : 0(min)
        - max session count : -1
        - shared            : false
        - reload-persistent : false
    - session tracking mode -
        - Cookie     : true
        - URL Rewrite: false
        - SSL        : false
    
    - session cookie config -
        - cookie-name : JSESSIONID
        - url-cookie-name : jsessionid
        - version         : 0
        - domain          : null
        - path            : null
        - max-age         : -1 (browser-lifetime)
        - secure          : false
        - http-only       : true
        - same-site       : Disable
    
    [2023.06.20 18:35:27:138][2] [server1-26] [JASPER-1002] At least one JAR was scanned for TLDs yet contained no TLDs. Enable debug logging for this logger for a complete list of JARs that were scanned but no TLDs were found in them. Skipping unneeded JARs during scanning can improve startup time and JSP compilation time.
    [2023.06.20 18:35:28:048][1] [server1-26] [CDI-0164] CDI scanning has bean disabled due to user settings.
    [2023.06.20 18:35:28:048][2] [server1-26] [WEB-1032] Distributed the web context [ofmanager2] information
    - Virtual host    : DEFAULT_HOST
    - Context path    : /ofmanager2
    - Document base   : /home/oframe10/jeus8_5/domains/jeus_domain/servers/server1/lib/application/ofmanager2
    - Module version  : 3.0
    - Class loading   : ISOLATED
    
    ... 생략 ...
    
    [2023.06.20 18:35:30:829][0] [server1-1] [SERVER-0242] Successfully started the server.
    [2023.06.20 18:35:30:829][2] [server1-1] [SERVER-0248] The JEUS server is RUNNING.
    [2023.06.20 18:35:30][2] [launcher-14] [Launcher-0034] The server[server1] initialization completed successfully[pid : 20574].
    [2023.06.20 18:35:30][0] [launcher-1] [Launcher-0040] Successfully started the server[server1]. The server state is now RUNNING.
  2. 서버 기동이 완료되면 DAS와 MS가 정상 기동되었는지 프로세스와 로그를 확인한다. 자세한 설명은 JEUS 서버 기동 확인을 참고한다.

  3. JEUS의 MS가 기동될 때 OpenFrame Manager도 함께 기동되어, 웹브라우저를 통해 OpenFrame Manager에 접속할 수 있다. 접속하는 방법은 OpenFrame Manager 기동을 참고한다.

2. JEUS 서버 종료

OpenFrame Manager 를 종료하기 위해서는 OpenFrame Manager가 디플로이 되어있는 JEUS 서버(MS)를 종료해야 한다. 서버는 jeusadmin에 접속해서 종료하거나, jeusadmin 접속하지않고 stopServer 스크립트를 사용해서 종료할 수 있다.

jeusadmin 접속

다음은 jeusadmin에 접속해서 JEUS 서버를 종료하는 과정에 대한 설명이다.

  1. 콘솔 창에서 jeusadmin 명령어를 실행한다. 일반적으로 관리자의 계정은 'administrator'이고 패스워드는 JEUS를 설치할 때 입력한 값이다.

    [oframejeus1@ofLinux64 ~]$ jeusadmin -u administrator -p 1111111
    Attempting to connect to 127.0.0.1:9736.
    The connection has been established to Domain Administration Server adminServer in the domain jeus_domain.
    JEUS8_5 Administration Tool
    To view help, use the 'help' command.
    [DAS]jeus_domain.adminServer>

    jeusadmin의 appinfo 명령어를 실행해서 JEUS 서버 현황을 확인한다.

    [DAS]jeus_domain.adminServer>appinfo
    Application information for the domain [jeus_domain].
    ================================================================================
    +---------+-----------+---------+---------+----------+-------------------------+
    | Applicat|Application|  State  |  Target |  Target  |     Application Path    |
    | ion ID  |   Type    |         | Servers | Clusters |                         |
    +---------+-----------+---------+---------+----------+-------------------------+
    | ofmanage| WAR       | RUNNING | server1 |          |/home/oframejeus1/jeus8_5/|
    |r        |           |         |         |          |domains/jeus_domain/serve|
    |         |           |         |         |          |rs/server1/lib/applicatio|
    |         |           |         |         |          |n/ofmanager              |
    +---------+-----------+---------+---------+----------+-------------------------+
    ================================================================================
  2. OpenFrame Manager가 설치된 환경에서 JEUS 서버들을 종료한다.

    [DAS]jeus_domain.adminServer>stop-server server1
    Server [server1] was successfully stopped.
    [DAS]jeus_domain.adminServer>

    local-shutdown 명령어를 실행해서 JEUS 서버를 종료한다. local-start-server와 local-shutdown 명령으로 JEUS 서버를 제어할 수 있다.

    [DAS]jeus_domain.adminServer>local-shutdown
    The server [adminServer] has been shut down successfully.
    offline>
  3. jeusadmin을 종료하기 위해서 exit 명령을 실행한다.

    exit
stopServer 스크립트 사용

jeusadmin에 접속하지 않고 stopServer 스크립트를 이용해서 서버를 종료할 수 있다.

$JEUS_HOME/bin/stopServer -u <user_name> -p <password> -host <das_ip:das_baseport>

다음은 MS를 종료하는 예제이다.

[oframejeus1@ofLinux64 bin]$ stopServer -u administrator -p 1111111 -host 192.168.105.207:9714

****************************************************************************
  - Usage : stopServer -host host:port -u username -p password
****************************************************************************
Attempting to connect to 192.168.105.207:9714.
The connection has been established to the managed server server1 in the domain jeus_domain.
The server [server1] has been shut down successfully.