WebtoB Console Tool

WebtoB provides the following tools to manage engine processes and server processes.

  • Admin Tools

    Console Tool Description

    wsadmin

    A tool used for the overall WebtoB system management, supporting system information retrieval and administrator tasks.

  • Other Tools

    Console Tool Description

    configValidator

    Performs schema validation on WebtoB environment files.

    mkpwd

    Creates a file to store passwords for SSL certificate keys.

wsadmin

wsadmin provides a text-based management environment. It waits in the command prompt and executes a command that has been entered.

  • Execution

    To run the wsadmin tool, use the wsadmin command.

    $ wsadmin

    If the wsadmin tool runs successfully, the following message is displayed at the prompt:

    $$1 [wsadmin]>>
  • Exit

    To exit the wsadmin tool, use the exit command.

    $$3 [wsadmin]>> exit

 

The following describes the commands provided by wsadmin.

Command Abbreviation Description

help

Displays help for commands available in the wsadmin tool.

client-info

(cli)

Displays client connection information for WebtoB.

connect

Connects to a specific WebtoB Admin server.

stat-info

(st)

Displays statistics about server and service status.

config

(cfg)

Displays environment settings information.

cache-list

(cachelist)

Displays information about the HTTP response cache.

svg-info

(and)

Displays information about the internal servers processing the client requests.

connection-info

(There)

Displays connection information between WebtoB’s clients and internal servers.

exit

Exits the wsadmin tool.

Each command provides the following common options:

Option Description

[-i <repeat interval>]

Specifies the repetition interval in seconds of the command. (Default: 1 second)

[-r <number of repetitions>]

Specifies the number of repetitions. (Default: 0)
If set to 0, it will repeat infinitely.

The following is an example of executing the cli command 2 times with a 2-second interval.

wsadmin]>> cli -i 2 -r 2
Command will be executed repeatedly. Count=2. Interval=2(sec).
* Repeat count = 1
----------------------------------------------------------------------------------------------------------
| Client Info : HTH-0                                                                                    |
----------------------------------------------------------------------------------------------------------
| No | Status | Request Count | Response Count | Idle |    Local Address    |    Remote Address    | Ssl |
----------------------------------------------------------------------------------------------------------
| 12 | READY  |       1       |       1        |  22  | 192.168.15.120:8080 | 192.168.15.120:53844 | No  |
----------------------------------------------------------------------------------------------------------


* Repeat count = 2
----------------------------------------------------------------------------------------------------------
| Client Info : HTH-0                                                                                    |
----------------------------------------------------------------------------------------------------------
| No | Status | Request Count | Response Count | Idle |    Local Address    |    Remote Address    | Ssl |
----------------------------------------------------------------------------------------------------------
| 12 | READY  |       1       |       1        |  24  | 192.168.15.120:8080 | 192.168.15.120:53844 | No  |
----------------------------------------------------------------------------------------------------------


Repeat done.

help

Displays the help for commands available in the wsadmin tool.

  • Usage

    >  help [command]
    Option Description

    [Command]

    Specifies the command for which to output usage information.

  • Example

    No Options Used
    [wsadmin]>> help
    ---------------------------------------------------------------------------------------------
    | Help                                                                                      |
    ---------------------------------------------------------------------------------------------
    |  Command Name  |   Command Alias    |                 Command Descriptor                  |
    ---------------------------------------------------------------------------------------------
    | client-info    | cliinfo, cli       | show client info                                    |
    | connect        |                    | connect to the api server                           |
    | stat-info      | stat, st           | Show statistics info.                               |
    |                |                    | jeus, reverser proxy server, html server statistic. |
    | config         | cfg                | Config info                                         |
    | cache-list     | cachelist          | Cache info list                                     |
    | svg-info       | svginfo, sgi, si   | show server group info                              |
    | connectioninfo | coninifo, ci, coni | show connection info                                |
    ---------------------------------------------------------------------------------------------
    | You can use the help command for each individual command.                                 |
    ---------------------------------------------------------------------------------------------
    Options Used
    [wsadmin]>> help st
    ---------------------------------------------------------------------------------------------------------------------------------------
    | Help : stat-info( stat, st )                                                                                                        |
    ---------------------------------------------------------------------------------------------------------------------------------------
    | OptionName | IsRequired | HasArgs |                                           Description                                           |
    ---------------------------------------------------------------------------------------------------------------------------------------
    | hth_number |     No     |   Yes   | target hth number                                                                               |
    | jeus       |     No     |   Yes   | jeus statistic info                                                                             |
    | rproxy     |     No     |   Yes   | reverse proxy statistic info                                                                    |
    | htmls      |     No     |   No    | html server statistic info                                                                      |
    | ---        |    ---     |   ---   | ---                                                                                             |
    | i          |     No     |   Yes   | Default: 1 (second) if a repeat is needed. Interval specifies the time delay between repeats.   |
    | r          |     No     |   Yes   | Default: 0 (unlimited) if a repeat is needed. To limit the repeats, set a value greater than 0. |
    ---------------------------------------------------------------------------------------------------------------------------------------
    | Show statistics info.                                                                                                               |
    | jeus, reverser proxy server, html server statistic.                                                                                 |
    ---------------------------------------------------------------------------------------------------------------------------------------

client-info (cli, cliinfo)

Displays the environment settings, such as the current status, IP address, number of processed requests, of the currently connected client (usually a web browser).

  • Usage

    > cli [-vhost <VHOST name>][-hth <HTH number>]
    Option Description

    [-vhost <VHOST name>]

    Specifies the VHOST name for which client information will be displayed.

    [-hth <HTH number>]

    Specifies the HTH number for which client information will be displayed.

  • Example

    Using the cli without options displays the following result. Each entry represents one client.

    [wsadmin]>> cli
    ----------------------------------------------------------------------------------------------------------
    | Client Info : HTH-0                                                                                    |
    ----------------------------------------------------------------------------------------------------------
    | No | Status | Request Count | Response Count | Idle |    Local Address    |    Remote Address    | Ssl |
    ----------------------------------------------------------------------------------------------------------
    | 5  | READY  |       0       |       0        |  4   | 192.168.15.120:8080 | 192.168.15.120:38572 | No  |
    ----------------------------------------------------------------------------------------------------------

    The following describes each output item.

    Item Description

    No

    The connection number managed internally by WebtoB.

    Status

    Client state within the server.

    • READY: Receiving requests from the client.

    • RUNNING: A client request is being processed on the server.

    Request Count

    The number of requests sent by the client.

    Response Count

    The number of responses received by that client.

    Idle

    Client idle time with no data exchanges.

    Local Address,
    Remote Address

    IP addresses and port numbers of the server and client

    Ssl

    Specifies whether the client is using an SSL connection.

connect

This command is used to connect to the WebtoB Admin server from wsadmin.

  • Usage

    > connect [-ip <Admin server IP>][-port <Admin server port>]
    Option Description

    [-ip <Admin server IP>]

    Specifies the IP address of the WebtoB Admin server to connect to.

    [-port <Admin server port>]

    Specifies the port number of the WebtoB Admin server to connect to.

  • Example

    [wsadmin]>> connect -ip localhost -port 9090
    Connection established successfully with localhost:9090.

stat-info (st, stat)

Provides information about the operational state of the system and internal servers in operation.

You can check dynamic information such as the current status of the internal server, the names of the services being processed, the number of services processed, service status, and the number of requests waiting in the service queue.

  • Usage

    > st [-hth <HTH number>][-jeus <JEUS server group name>][-rproxy <reverse proxy server group name>][-htmls <HTML server name>]
    Option Description

    [-hth <HTH number>]

    Specifies the HTH number for which internal server statistics will be output.

    [-jeus <JEUS server group name>]

    Specifies the JEUS server group name for which statistics will be output.

    [-rproxy <reverse proxy server group name>]

    Specifies the name of the reverse proxy server group for which statistics should be output.

    [-htmls <HTML server name>]

    Specifies the HTML server name for which statistics will be output.

  • Example

    [wsadmin]>> st
    Prints all information. Use options to print specific items ( -jeus, -rproxy, -htmls )
    -------------------------------------------------------------------------------------------------------------------------------------------------
    | HTH-0 : Jeus statistic                                                                                                                        |
    -------------------------------------------------------------------------------------------------------------------------------------------------
    |              Server              | Server Group | Connections | Average Processed Time | Request Count | Response Count | Sticky Routed Count |
    -------------------------------------------------------------------------------------------------------------------------------------------------
    | amV1c19kb21haW4vYWRtaW5TZXJ2ZXI= |   MyGroup1   |     10      |        0.000000        |       0       |       0        |          0          |
    -------------------------------------------------------------------------------------------------------------------------------------------------
    
    ------------------------------------------------------------------------------------------------------------------------------------
    | HTH-0 : ReverseProxy statistic                                                                                                   |
    ------------------------------------------------------------------------------------------------------------------------------------
    |       Server        | Server Group | Connections | Average Processed Time | Request Count | Response Count | Sticky Routed Count |
    ------------------------------------------------------------------------------------------------------------------------------------
    | 192.168.15.120:8088 |   rproxyg1   |      0      |        0.000000        |       0       |       0        |          0          |
    ------------------------------------------------------------------------------------------------------------------------------------
    
    ----------------------------------------------------------------------------------
    | HTH-0 : Html server statistic                                                  |
    ----------------------------------------------------------------------------------
    | Server | Queue Count | Average Processed Time | Request Count | Response Count |
    ----------------------------------------------------------------------------------
    | HTMLS  |      0      |        0.002725        |      10       |       10       |
    ----------------------------------------------------------------------------------

    The following describes each output item.

    • Output items for JEUS server statistics

      Item Description

      Server

      The name of the JEUS server managed internally.

      Server Group

      The name of the JEUS server group.

      Connections

      The number of connections established with the JEUS server.

      Average Processed Time

      The average processing time. (Unit: seconds)

      Request Count

      The number of requests sent to the internal server.

      Response Count

      The number of requests processed by the internal server.

      Sticky Routed Count

      The number of requests sent to the internal server with a Sticky ID from the client.

    • Output items for reverse proxy server statistics

      Item Description

      Server

      The address of the reverse proxy server.

      Server Group

      The name of the reverse proxy server group.

      Connections

      The number of connections established with the reverse proxy server.

      Average Processed Time

      The average processing time. (Unit: seconds)

      Request Count

      The number of requests sent to the internal server.

      Response Count

      The number of requests processed by the internal server.

      Sticky Routed Count

      The number of requests sent to the internal server with a Sticky ID from the client.

    • Output items for HTML server statistics

      Item Description

      Server

      The HTML server name.

      Queue Count

      The number of requests waiting in the internal server’s queue.

      Average Processed Time

      The average processing time. (Unit: seconds)

      Request Count

      The number of requests sent to the internal server.

      Response Count

      The number of requests processed by the internal server.

config (cfg)

Displays the environment information of the currently running system. It allows you to check all environment information including default values by nodes, server groups, servers, and services defined in the environment configuration file.

  • Usage

    > config [-path <JSON path>]
    Option Description

    [-path <JSON path>]

    Specifies the JSON path to the configuration file to check. The path must always start with '/'.
    If the path is omitted or set to '/', all currently set environment information will be retrieved.

  • Example

    The following is an example of displaying the environment configuration for the NODE section. For detailed information about the cofngiruation items in the NODE section, refer to Configuration Items.

    [wsadmin]>> cfg -path /node
    ----------------------------------------------
    | Target Config /node                        |
    ----------------------------------------------
    |                   Values                   |
    ----------------------------------------------
    | {                                          |
    |   "cache_entry": 128,                      |
    |   "cache_key": "HOST_URI",                 |
    |   "cache_max_file_size": 8192,             |
    |   "connection_pool_size": 8192,            |
    |   "graceful_shutdown_timeout": 30,         |
    |   "hth_count": 1,                          |
    |   "hth_schedule": "RR",                    |
    |   "limit_request_body_size": 0,            |
    |   "limit_request_header_field_count": 100, |
    |   "limit_request_header_field_size": 8190, |
    |   "limit_request_line_size": 8190,         |
    |   "listen_backlog": 4096,                  |
    |   "max_cache_memory_size": 100,            |
    |   "name": "ksh",                           |
    |   "system_filters": [],                    |
    |   "worker_threads": 1                      |
    | }                                          |
    ----------------------------------------------

cache-list (cachelist)

Displays information about the responses stored in WebtoB’s HTTP response cache.

  • Usage

    > cachelist [-hth <HTH number>]
    Option Description

    [-hth <HTH number>]

    Specifies the HTH for which to retrieve cache information. If not specified, cache information for all HTHs is retrieved.

  • Example

    The following is an example of a cached response to the request "/test.txt". The rest of the request path is used only for internal server debugging.

    [wsadmin]>> cachelist
    -------------------------------------------------------------------
    | HTH-0: Cache List Info                                          |
    -------------------------------------------------------------------
    |          Cache key           |    Expired time     | Cache size |
    -------------------------------------------------------------------
    | 192.168.15.120:8080/test.txt | 2024-10-29 12:34:53 |         286|
    -------------------------------------------------------------------
    | Cache count : 1                                                 |
    | Memory usages : 286                                             |
    -------------------------------------------------------------------

svg-info (si, sgi, svginfo)

Displays information about the internal server that processes the client’s request.

  • Usage

    > si [-jeus <JEUS server group name>][-rproxy <reverse proxy server group name>]
    Option Description

    [-jeus <JEUS server group name>]

    Specifies the JEUS server group name for which information will be output.

    [-rproxy <reverse proxy server group name>]

    Specifies the name of the reverse proxy server group for which information will be output.

  • Example

    [wsadmin]>> si
    --------------------------------------------------------------------
    | HTH-0 : Jeus ServerGroup Info                                    |
    --------------------------------------------------------------------
    | svgname  | status | aqcnt | count | cqcnt | qpcnt | reqs | rscnt |
    --------------------------------------------------------------------
    | MyGroup2 |  NRDY  |   0   |   0   |   0   |   0   |  0   |   0   |
    | MyGroup1 |  RDY   |   0   |   0   |   0   |   0   |  0   |   0   |
    --------------------------------------------------------------------
    
    --------------------------------------------------------------------
    | HTH-0 : Reverse Proxy ServerGroup Info                           |
    --------------------------------------------------------------------
    | svgname  | status | aqcnt | count | cqcnt | qpcnt | reqs | rscnt |
    --------------------------------------------------------------------
    | rproxyg1 |  RDY   |   0   |   0   |   0   |   0   |  0   |   0   |
    --------------------------------------------------------------------

    The following describes each output item.

    Item Description

    svgname

    The server group name.

    status

    Client state within the server.

    • RDY: Request can be processed. There are internal server processes connected to WebtoB.

    • NRDY: Request cannot be processed. There are no internal server processes connected to WebtoB.

    • BLK: Server is suspended by administrator command. Request cannot be processed.

    aqcnt

    Cumulative number of queued requests. (Cumulative cqcnt value)

    count

    Number of processed requests.

    cqcnt

    Number of requests in the queue.

    qpcnt

    Number of queued requests that have been removed from the queue due to request timeout, qp command, etc.

    reqs

    Number of requests sent to the server.

    rscnt

    Number of server restarts due to abnormal termination.

connection-info (ci, coni, coninfo)

Displays connection information between WebtoB’s clients and internal servers.

  • Usage

    > ci [-jeus <JEUS server group name>][-rproxy <reverse proxy server group name>]
    Option Description

    [-jeus <JEUS server group name>]

    Specifies the JEUS server group name for which information will be output.

    [-rproxy <reverse proxy server group name>]

    Specifies the name of the reverse proxy server group for which information will be output.

  • Example

    [wsadmin]>> ci
    ---------------------------------------------------------------------------------------------------------------------------------------------------
    | HTH-0 : Connection info                                                                                                                         |
    ---------------------------------------------------------------------------------------------------------------------------------------------------
    | No | Server |    Local Address    |    Remote Address    | Remote Type | Ssl | Status | Request Count | Response Count | Idle Time | Mapping No |
    ---------------------------------------------------------------------------------------------------------------------------------------------------
    | 0  | WJP-0  | 192.168.15.120:9900 | 192.168.15.120:40158 |     JSV     | No  | READY  |       1       |       1        |    23     |     -1     |
    | 1  | WJP-0  | 192.168.15.120:9900 | 192.168.15.120:40170 |     JSV     | No  | READY  |       1       |       1        |    13     |     -1     |
    | 2  | WJP-0  | 192.168.15.120:9900 | 192.168.15.120:40186 |     JSV     | No  | READY  |       1       |       1        |    42     |     -1     |
    | 3  | WJP-0  | 192.168.15.120:9900 | 192.168.15.120:40202 |     JSV     | No  | READY  |       1       |       1        |    31     |     -1     |
    | 4  | WJP-0  | 192.168.15.120:9900 | 192.168.15.120:40214 |     JSV     | No  | READY  |       1       |       1        |    26     |     -1     |
    | 5  | WJP-0  | 192.168.15.120:9900 | 192.168.15.120:40220 |     JSV     | No  | READY  |       1       |       1        |    12     |     -1     |
    | 6  | WJP-0  | 192.168.15.120:9900 | 192.168.15.120:40224 |     JSV     | No  | READY  |       0       |       0        |    27     |     -1     |
    | 7  | WJP-0  | 192.168.15.120:9900 | 192.168.15.120:40230 |     JSV     | No  | READY  |       0       |       0        |    27     |     -1     |
    | 8  | WJP-0  | 192.168.15.120:9900 | 192.168.15.120:40234 |     JSV     | No  | READY  |       0       |       0        |    27     |     -1     |
    | 9  | WJP-0  | 192.168.15.120:9900 | 192.168.15.120:40240 |     JSV     | No  | READY  |       0       |       0        |    27     |     -1     |
    | 21 | http1  | 192.168.15.120:8080 | 192.168.15.120:47098 |   CLIENT    | No  | READY  |       3       |       3        |    12     |     -1     |
    ---------------------------------------------------------------------------------------------------------------------------------------------------

    The following describes each output item.

    Item Description

    No

    The connection number managed internally by WebtoB.

    Server

    The server name managed internally by WebtoB.

    Local Address,
    Remote Address

    IP address and port number of the server and client.

    Remote Type

    The type of connection.

    • CLIENT: Connection with the client

    • CLIENT_WEBSOCKET: Websocket connection with the client

    • RPROXY: Connection with an internal reverse proxy server

    • RPROXY_PERSISTENT: Keep-Alive connection with an internal reverse proxy server.

    • RPROXY_WEBSOCKET: Websocket connection with an internal reverse proxy server.

    • JSV: Connection with an internal JEUS server.

    Ssl

    Specifies whether the connection is established using SSL.

    Status

    The status of the connection.

    • READY: Ready to receive requests from clients.

    • RUNNING: Processing the client’s request.

    Request Count

    The number of requests sent through this connection.

    Response Count

    The number of requests processed through this connection.

    Idle Time

    Idle time with no data exchanges.

    Mapping No

    The connection number associated with this connection.
    If it is a client connection, it displays the server connection number handling the request. If it is a server connection, it displays the client connection number that sent the request. If there is no associated connection, it displays -1.

exit

Exits the wsadmin tool.

  • Usage

    [wsadmin]>> exit

configValidator

The configValidator performs schema validation on WebtoB configuration files.

Before running WebtoB, you can check the verification results for the configuration file using the configValidator tool.

WebtoB’s default configuration file is webtob-config.json, and you can change it by setting the environment variable WEBTOB6_CONFIG_FILE_NAME.

  • Usage

    $ configValidator
  • Example

    Validating a Normal WebtoB Configuration File
    $ configValidator
    Config file path: ../config/webtob-config.json
    Schema file path: ../config/webtob-config.schema.json
    WEBTOB6_HOME_PATH = ../
    WEBTOB6_CONFIG_FILE_PATH = ../config/
    WEBTOB6_LIBRARY_PATH = ../lib/
    WEBTOB6_SSL_PATH = ../ssl/
    WEBTOB6_LICENSE_PATH = ../license/
    WEBTOB6_SCHEMA_PATH = ../schema/
    WEBTOB6_CONFIG_FILE_NAME = webtob-config.json
    ******* Start config validation *******
    1. Opened schema file
    2. Opened config file
    3. Config parsing finished
    4. Pre-validation process finished
    5. Validation using json-schema finished
    6. Post-validation process finished
    Config file "../config/webtob-config.json" is validated with schema file "../schema/webtob-config.schema.json"
    Success to load config files : webtob-config.json
    ******* Validation success *******
    Validating an Abnormal WebtoB Configuration File
    $ configValidator
    Config file path: ../config/webtob-config.json
    Schema file path: ../config/webtob-config.schema.json
    WEBTOB6_HOME_PATH = ../
    WEBTOB6_CONFIG_FILE_PATH = ../config/
    WEBTOB6_LIBRARY_PATH = ../lib/
    WEBTOB6_SSL_PATH = ../ssl/
    WEBTOB6_LICENSE_PATH = ../license/
    WEBTOB6_SCHEMA_PATH = ../schema/
    WEBTOB6_CONFIG_FILE_NAME = webtob-config.json
    ******* Start config validation *******
    1. Opened schema file
    2. Opened config file
    3. Config parsing finished
    4. Pre-validation process finished
    [Exception on json-schema validation][Config validation failed]At /node/hth_count of -1 - instance is below minimum of 1

mkpwd

mkpwd is a tool to support certificate_key_password in the SSL section.

When an encrypted private key is set in the SSL section, WebtoB prompts you to enter a passphrase every time it starts. To avoid repeatedly entering the passphrase, you can set the certificate_key_password. The mkpwd tool creates a passphrase file that stores the passphrase so that it can be applied to the certificate_key_password.

For more information on using certificate_key_password, refer to Configuration Items.

  • Usage

    $ mkpwd <file path> <SSL name>
    Options Description

    <file path>

    Name of the file used for certificate_key_password. The result of running mkpwd is saved to this file.

    <SSL name>

    The name set in the SSL section.

  • Example

    No Options Used
    $ mkpwd
    << Usage >>
    $ mkpwd file_path ssl_name
    	 file_path: output file for ssl certificate key password
    	 ssl_name: name of SSL section
    Speficying file_path and ssl_name
    $ mkpwd ssl.ppd ssl1
    Make password for SSL certificate key password
    Enter password: (Enter password)
    Successfully Added password for [ssl1] to a file [ssl.ppd].
    
    $ls -al ssl.ppd
    -rw-rw-r--  1 webtob webtob 14 Nov 6 12:34 ssl.ppd
  • Verifying File Contents

    $ cat ssl.ppd
    ssl1 dGVzdA==