Replies: 3 comments 3 replies
-
我也是遇到这个问题, 没几天用launchd重启服务临时解决 |
Beta Was this translation helpful? Give feedback.
-
I'm seeing this as well across multiple Macs. Intel and Apple Silicon. It's being throttled:
The log entry indicates that a connection associated with the beszel-agent process was removed by the macOS Input/Output HID Event System. The message suggests that the beszel-agent is making a large number of requests to the IOHID system, which has triggered rate-limiting or throttling mechanisms. Here's an example from fs_usage. You can see that the agent is making a lot of read, write, and close operations in quick succession which is probably the root cause. We probably need a sleep statement in a loop somewhere. 14:05:16.144433 read F=5 B=0x34 |
Beta Was this translation helpful? Give feedback.
-
Actually, I took a chance and ran the agent with a nice 10 value, which seems to have been enough to place 'nice'. To use this... Download beszel agent curl -sL "https://github.com/henrygd/beszel/releases/latest/download/beszel-agent_$(uname -s)_$(uname -m | sed -e 's/x86_64/amd64/' -e 's/armv6l/arm/' -e 's/armv7l/arm/' -e 's/aarch64/arm64/').tar.gz" | tar -xz -O beszel-agent | tee ./beszel-agent >/dev/null && chmod +x beszel-agent Copy to /usr/local/bin sudo cp beszel-agent /usr/local/bin Create a LaunchDaemon sudo nano /Library/LaunchDaemon/com.beszel.agent.plist Edit the following, replacing the port and key as required <?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>Label</key>
<string>com.beszel.agent</string>
<key>ProgramArguments</key>
<array>
<string>/bin/bash</string>
<string>-c</string>
<string>PORT=45876 KEY="ssh-ed25519 XXXXXX" /usr/local/bin/beszel-agent</string>
</array>
<key>RunAtLoad</key>
<true/>
<key>KeepAlive</key>
<dict>
<!-- Prevent excessive restarts -->
<key>SuccessfulExit</key>
<false/>
<key>ThrottleInterval</key>
<integer>60</integer> <!-- Minimum 60 seconds between restarts -->
</dict>
<key>StandardErrorPath</key>
<string>/var/log/beszel-agent.err</string>
<key>StandardOutPath</key>
<string>/var/log/beszel-agent.log</string>
<!-- Lower the agent's process priority -->
<key>Nice</key>
<integer>10</integer>
</dict>
</plist> Load the LaunchDaemon pgrep -l beszel-agent
38277 beszel-agent |
Beta Was this translation helpful? Give feedback.
-
Hello all,
I have very little experience with MacOS, so I don't know what to tell people when they ask for help.
I'm hoping I can get some tips and feedback from anyone here who is running the agent successfully.
Are you using launchd? Docker? Detached tmux session?
I would like to create a little guide with recommended approaches and examples.
Thanks!
Beta Was this translation helpful? Give feedback.
All reactions