{"id":23215443,"url":"https://github.com/cctyl/starsnode","last_synced_at":"2025-07-31T09:33:33.430Z","repository":{"id":250973520,"uuid":"835998342","full_name":"cctyl/starsnode","owner":"cctyl","description":"A cross-platform, lightweight, and high-performance system monitoring software based on WebSocket;基于websocket跨平台、轻量级、高性能的系统状态监控软件","archived":false,"fork":false,"pushed_at":"2025-01-05T10:53:15.000Z","size":1357,"stargazers_count":25,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-02-11T09:50:36.429Z","etag":null,"topics":["nodejs","qt6","vue","websocket"],"latest_commit_sha":null,"homepage":"https://www.bilibili.com/video/BV1DRrpYfE2m/","language":"C++","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/cctyl.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-07-31T00:41:35.000Z","updated_at":"2025-01-26T11:46:52.000Z","dependencies_parsed_at":"2025-02-11T09:46:25.977Z","dependency_job_id":"e86cfdfa-cdd0-4553-851d-c86a1bcbce3b","html_url":"https://github.com/cctyl/starsnode","commit_stats":null,"previous_names":["cctyl/starsnode"],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cctyl%2Fstarsnode","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cctyl%2Fstarsnode/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cctyl%2Fstarsnode/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cctyl%2Fstarsnode/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/cctyl","download_url":"https://codeload.github.com/cctyl/starsnode/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247345788,"owners_count":20924098,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["nodejs","qt6","vue","websocket"],"created_at":"2024-12-18T20:16:32.516Z","updated_at":"2025-07-16T16:35:02.243Z","avatar_url":"https://github.com/cctyl.png","language":"C++","funding_links":[],"categories":[],"sub_categories":[],"readme":"# starsnode\n\n## 简介\n\n[starsnode]是一个系统状态监控软件。\n\n展示的信息包括：cpu、内存、硬盘、网速、网卡等信息。\n\n### 优点\n\n#### 高性能\n\nrust编写的原生客户端，只占用%0.几的cpu，最低3.9M的内存(不开启ip信息的情况，开启ipinfo 需要使用openssl会带来一定的内存开销)\n(c++原生客户端和qt客户端不再推荐)\n\n#### 轻量级\n\n软件小，依赖少，编译十分简单，同时提供编译好的客户端\n\n#### 跨平台\n\nnodejs客户端几乎适配所有主流系统，win、linux、macos、android。\n如要求性能，也可使用rust客户端，同样支持跨平台\n\n本库的js服务端参考了该项目：https://github.com/chaos-zhu/easynode   感谢原作者。\n\n## 效果图\n\n\u003cp align=\"center\"\u003e\n    \u003cimg src=\"./img/a.png\" \u003e\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n    \u003cimg src=\"./img/b.png\" \u003e\n\u003c/p\u003e\n\n## 平台构成\n\n由1个服务端+n个客户端+web展示页面组成。三个部分每部分都可以单独部署，通过websocket进行数据传输。\n\n各客户端首先将信息通过ws上报给服务端，服务端进行汇总。用户可以通过web页面查看到汇总后数据。\n\n## 客户端选择\n\n### 如果你不考虑性能问题\n\n选择js客户端，兼容性好，bug少，稳定性强。\n\n### 如果对性能敏感\n\n统一推荐rust客户端。有良好的跨平台支持\n\n~~win平台，使用qt客户端。~~ \n\n~~linux平台，如果内核版本比较新，比如ubuntu22以上，建议使用qt客户端。~~ \n\n~~如果是历史平台，比如centos系列，建议使用linux客户端，缺点是稳定性可能稍差。~~ \n\n~~macos，理论上也可以使用linux客户端，但是编译是个问题~~ \n\n\n## 性能展示\n\n### rust客户端\n\n\n\n\n#### win10 8c 16g x64\nwin10实测，软件大小只有3.67M, 只占用6m左右的内存，百分之0.3的cpu。\n\u003cp align=\"center\"\u003e\n    \u003cimg src=\"./img/rust_win10_8c_16g_x64.png\" \u003e\n\u003c/p\u003e\n\n\n#### debian 2c 4g x64\n开启ip信息后，占11M左右，0.3%cpu\n\n\u003cp align=\"center\"\u003e\n    \u003cimg src=\"./img/rust_debian_2c_4g_x64.png\" \u003e\n\u003c/p\u003e\n\n#### armbian 4c 4g x64\n\n开启ip信息后，占7M左右，0.3%cpu\n\n\u003cp align=\"center\"\u003e\n    \u003cimg src=\"./img/rust_armbian_4c_4g_x64.png\" \u003e\n\u003c/p\u003e\n## 部署方式\n\n\n\n\n### 配置\n服务端的配置文件在 `server/config.js`，只需要设置port和token即可。\n\n\n\n\nnodejs客户端的配置文件，在其目录下的config.js 中，需要设置服务端地址(serverHost)，端口(port)，token。\nendpointName可省略，这是用于给客户端命名的。\n\n\n\nrust配置文件，在各自目录下的 config.json 文件中，需要设置服务端地址(server)，端口(port)，token。\n使用时，只需要把这个config.json，放在可执行文件的旁边即可。\n\n\n\nweb端的配置写到了 simple-list.html中的625行：\n```\nconst ws = new WebSocket(\"ws://服务端地址:服务器端口?token=你的token\u0026type=view\u0026endpointName=web\");\n```\n\n### web端\n\n你可以选择部署到nginx中，也可以直接双击simple-list.html 在本地打开，如果你能直接访问服务端的话\n\n### 服务端\n\n\n```\n# 需要安装 nodejs16 及以上\n# 下载release文件中的server并解压\ncd server\nnpm install\n#直接启动\nnode app/server.js\n\n#或使用pm2启动，需要提前安装pm2，win平台似乎是不支持pm2的\n#pm2 start app/server.js --name starsnode\n\n```\n\n### js客户端\n\n```\n# 需要安装 nodejs16 及以上\n# 下载release文件中js-client并解压\ncd js-client\nnpm install\n#直接启动\nnode app/client.js\n\n#或使用pm2启动，需要提前安装pm2，win平台似乎是不支持pm2的\n#pm2 start app/client.js --name starsnode\n\n```\n\n### Rust客户端\n\n#### win环境\n我已经提供了打包后的exe文件，直接到release下载即可，双击启动即可\n\n#### 其他平台\n- 安装rust\n\n- 执行 `cargo build --release` ，然后执行生成的可执行文件\n注意，国内依赖下载可能比较慢，可以配置一下国内镜像来加速下载\n\n\n\n\n\n\n### qt客户端\n不再推荐使用，如有需要，参考 other-client.md\n### linux客户端\n不再推荐使用，如有需要，参考 other-client.md\n\n\n\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcctyl%2Fstarsnode","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcctyl%2Fstarsnode","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcctyl%2Fstarsnode/lists"}