Skip to content

Commit

Permalink
add-GraphMemoryExceeded-(-2600)faq-and-move-port-guide-to-appendix (#…
Browse files Browse the repository at this point in the history
  • Loading branch information
abby-cyber authored Jul 21, 2023
1 parent bdaf629 commit 4f3b7cc
Show file tree
Hide file tree
Showing 4 changed files with 54 additions and 40 deletions.
45 changes: 11 additions & 34 deletions docs-2.0/20.appendix/0.FAQ.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,16 @@ NebulaGraph is still under development. Its behavior changes from time to time.

## About execution errors

### "How to resolve the error `-1005:GraphMemoryExceeded: (-2600)`?"

This error is issued by the Memory Tracker when it observes that memory usage has exceeded a set threshold. This mechanism can help avoid service processes from being terminated by the system's OOM (Out of Memory) killer. Steps to resolve:

1. Check memory usage: First, you need to check the memory usage during the execution of the command. If the memory usage is indeed high, then this error might be expected.

2. Check the configuration of the Memory Tracker: If the memory usage is not high, check the relevant configurations of the Memory Tracker. These include `memory_tracker_untracked_reserved_memory_mb` (untracked reserved memory in MB), `memory_tracker_limit_ratio` (memory limit ratio), and `memory_purge_enabled` (whether memory purge is enabled). For the configuration of the Memory Tracker, see [memory tracker configuration](../5.configurations-and-logs/1.configurations/4.storage-config.md#memory_tracker_configurations).

3. Optimize configurations: Adjust these configurations according to the actual situation. For example, if the available memory limit is too low, you can increase the value of `memory_tracker_limit_ratio`.

### "How to resolve the error `SemanticError: Missing yield clause.`?"

Starting with NebulaGraph 3.0.0, the statements `LOOKUP`, `GO`, and `FETCH` must output results with the `YIELD` clause. For more information, see [YIELD](../3.ngql-guide/8.clauses-and-options/yield.md).
Expand Down Expand Up @@ -555,40 +565,7 @@ If you have not modified the predefined ports in the [Configurations](../5.confi

If you have customized the configuration files and changed the predefined ports, find the port numbers in your configuration files and open them on the firewalls.

For those eco-tools, see the corresponding document.

The following are the default ports used by NebulaGraph core and peripheral tools.

| No. | Product / Service | Type | Default | Description |
| :--- | :--------------------- | :--- | :---------------------------- | :----------------------------------------------------------- |
| 1 | NebulaGraph | TCP | 9669 | Graph service RPC daemon listening port (commonly used for client connections to the Graph service). |
| 2 | NebulaGraph | TCP | 19669 | Graph service HTTP port. |
| 3 | NebulaGraph | TCP | 19670 | Graph service HTTP/2 port. (Deprecated after version 3.x) |
| 4 | NebulaGraph | TCP | 9559 | Meta service RPC daemon listening port. (Commonly used by Graph and Storage services for querying and updating metadata in the graph database). |
| 5 | NebulaGraph | TCP | 9560 | Raft communication port between Meta services. |
| 6 | NebulaGraph | TCP | 19559 | Meta service HTTP port. |
| 7 | NebulaGraph | TCP | 19560 | Meta service HTTP/2 port. (Deprecated after version 3.x) |
| 8 | NebulaGraph | TCP | 9777 | Drainer service port in Storage services (exposed only in Enterprise Edition clusters). |
| 9 | NebulaGraph | TCP | 9778 | Admin service port in Storage services. |
| 10 | NebulaGraph | TCP | 9779 | Storage service RPC daemon listening port. (Commonly used by Graph services for data storage-related operations, such as reading, writing, or deleting data). |
| 11 | NebulaGraph | TCP | 9780 | Raft communication port between Storage services. |
| 12 | NebulaGraph | TCP | 19779 | Storage service HTTP port. |
| 13 | NebulaGraph | TCP | 19780 | Storage service HTTP/2 port. (Deprecated after version 3.x) |
| 14 | NebulaGraph | TCP | 8888 | Backup and restore Agent service port. The Agent is a daemon running on each machine in the cluster, responsible for starting and stopping NebulaGraph services and uploading and downloading backup files. |
| 15 | NebulaGraph | TCP | 9789, 9790, and 9788 | Full-text index Raft Listener port, which reads data from Storage services and writes it to the Elasticsearch cluster.<br/>Also the port for Storage Listener in inter-cluster data synchronization, used for synchronizing Storage data from the primary cluster. Ports 9790 and 9788 are generated by adding and subtracting one from port 9789. |
| 16 | NebulaGraph | TCP | 9200 | NebulaGraph uses this port for HTTP communication with Elasticsearch to perform full-text search queries and manage full-text indexes. |
| 17 | NebulaGraph | TCP | 9569, 9570, and 9568| Meta Listener port in inter-cluster data synchronization, used for synchronizing Meta data from the primary cluster. Ports 9570 and 9568 are generated by adding and subtracting one from port 9569. |
| 18 | NebulaGraph | TCP | 9889, 9890, and 9888 |Drainer service port in inter-cluster data synchronization, used for synchronizing Storage and Meta data to the primary cluster. Ports 9890 and 9888 are generated by adding and subtracting one from port 9889. |
| 19 | NebulaGraph Studio | TCP | 7001 | Studio web service port. |
| 20 | NebulaGraph Dashboard | TCP | 8090 | Nebula HTTP Gateway dependency service port. Provides an HTTP interface for cluster services to interact with the NebulaGraph database using nGQL statements. |
| 21 | NebulaGraph Dashboard | TCP | 9200 | Nebula Stats Exporter dependency service port. Collects cluster performance metrics, including service IP addresses, versions, and monitoring metrics (such as query count, query latency, heartbeat latency, etc.). |
| 22 | NebulaGraph Dashboard | TCP | 9100 | Node Exporter dependency service port. Collects resource information for machines in the cluster, including CPU, memory, load, disk, and traffic. |
| 23 | NebulaGraph Dashboard | TCP | 9091 | Prometheus service port. Time-series database for storing monitoring data. |
| 24 | NebulaGraph Dashboard | TCP | 7003 | Dashboard Community Edition web service port. |
| 25 | NebulaGraph Dashboard | TCP | 7005 | Dashboard Enterprise Edition web service port. |
| 26 | NebulaGraph Dashboard | TCP | 9093 | Alertmanager service port. Receives alerts from Prometheus and sends alert notifications to Dashboard. |
| 27 | NebulaGraph Explorer | TCP | 7002 | Explorer web service port. |

For more port information, see [Port Guide for Company Products](port-guide.md).

### "How to test whether a port is open or closed?"

Expand Down
34 changes: 34 additions & 0 deletions docs-2.0/20.appendix/port-guide.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
# Port guide for company products

The following are the default ports used by NebulaGraph core and peripheral tools.

| No. | Product / Service | Type | Default | Description |
| :--- | :--------------------- | :--- | :---------------------------- | :----------------------------------------------------------- |
| 1 | NebulaGraph | TCP | 9669 | Graph service RPC daemon listening port (commonly used for client connections to the Graph service). |
| 2 | NebulaGraph | TCP | 19669 | Graph service HTTP port. |
| 3 | NebulaGraph | TCP | 19670 | Graph service HTTP/2 port. (Deprecated after version 3.x) |
| 4 | NebulaGraph | TCP | 9559 | Meta service RPC daemon listening port. (Commonly used by Graph and Storage services for querying and updating metadata in the graph database). |
| 5 | NebulaGraph | TCP | 9560 | Raft communication port between Meta services. |
| 6 | NebulaGraph | TCP | 19559 | Meta service HTTP port. |
| 7 | NebulaGraph | TCP | 19560 | Meta service HTTP/2 port. (Deprecated after version 3.x) |
| 8 | NebulaGraph | TCP | 9777 | Drainer service port in Storage services (exposed only in Enterprise Edition clusters). |
| 9 | NebulaGraph | TCP | 9778 | Admin service port in Storage services. |
| 10 | NebulaGraph | TCP | 9779 | Storage service RPC daemon listening port. (Commonly used by Graph services for data storage-related operations, such as reading, writing, or deleting data). |
| 11 | NebulaGraph | TCP | 9780 | Raft communication port between Storage services. |
| 12 | NebulaGraph | TCP | 19779 | Storage service HTTP port. |
| 13 | NebulaGraph | TCP | 19780 | Storage service HTTP/2 port. (Deprecated after version 3.x) |
| 14 | NebulaGraph | TCP | 8888 | Backup and restore Agent service port. The Agent is a daemon running on each machine in the cluster, responsible for starting and stopping NebulaGraph services and uploading and downloading backup files. |
| 15 | NebulaGraph | TCP | 9789, 9790, and 9788 | Full-text index Raft Listener port, which reads data from Storage services and writes it to the Elasticsearch cluster.<br/>Also the port for Storage Listener in inter-cluster data synchronization, used for synchronizing Storage data from the primary cluster. Ports 9790 and 9788 are generated by adding and subtracting one from port 9789. |
| 16 | NebulaGraph | TCP | 9200 | NebulaGraph uses this port for HTTP communication with Elasticsearch to perform full-text search queries and manage full-text indexes. |
| 17 | NebulaGraph | TCP | 9569, 9570, and 9568| Meta Listener port in inter-cluster data synchronization, used for synchronizing Meta data from the primary cluster. Ports 9570 and 9568 are generated by adding and subtracting one from port 9569. |
| 18 | NebulaGraph | TCP | 9889, 9890, and 9888 |Drainer service port in inter-cluster data synchronization, used for synchronizing Storage and Meta data to the primary cluster. Ports 9890 and 9888 are generated by adding and subtracting one from port 9889. |
| 19 | NebulaGraph Studio | TCP | 7001 | Studio web service port. |
| 20 | NebulaGraph Dashboard | TCP | 8090 | Nebula HTTP Gateway dependency service port. Provides an HTTP interface for cluster services to interact with the NebulaGraph database using nGQL statements. |
| 21 | NebulaGraph Dashboard | TCP | 9200 | Nebula Stats Exporter dependency service port. Collects cluster performance metrics, including service IP addresses, versions, and monitoring metrics (such as query count, query latency, heartbeat latency, etc.). |
| 22 | NebulaGraph Dashboard | TCP | 9100 | Node Exporter dependency service port. Collects resource information for machines in the cluster, including CPU, memory, load, disk, and traffic. |
| 23 | NebulaGraph Dashboard | TCP | 9091 | Prometheus service port. Time-series database for storing monitoring data. |
| 24 | NebulaGraph Dashboard | TCP | 7003 | Dashboard Community Edition web service port. |
| 25 | NebulaGraph Dashboard | TCP | 7005 | Dashboard Enterprise Edition web service port. |
| 26 | NebulaGraph Dashboard | TCP | 9093 | Alertmanager service port. Receives alerts from Prometheus and sends alert notifications to Dashboard. |
| 27 | NebulaGraph Explorer | TCP | 7002 | Explorer web service port. |
| 28 | License Manager | TCP | 9119 | The port for the License Manager (LM) service. The LM service is used for managing licenses (only used in enterprise clusters).|
Original file line number Diff line number Diff line change
Expand Up @@ -199,7 +199,7 @@ For more information, see [RocksDB official documentation](https://rocksdb.org/)
| `negative_pool_capacity` | `50` | The negative pool size in MB. |
| `negative_item_ttl` | `300` | The TTL in seconds for negative items in the cache. | -->

## Black box configurations
## Black Box configurations

!!! enterpriseonly

Expand All @@ -214,14 +214,16 @@ For more information, see [RocksDB official documentation](https://rocksdb.org/)

{{ ent.ent_end }}

## Memory tracker configurations
## Memory Tracker configurations

For details about Memory Tracker, see [Memory Tracker: Memory Management Practice in NebulaGraph Database](https://www.nebula-graph.io/posts/memory-tracker-practices)

| Name | Predefined value | Description |Whether supports runtime dynamic modifications|
| :------------------- | :------------------------ | :------------------------------------------ |:------------------|
|`memory_tracker_limit_ratio` |`0.8` | The value of this parameter can be set to `(0, 1]`, `2`, and `3`.<br/>`(0, 1]`: The percentage of free memory. When the free memory is lower than this value, NebulaGraph stops accepting queries. <br/> Calculated as follows: <br/> `Free memory / (Total memory - Reserved memory)` <br/> **Note**: For clusters with a mixed-used environment, the value of `memory_tracker_limit_ratio` should be set to a **lower** value. For example, when Graphd is expected to occupy only 50% of memory, the value can be set to less than `0.5`.<br/>`2`: Dynamic Self Adaptive mode. MemoryTracker dynamically adjusts the available memory based on the system's current available memory. <br/>**Note**: This feature is experimental. As memory usage cannot be monitored in real time in dynamic adaptive mode, an OOM error may still occur to handle large memory allocations. <br/>`3`: Disable MemoryTracker. MemoryTracker only logs memory usage and does not interfere with executions even if the limit is exceeded.| Yes|
|`memory_tracker_untracked_reserved_memory_mb` |`50`| The reserved memory that is not tracked by the memory tracker. Unit: MB.| Yes|
|`memory_tracker_detail_log` |`false` | Whether to enable the memory tracker log. When the value is `true`, the memory tracker log is generated.| Yes|
|`memory_tracker_detail_log_interval_ms` |`60000`| The time interval for generating the memory tracker log. Unit: Millisecond. `memory_tracker_detail_log` is `true` when this parameter takes effect.| Yes|
|`memory_tracker_untracked_reserved_memory_mb` |`50`| The reserved memory that is not tracked by the Memory Tracker. Unit: MB.| Yes|
|`memory_tracker_detail_log` |`false` | Whether to enable the Memory Tracker log. When the value is `true`, the Memory Tracker log is generated.| Yes|
|`memory_tracker_detail_log_interval_ms` |`60000`| The time interval for generating the Memory Tracker log. Unit: Millisecond. `memory_tracker_detail_log` is `true` when this parameter takes effect.| Yes|
|`memory_purge_enabled` |`true` |Whether to enable the memory purge feature. When the value is `true`, the memory purge feature is enabled.| Yes|
|`memory_purge_interval_seconds` |`10` |The time interval for the memory purge feature to purge memory. Unit: Second. This parameter only takes effect if `memory_purge_enabled` is set to true.| Yes|

Expand Down
3 changes: 2 additions & 1 deletion mkdocs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -744,6 +744,7 @@ nav:
- Flink Connector: nebula-flink-connector.md

- Bench: nebula-bench.md
- FAQ: 20.appendix/0.FAQ.md

- Appendix:
- Release Note:
Expand All @@ -755,8 +756,8 @@ nav:
- NebulaGraph Dashboard Enterprise: 20.appendix/release-notes/dashboard-ent-release-note.md
- NebulaGraph Explorer: 20.appendix/release-notes/explorer-release-note.md
- Learning path: 20.appendix/learning-path.md
- FAQ: 20.appendix/0.FAQ.md
- Ecosystem tools: 20.appendix/6.eco-tool-version.md
- Port guide for company products: 20.appendix/port-guide.md
- Write tools: 20.appendix/write-tools.md
- How to contribute: 15.contribution/how-to-contribute.md
- History timeline: 20.appendix/history.md
Expand Down

0 comments on commit 4f3b7cc

Please sign in to comment.