mcp-ntopng
mcp-服务器-ntopng
NTOPNG 模型上下文协议服务器
NTOPNG的模型上下文协议服务器实现,使 AI 代理能够使用 NTOPNG 数据库查询网络监控数据。
此 MCP 服务器假设ntopng使用 ClickHouse 来存储历史流量和警报。请查看ntopng 的 ClickHouse
工具
fetch_ntopng_all_ifids从 ntopng 中检索所有可用的接口 ID。
get_ntopng_hosts_location获取主机的地理位置和附加信息。
fetch_ntopng_top_local_talkers检索指定接口的前 10 个本地对话者。
fetch_ntopng_top_remote_talkers检索指定接口的前 10 个远程对话者。
get_ntopng_all_alert_stats检索所有警报的统计信息。
get_ntopng_flow_alert_stats检索流量警报的统计数据。
get_ntopng_host_alert_stats检索主机警报的统计数据。
get_ntopng_interface_alert_stats检索接口警报的统计数据。
get_ntopng_mac_alert_stats检索 MAC 警报的统计数据。
get_ntopng_network_alert_stats检索网络警报的统计数据。
get_ntopng_snmp_device_alert_list检索 SNMP 设备警报列表。
get_ntopng_snmp_device_alert_stats检索 SNMP 设备警报的统计信息。
get_ntopng_system_alert_stats检索系统警报的统计数据。
query_ntopng_flows_data从 ntopng 流量数据库中检索详细的流量数据。
get_ntopng_top-k_flows从 ntopng 流数据库中检索前 k 个流数据。
get_ntopng_user_alert_stats检索用户警报的统计数据。
get_ntopng_flow_devices_stats检索所有流设备的统计数据。
get_ntopng_sflow_devices_stats检索所有 sFlow 设备的统计信息。
list_tables_ntopng_database列出 ntopng 数据库的表结构。
query_ntopng_database查询 ntopng Clickhouse 数据库。
Related MCP server: mcp-osint-server
地位
可与 Claude Desktop 应用程序和其他符合 MCP 的主机和客户端配合使用。
配置
创建或编辑位于以下位置的 Claude Desktop 配置文件:
在 macOS 上:
~/Library/Application Support/Claude/claude_desktop_config.json在 Windows 上:
%APPDATA%/Claude/claude_desktop_config.json
添加以下内容:
{
"mcpServers": {
"mcp-ntopng": {
"command": "/path/to/your/uv-binary",
"args": ["run", "--with", "mcp-ntopng", "--python", "3.13", "mcp-ntopng"]
"env": {
"NTOPNG_HOST": "<ntopng-host>",
"NTOPNG_DBPORT": "<ntopng-dbport>",
"NTOPNG_DBUSER": "<ntopng-dbuser>",
"NTOPNG_DBPASSWORD": "<ntopng-dbpassword>",
"NTOPNG_SECURE": "true",
"NTOPNG_VERIFY": "true",
"NTOPNG_CONNECT_TIMEOUT": "30",
"NTOPNG_SEND_RECEIVE_TIMEOUT": "300",
"NTOPNG_API_KEY": "NTOPNG_TOKEN"
}
}
}
}将
/path/to/your/uv-binary替换为uv可执行文件的绝对路径。使用which uv查找路径。这可确保启动服务器时使用正确版本的uv。重新启动 Claude Desktop 以应用更改。
发展
在
claude_desktop_config.json文件或存储库根目录中的.env文件中设置环境变量。
NTOPNG_HOST=localhost
NTOPNG_PORT=9000
NTOPNG_USER=default
NTOPNG_PASSWORD=运行
uv sync来安装依赖项。要安装uv,请按照此处的说明操作。然后执行source .venv/bin/activate。使用
uv pip install -e .从项目主目录安装mcp-ntopng包。为了方便测试,您可以运行
mcp dev mcp_ntopng/mcp_server.py来启动 MCP 服务器。请使用合适的聊天客户端进行更改
环境变量
以下环境变量用于配置数据库连接:
NTOPNG_HOST:ntopng服务器的主机名NTOPNG_DBUSER:Clickhouse DB 身份验证的用户名NTOPNG_DBPASSWORD:Clickhouse DB 身份验证的密码NTOPNG_API_KEY:ntopng身份验证令牌。
选修的
NTOPNG_DBPORT:ntopng服务器中 Clickhouse DB 的端口号默认值:如果启用 HTTPS,
9000;如果禁用,8123通常不需要设置,除非使用非标准端口
NTOPNG_SECURE:启用/禁用 TLS 连接默认值:
false设置为
true以实现安全的 TLS 连接
NTOPNG_VERIFY:启用/禁用 SSL 证书验证默认值:
true设置为 `false 以禁用证书验证(不建议用于生产)
NTOPNG_CONNECT_TIMEOUT:连接超时(秒)默认值:`30
如果遇到连接超时,请增加此值
NTOPNG_SEND_RECEIVE_TIMEOUT:发送/接收超时(秒)默认值:
300对于长时间运行的查询,请增加此值
有关设置与 Clickhouse 的 TLS 连接的详细信息,请查看
ntopng文档中的TLS 设置。
发展
在本地机器上安装包:
$ uv sync
$ uv pip install -e .运行 MCP 检查器
$ cd mcp_ntopng
$ source .env
$ CLIENT_PORT=8077 SERVER_PORT=8078 mcp dev run_mcp_ntopng.py --with clickhouse-driver --with python-dotenv --with uvicorn --with pip-system-certs使用 Claude Desktop 中的本地库。
查找:/Users/marco/Library/Application\Support/Claude/claude_desktop_config.json
编辑 claude_desktop_config.json 更改本地路径:
{
"mcpServers": {
"mcp-ntopng": {
"command": "/Users/marco/Development/claude/mcp-server-ntopng/.venv/bin/python",
"args": [
"/Users/marco/Development/claude/mcp-server-ntopng/run_mcp_ntopng.py"
],
"env": {
"NTOPNG_HOST": "marcoeg-nod004.ntoplink.com",
"NTOPNG_DBPORT": "9000",
"NTOPNG_DBUSER": "default",
"NTOPNG_DBPASSWORD": "",
"NTOPNG_SECURE": "false",
"NTOPNG_VERIFY": "false",
"NTOPNG_CONNECT_TIMEOUT": "30",
"NTOPNG_SEND_RECEIVE_TIMEOUT": "300",
"SELECT_QUERY_TIMEOUT_SECS": "30",
"NTOPNG_API_KEY": "NTOPNG_TOKEN"
}
}
}
}This server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Servers
- Apache 2.0
- Flicense-qualityDmaintenanceMCP server to perform various OSINT tasks by leveraging common network reconnaissance tools.46

DevHelm MCP Serverofficial
AlicenseBqualityBmaintenanceMCP server for uptime monitoring, incidents, alerting, and dependency status.1001MIT- FlicenseBqualityCmaintenanceMCP server for network-troubleshooting PCAP analysis via tshark, enabling users to analyze PCAP files, detect anomalies, and troubleshoot network issues.22
Related MCP Connectors
MCP server for ScanMalware.com URL scanning, malware detection, and analysis.
An MCP server giving access to Grafana dashboards, data and more.
Autopilot MCP server for GEO analyses, reports, content, audits, memories and agents.
Appeared in Searches
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/marcoeg/mcp-server-ntopng'
If you have feedback or need assistance with the MCP directory API, please join our Discord server