guara-troubleshoot
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
ChineseTroubleshooting GuaraCloud
GuaraCloud故障排查指南
First Things to Check
首先检查以下内容
When something is wrong, start here:
bash
undefined当遇到问题时,先从以下步骤开始排查:
bash
undefined1. Is the service running?
1. 服务是否在运行?
guara services info
guara services info
2. What do the logs say?
2. 日志中有什么信息?
guara logs --level error --since 1h
guara logs --level error --since 1h
3. What's the deployment history?
3. 部署历史如何?
guara deployments list
guara deployments list
4. Is the platform itself healthy?
4. 平台自身状态是否健康?
guara status
undefinedguara status
undefinedHealth Statuses
健康状态说明
guara services info| Status | Meaning | Action |
|---|---|---|
| All replicas running and passing health checks | No action needed |
| Container repeatedly crashing and restarting | Check logs: |
| Cannot pull the container image | Check deployment logs, verify build succeeded |
| Container exceeded memory limit | Reduce memory usage or upgrade tier — see guaracloud.com/docs |
| Some but not all replicas healthy | Check logs, may resolve on its own during rolling updates |
| Status cannot be determined | Wait a moment, then check again |
guara services info| 状态 | 含义 | 操作建议 |
|---|---|---|
| 所有副本正常运行且通过健康检查 | 无需操作 |
| 容器反复崩溃并重启 | 查看日志: |
| 无法拉取容器镜像 | 查看部署日志,验证构建是否成功 |
| 容器超出内存限制 | 降低内存占用或升级套餐——详见guaracloud.com/docs |
| 部分副本状态正常(非全部) | 查看日志,滚动更新过程中可能自行恢复 |
| 无法确定状态 | 等待片刻后重新检查 |
Deployment Failure Decision Tree
部署失败排查决策树
Deployment status is :
failed- Check deployment logs:
guara logs --since 10m --level error - If build error → fix code/Dockerfile and redeploy:
guara deploy - If image pull error → previous build may have failed silently. Check for the last healthy deployment, then
guara deployments listguara rollback - If crash on startup → app fails to start. Check logs for stack traces, missing env vars, or port mismatches
Container keeps restarting (crash_loop):
- Check logs:
guara logs --level error --since 30m - Common causes:
- Missing environment variables → to check,
guara env listto fixguara env set - Wrong port → service listens on a different port than configured. Check with
guara services info - Missing dependencies → Dockerfile or buildpack not installing all deps
- OOM → app needs more memory than tier allows
- Missing environment variables →
- If you can't determine the cause from logs, exec into the container: to check runtime environment
guara exec -- env
Service stuck in :
deploying- Wait — deployments can take up to 10 minutes
- If still stuck, check for the status
guara deployments list - The new deployment may be waiting for health checks to pass
部署状态显示:
failed- 查看部署日志:
guara logs --since 10m --level error - 若为构建错误 → 修复代码/Dockerfile后重新部署:
guara deploy - 若为镜像拉取错误 → 之前的构建可能静默失败。查看找到最后一次健康的部署,然后执行
guara deployments list回滚guara rollback - 若为启动时崩溃 → 应用无法启动。查看日志中的堆栈跟踪、缺失的环境变量或端口不匹配问题
容器持续重启(crash_loop):
- 查看日志:
guara logs --level error --since 30m - 常见原因:
- 缺失环境变量 → 执行检查,
guara env list修复guara env set - 端口错误 → 服务监听的端口与配置不符。执行检查
guara services info - 依赖缺失 → Dockerfile或构建包未安装全部依赖
- OOM → 应用所需内存超出套餐限制
- 缺失环境变量 → 执行
- 若无法从日志确定原因,进入容器执行命令:检查运行时环境
guara exec -- env
服务卡在状态:
deploying- 等待——部署过程最长可能需要10分钟
- 若仍卡住,执行查看状态
guara deployments list - 新部署可能在等待健康检查通过
Tier Limit Errors
套餐限制错误
The CLI surfaces these when a tier limit is reached:
- "Resource exceeds your tier quota" → service needs more CPU/memory than tier allows
- "Maximum number of projects reached" → delete an unused project or upgrade
- "Maximum number of services reached" → delete an unused service or upgrade
- "Build minutes quota exceeded" → wait for next billing cycle or upgrade
- "Maximum number of custom domains reached" → remove an existing domain or upgrade
- "Account resource pool exhausted" → scale down other services or upgrade
For all tier limits, direct the user to guaracloud.com/docs to see current tier details and upgrade options.
当达到套餐限制时,CLI会显示以下错误:
- "Resource exceeds your tier quota" → 服务所需CPU/内存超出套餐限制
- "Maximum number of projects reached" → 删除未使用的项目或升级套餐
- "Maximum number of services reached" → 删除未使用的服务或升级套餐
- "Build minutes quota exceeded" → 等待下一个计费周期或升级套餐
- "Maximum number of custom domains reached" → 删除现有域名或升级套餐
- "Account resource pool exhausted" → 缩减其他服务规模或升级套餐
对于所有套餐限制问题,引导用户访问guaracloud.com/docs查看当前套餐详情及升级选项。
Authentication Errors
认证错误
- "Authentication failed. API key is invalid or revoked" → to re-authenticate
guara login - "Authentication failed. API key has expired" → to generate a new key
guara login - "Not authenticated" →
guara login - "Account is suspended due to billing issues" → update payment at app.guaracloud.com
- "Terms of Service must be accepted" → accept at app.guaracloud.com
- "Authentication failed. API key is invalid or revoked" → 执行重新认证
guara login - "Authentication failed. API key has expired" → 执行生成新密钥
guara login - "Not authenticated" → 执行
guara login - "Account is suspended due to billing issues" → 前往app.guaracloud.com更新支付信息
- "Terms of Service must be accepted" → 前往app.guaracloud.com接受服务条款
Network and Session Errors
网络与会话错误
- "Could not reach GuaraCloud API" → check internet connection and API URL:
guara config get api-url - "No ready pods available" → service is not running. Start it:
guara services start - "Session disconnected due to inactivity" → reconnect by running the command again
- "Maximum concurrent sessions reached" → close existing exec/proxy sessions first
- "Could not reach GuaraCloud API" → 检查网络连接及API地址:
guara config get api-url - "No ready pods available" → 服务未运行。启动服务:
guara services start - "Session disconnected due to inactivity" → 重新执行命令以重新连接
- "Maximum concurrent sessions reached" → 先关闭现有的执行/代理会话
Common Pitfalls
常见误区
- Forgot to deploy after creating a service — does NOT trigger a build. Run
services createafter.guara deploy - Port mismatch — the in
--portmust match what the app listens on.services create - Missing GitHub App — install at github.com/apps/guaracloud if you see "No GitHub App installation found."
- Env var change didn't take effect — triggers a rolling restart, but check logs to confirm the new process picked up the change.
guara env set - DNS not propagated for custom domain — shows
guara domains listuntil CNAME propagates. This can take minutes to hours.pending
For the full error code reference, see references/error-codes.md.
- 创建服务后忘记部署 — 不会触发构建。创建后需执行
services create。guara deploy - 端口不匹配 — 中的
services create参数必须与应用监听的端口一致。--port - 缺失GitHub App — 若看到"No GitHub App installation found.",请前往github.com/apps/guaracloud安装。
- 环境变量修改未生效 — 会触发滚动重启,但需查看日志确认新进程已加载修改后的变量。
guara env set - 自定义域名DNS未生效 — 在CNAME记录完成传播前,会显示
guara domains list状态。此过程可能需要数分钟到数小时。pending
完整错误码参考请查看references/error-codes.md。