Page cover image

status

Published: March 2025 | Last updated: March 2025

Overview

The status RPC method provides diagnostic information about the blockchain storage system's operational state. It shows the current condition of the storage worker and lists the most recent storage jobs (both completed and in progress). This command is essential for monitoring system health and troubleshooting issues with file storage operations.

Syntax

status

Description

When you invoke the status method, the Lynx daemon checks the current state of the storage worker process and retrieves information about recent jobs from the work queue. This gives you immediate visibility into the system's activity and helps identify potential bottlenecks or errors in the storage subsystem. The information is particularly valuable when diagnosing problems with store or fetch operations that may appear unresponsive.

Parameters

This method does not accept any parameters.

Returns

The method returns an array containing the worker status and recent job information:

[
  "WORKER_IDLE",
  "00112233445566778899aabbccddeeff, Fetch operation completed successfully",
  "aabbccddeeff00112233445566778899, Store operation failed: file not found",
  ...
]

The array contains the following elements:

  1. First element: The current status of the storage worker, which will be one of:

    • WORKER_IDLE - The worker is available and ready to process new storage jobs

    • WORKER_BUSY - The worker is currently processing a storage job

    • WORKER_ERROR - The worker has encountered an error and may need attention

  2. Subsequent elements: The most recent job results (up to 15 entries), with each entry containing:

    • The UUID of the file involved in the operation

    • A status message describing the result of the operation

The job list is ordered chronologically with the most recent jobs appearing last in the array.

Usage Notes

  • No authentication is required to use this command, making it useful for basic system diagnostics

  • The command only shows the most recent 15 job results to prevent overwhelming output

  • You can use this command to verify if the storage worker is available before submitting large storage jobs

  • If the worker shows WORKER_ERROR status, you may need to restart the daemon to resolve issues

Examples

Check the current system status

lynx-cli status

Output when the system is idle:

[
  "WORKER_IDLE",
  "00112233445566778899aabbccddeeff, Fetch completed",
  "aabbccddeeff00112233445566778899, Store completed"
]

Output when the system is processing jobs:

[
  "WORKER_BUSY",
  "00112233445566778899aabbccddeeff, Fetch completed",
  "aabbccddeeff00112233445566778899, Store in progress"
]

Using JSON-RPC:

curl --data-binary '{"jsonrpc": "1.0", "id": "curltest", "method": "status", "params": []}' -H 'content-type: text/plain;' http://127.0.0.1:9332/

Implementation Notes

  • The system maintains a history of job results that persists until the daemon is restarted

  • Only the most recent 15 job results are displayed to keep the output manageable

  • While this command provides operational status, it does not include detailed performance metrics

Last updated