🦞龙虾养殖小技巧

在深入体验这个东西之前,其实我并未对龙虾抱有太高的期望。不过这几天实际使用下来,感觉还算可以,最起码没那么智障,一些简单的事情也能给处理好。

然而,龙虾虽好,但是养殖却还是稍显麻烦。尤其是系统配置不高的情况下,最开始的时候一切都配置好了,结果在某天晚上gateway就再也启动不了了,启动的的时候就报内存溢出。cpu和内存都直接跑满,等降下来之后,龙虾也跟着死了。刚开始以为是配置问题,改错东西导致启动失败了,结果在回滚镜像之后依然报错,这个镜像是刚安装好的时候创建的镜像。那么此时就有另外一个问题了,同样的镜像为什么系统重启之后就启动不了了?

当时没想这么多,解决办法是备份memory文件等进行重装,好在重装之后接本的功能和代码都在,让龙虾从新加载配置文件,也恢复到了之前的状态。不过,在重装的时候npm源也是个问题,可以考虑直接修改系统的npm源:

npm config set registry https://registry.npmmirror.com

检查修改是否生效:

npm config get registry

另外一个,那就是我给龙虾外层套了一层认证,当然这个做法有点傻,但是呢。这些乱七八糟的东西直接暴露出来总是多少感觉有点问题,于是还是套了一层nginx的认证。

毕竟,前几天周鸿祎还吆喝发现了龙虾的oday漏洞。

相关登录界面实现参考:https://cnb.cool/oba.by/baby-claw

然而,安装之后,昨天尝试更新龙虾,结果更新之后重启又开始报内存溢出,这就有点尴尬了,直接运行doctor:

ubuntu@VM-0-11-ubuntu:~$ openclaw doctor

🦞 OpenClaw 2026.3.23-2 (77e4) — I'm like tmux: confusing at first, then suddenly you can't live without me.

▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄
██░▄▄▄░██░▄▄░██░▄▄▄██░▀██░██░▄▄▀██░████░▄▄▀██░███░██
██░███░██░▀▀░██░▄▄▄██░█░█░██░█████░████░▀▀░██░█░█░██
██░▀▀▀░██░█████░▀▀▀██░██▄░██░▀▀▄██░▀▀░█░██░██▄▀▄▀▄██
▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
                  🦞 OPENCLAW 🦞                    
 
┌  OpenClaw doctor
│
◇  Update ──────────────────────────────────────────────────────────────────────────────────╮
│                                                                                           │
│  This install is not a git checkout.                                                      │
│  Run `openclaw update` to update via your package manager (npm/pnpm), then rerun doctor.  │
│                                                                                           │
├───────────────────────────────────────────────────────────────────────────────────────────╯
│
◇  Startup optimization ─────────────────────────────────────────────────────────────────────╮
│                                                                                            │
│  - NODE_COMPILE_CACHE is not set; repeated CLI runs can be slower on small hosts (Pi/VM).  │
│  - OPENCLAW_NO_RESPAWN is not set to 1; set it to avoid extra startup overhead from        │
│    self-respawn.                                                                           │
│  - Suggested env for low-power hosts:                                                      │
│    export NODE_COMPILE_CACHE=/var/tmp/openclaw-compile-cache                               │
│    mkdir -p /var/tmp/openclaw-compile-cache                                                │
│    export OPENCLAW_NO_RESPAWN=1                                                            │
│                                                                                            │
├────────────────────────────────────────────────────────────────────────────────────────────╯
13:24:32 [plugins] plugins.allow is empty; discovered non-bundled plugins may auto-load: openclaw-qqbot (/home/ubuntu/.openclaw/extensions/openclaw-qqbot/index.ts). Set plugins.allow to explicit trusted ids.
[qqbot-channel-api] Registered QQ channel API proxy tool
[qqbot-remind] Registered QQBot remind tool
│
◇  Archive 1 orphan transcript file in ~/.openclaw/agents/main/sessions? This only renames them to *.deleted.<timestamp>.
│  No
│
◇  State integrity ─────────────────────────────────────────────────────────────────────────╮
│                                                                                           │
│  - OAuth dir not present (~/.openclaw/credentials). Skipping create because no            │
│    WhatsApp/pairing channel config is active.                                             │
│  - Found 1 orphan transcript file in ~/.openclaw/agents/main/sessions.                    │
│    These .jsonl files are no longer referenced by sessions.json, so they are not part of  │
│    any active session history.                                                            │
│    Doctor can archive them safely by renaming each file to *.deleted.<timestamp>.         │
│    Examples: 9ede0dd4-5344-4156-a156-a9035538b1cb0d.jsonl                                   │
│                                                                                           │
├───────────────────────────────────────────────────────────────────────────────────────────╯
│
◇  Security ─────────────────────────────────╮
│                                            │
│  - No channel security warnings detected.  │
│  - Run: openclaw security audit --deep     │
│                                            │
├────────────────────────────────────────────╯
│
◇  Systemd ───────────────────────────────────────────────────────────────────────────╮
│                                                                                     │
│  Gateway runs as a systemd user service. Without lingering, systemd stops the user  │
│  session on logout/idle and kills the Gateway.                                      │
│  We can enable lingering now (may require sudo; writes /var/lib/systemd/linger).    │
│                                                                                     │
├─────────────────────────────────────────────────────────────────────────────────────╯
│
◇  Enable systemd lingering for ubuntu?
│  Yes
│
◇  Systemd ───────────────────────────────╮
│                                         │
│  Enabled systemd lingering for ubuntu.  │
│                                         │
├─────────────────────────────────────────╯

这时候才发现关键性的几行:

◇  Startup optimization ─────────────────────────────────────────────────────────────────────╮
│                                                                                            │
│  - NODE_COMPILE_CACHE is not set; repeated CLI runs can be slower on small hosts (Pi/VM).  │
│  - OPENCLAW_NO_RESPAWN is not set to 1; set it to avoid extra startup overhead from        │
│    self-respawn.                                                                           │
│  - Suggested env for low-power hosts:                                                      │
│    export NODE_COMPILE_CACHE=/var/tmp/openclaw-compile-cache                               │
│    mkdir -p /var/tmp/openclaw-compile-cache                                                │
│    export OPENCLAW_NO_RESPAWN=1                                                            │
│                                                                                            │
├────────────────────────────────────────────────────────────────────────────────────────────╯

这个startup 优化,不知道是不是针对gateway的启动也有效。不过在升级到最新版之后,感觉启动稍微顺畅了一点。似乎没那么卡了。

新版本貌似也同时修复了用量显示问题,上个版本,不管怎么查询用量都只显示今天的,新版貌似是没问题了:

服务器作为一个比较干净的环境,如果要实现一些其他的功能,就得能够进行文件快速交互,所以文件上传下载也就是一个必备的技能,推荐filebrower:

至此对我来说,一个简单的勉强能用的龙虾就实现了。可以尝试各种工作了:

1. 手搓elf可执行文件

2.给我发布闺蜜圈wiki的文章:

3.批量创建停机申请表:

skill这个东西,可以有,但是也不是必须的。

 



闺蜜圈APP

You may also like

21 comments

  1. Level 1
    Google Chrome 125.0.6422.165 Google Chrome 125.0.6422.165 Android 13 Android 13 cn中国–中国广播电视网络有限公司 IPv6

    终于抢到首评啦!首图太漂亮了~你们都在养龙虾了,我还没开始

  2. Level 3
    Google Chrome 146.0.0.0 Google Chrome 146.0.0.0 Windows 11 x64 Edition Windows 11 x64 Edition cn中国–山东–青岛 联通 IPv4

    虚拟世界得养个小龙虾。这个小帮手不错滴的感觉。虽然我没问他几个问题。

    1. 公主 Queen Queen 
      Google Chrome 142.0.0.0 Google Chrome 142.0.0.0 Mac OS X  10.15.7 Mac OS X 10.15.7 cn中国–山东省–青岛市–李沧区–中国联通–3GNET网络 IPv6

      还行,能做点事情,不过有时候也挺傻的

    1. 公主 Queen Queen 
      Google Chrome 142.0.0.0 Google Chrome 142.0.0.0 Mac OS X  10.15.7 Mac OS X 10.15.7 cn中国–山东省–青岛市–李沧区–中国联通–3GNET网络 IPv6

      看我上篇文章nvidia免费的。

    1. 公主 Queen Queen 
      Google Chrome 142.0.0.0 Google Chrome 142.0.0.0 Mac OS X  10.15.7 Mac OS X 10.15.7 cn中国–山东省–青岛市–李沧区–中国联通–3GNET网络 IPv6

      嗯嗯,能用,不过有时候时间认知还是有问题。

      1. Level 3
        Google Chrome 146.0.0.0 Google Chrome 146.0.0.0 Windows 11 x64 Edition Windows 11 x64 Edition cn中国–江苏 移动/数据上网公共出口 IPv4

        感觉已经很快了,从出现到能用也就这几年时间

        1. 公主 Queen Queen 
          Google Chrome 142.0.0.0 Google Chrome 142.0.0.0 Mac OS X  10.15.7 Mac OS X 10.15.7 cn中国–山东省–青岛市–李沧区–中国联通–3GNET网络 IPv6

          是的,进化速度会越来越快

    1. 公主 Queen Queen 
      Google Chrome 142.0.0.0 Google Chrome 142.0.0.0 Mac OS X  10.15.7 Mac OS X 10.15.7 cn中国–山东省–青岛市–李沧区–中国联通–3GNET网络 IPv6

      锦鲤系列
      锦鲤配龙虾

    1. 公主 Queen Queen 
      Google Chrome 142.0.0.0 Google Chrome 142.0.0.0 Mac OS X  10.15.7 Mac OS X 10.15.7 cn中国–山东省–青岛市–李沧区–中国联通–3GNET网络 IPv6

      ssh 也是个办法,其实sftp也ok的,我就是不想开客户端每次再链接。

  3. Level 1
    Firefox 148.0 Firefox 148.0 Mac OS X  10.15 Mac OS X 10.15 cn中国–河北–邢台 电信 IPv4

    还没玩这个,不过最近这个小龙虾好火呀
    等有时间了找个配置高点的机器,尝试玩一玩
    就是不知道门槛高不,配置大概在多少就能顺利的跑起来了

    1. 公主 Queen Queen 
      Google Chrome 142.0.0.0 Google Chrome 142.0.0.0 Mac OS X  10.15.7 Mac OS X 10.15.7 cn中国–山东省–青岛市–李沧区–中国联通–3GNET网络 IPv6

      我现在是2h2g,轻量云99.
      跑起来有些吃力。

  4. Level 3
    Firefox 148.0 Firefox 148.0 GNU/Linux x64 GNU/Linux x64 cn中国–广东–中山 电信 IPv4

    开了一台专门的服务器给龙虾用么?它好像要跑有 UI 界面的操作系统

    1. 公主 Queen Queen 
      Google Chrome 142.0.0.0 Google Chrome 142.0.0.0 Mac OS X  10.15.7 Mac OS X 10.15.7 cn中国–山东省–青岛市–李沧区–中国联通–3GNET网络 IPv6

      是的 99一年的
      不需要ui

  5. Level 1
    Google Chrome 146.0.0.0 Google Chrome 146.0.0.0 Windows 11 x64 Edition Windows 11 x64 Edition cn中国–上海–上海 电信/上海宏光经济信息发展中心优特交互网 IPv4

    看着照片我总觉得,养鲤鱼才是正经事

  6. Level 4
    Microsoft Edge 145.0.3800.99 Microsoft Edge 145.0.3800.99 iPhone iOS 17.7.1 iPhone iOS 17.7.1 cn中国–辽宁省–朝阳市–双塔区–中国电信–公众宽带 IPv6

    养虾已经过了兴奋期了,平和的接受很多事情。可能预期太高了,但是,每日工作时间成本绝对可以省下,这样又可以做其他事情了。 smile

发表回复

您的邮箱地址不会被公开。 必填项已用 * 标注