> For the complete documentation index, see [llms.txt](https://orbitron.gitbook.io/orbitron-docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://orbitron.gitbook.io/orbitron-docs/documentation/ko/user-guide/installation/troubleshooting.md).

# 문제 해결

Orbitron 설치 및 자동 업데이트 과정에서 발생할 수 있는 일반적인 문제와 해결 방법을 소개합니다.

## 1️⃣ 새로 설치했는데 이전 버전이 계속 실행되는 경우

### 문제 증상

```bash
# 설치 스크립트를 실행했는데...
$ orbitron --version
v0.1.11  # 이전 버전이 표시됨

$ which orbitron
/Users/username/.orbitron/bin/orbitron  # 또는 /usr/local/bin/orbitron
```

### 원인

* 이전 설치 위치가 PATH에서 우선순위가 높음
* 터미널이 이전 경로를 캐시하고 있음
* 설치는 성공했지만 PATH 설정이 적용되지 않음

### 해결 방법

**단계 1: 터미널 재시작**

가장 간단한 방법입니다:

**Unix/Linux/macOS:**

```bash
# 쉘 재시작
exec $SHELL

# 또는 명령어 캐시만 재설정
hash -r

# 버전 확인
orbitron --version
```

**Windows:**

```powershell
# PowerShell 완전히 닫기
exit

# 새 PowerShell 창 열기
orbitron --version
```

**단계 2: 이전 설치 제거 (권장)**

가장 확실한 방법은 이전 설치를 제거하는 것입니다:

**Unix/Linux/macOS:**

```bash
# 이전 설치 제거
rm -rf ~/.orbitron

# 터미널 재시작
exec $SHELL

# 확인
orbitron --version
which orbitron  # /Users/username/.local/bin/orbitron 이어야 함
```

**Windows:**

```powershell
# 이전 설치 제거
Remove-Item -Recurse -Force "$env:USERPROFILE\.orbitron"

# PowerShell 재시작 후 확인
orbitron --version
```

**단계 3: 재설치 (모든 방법이 실패한 경우)**

```bash
# Unix/Linux/macOS
curl -fsSL https://orbitron.megaone.com/api/install.sh | bash

# Windows
irm https://orbitron.megaone.com/api/install.ps1 | iex
```

설치 중 마이그레이션 프롬프트가 나타나면 **YES**를 선택하세요.

***

## 2️⃣ 자동 업데이트를 활성화했는데 업데이트가 안 되는 것 같은 경우

### 문제 증상

```bash
# 자동 업데이트를 활성화했는데...
$ orbitron config get autoUpdate
true  # 활성화되어 있음

# 하지만 새 버전이 출시됐는데도 업데이트가 안 됨
$ orbitron --version
v0.1.12  # 이전 버전 (최신은 v0.1.13)
```

### 자동 업데이트 동작 방식 이해

**중요:** 자동 업데이트는 다음과 같이 작동합니다:

1. **6시간마다** 백그라운드에서 새 버전 확인
2. 새 버전이 있으면 자동으로 다운로드 및 설치
3. **다음 실행 시** 새 버전으로 자동 전환

즉, 설정을 활성화한 직후에는 업데이트되지 않으며, 다음 6시간 체크 주기까지 기다려야 합니다.

### 해결 방법

바로 업데이트가 필요한 경우, 설치 스크립트를 다시 실행하세요:

**Unix/Linux/macOS:**

```bash
curl -fsSL https://orbitron.megaone.com/api/install.sh | bash
```

**Windows:**

```powershell
irm https://orbitron.megaone.com/api/install.ps1 | iex
```

***

## 3️⃣ 중요 업데이트로 프로그램이 종료되는 경우

### 문제 증상

Orbitron을 실행하면 다음과 같은 메시지와 함께 자동으로 종료됩니다:

```
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
              ⚠️  Critical Security Update Required
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━

Current version: v0.1.9
Required version: v0.1.13

This update is required for security and stability.
Your work in progress has been automatically saved.

How to update:
  curl -fsSL https://orbitron.megaone.com/api/install.sh | bash

Installation guide:
  https://alphacode-ai.gitbook.io/orbitron/user-guide/installation

Exiting to prevent running a vulnerable version.
```

### 이유

보안 패치나 중요한 버그 수정이 포함된 필수 업데이트가 배포되었습니다. 이런 경우 사용자의 자동 업데이트 설정과 관계없이 프로그램이 종료됩니다.

### 해결 방법

**Unix/Linux/macOS**

메시지에 표시된 명령어를 실행하세요:

```bash
curl -fsSL https://orbitron.megaone.com/api/install.sh | bash
```

설치 완료 후:

```bash
orbitron --version  # 새 버전 확인
orbitron  # 정상 실행
```

**Windows**

```powershell
irm https://orbitron.megaone.com/api/install.ps1 | iex
```

설치 완료 후:

```powershell
orbitron --version  # 새 버전 확인
orbitron  # 정상 실행
```

***

## 4️⃣ 설치 스크립트 실행 중 경고 메시지

### 경고 1: 마이그레이션 프롬프트

```
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
  Old Installation Detected
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━

Old version: v0.1.12 (in ~/.orbitron/bin/)
New version: v0.1.13 (will be installed to ~/.local/bin/)

Would you like to migrate the old installation?
  YES: Backup old version, install new version, update PATH
  NO:  Keep both versions (you can remove old version later)

Migrate old installation? (Y/n):
```

**권장 선택:** `Y` 또는 `Enter` (YES)

**YES를 선택하면:**

* 이전 버전을 백업 (`~/.local/share/orbitron/versions/0.1.12/`)
* 이전 설치 위치에서 바이너리 제거
* 새 버전 설치
* PATH 자동 업데이트

**NO를 선택하면:**

* 두 버전 모두 유지
* 나중에 `rm -rf ~/.orbitron`로 이전 버전 제거 가능

### 경고 2: 자동 업데이트 설정

```
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
  Auto-Update Configuration
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━

Would you like to enable automatic updates?
You can change this setting later with: orbitron config set autoUpdate <true|false>

Enable auto-update? (Y/n):
```

**권장 선택:** `Y` 또는 `Enter` (YES)

**의미:**

* **YES:** 6시간마다 자동으로 새 버전 확인 및 업데이트
* **NO:** 수동으로 업데이트 스크립트 실행 필요

**나중에 변경 가능:**

```bash
# 활성화
orbitron config set autoUpdate true

# 비활성화
orbitron config set autoUpdate false
```

***

## 5️⃣ 명령어를 찾을 수 없음 (command not found)

### 증상

```bash
$ orbitron
command not found: orbitron
```

### 해결 방법

**단계 1: 터미널 재시작**

```bash
# Zsh 사용 시
source ~/.zshrc

# Bash 사용 시
source ~/.bashrc
```

**단계 2: 재설치**

그래도 해결되지 않으면 자동 설치 스크립트를 다시 실행하세요:

```bash
# Unix/Linux/macOS
curl -fsSL https://orbitron.megaone.com/api/install.sh | bash

# Windows
irm https://orbitron.megaone.com/api/install.ps1 | iex
```

***

## 6️⃣ Windows에서 Orbitron이 AWS 명령을 인식/실행하지 못하는 경우

### 문제 증상

* AI가 `aws` 명령을 실행했는데 결과 없이 실패하거나 인식되지 않음
* 명령 실행 결과가 비어있어 AI가 잘못된 결론을 내림

### 원인

Orbitron의 명령 실행 기능은 기본적으로 Unix 계열 셸(`/bin/bash`)을 사용합니다. Windows에는 기본 bash가 없어 명령이 실행되지 않습니다. **Git Bash**를 설치하고 셸 경로를 변경하면 해결됩니다.

### 해결 방법

**단계 1: Git for Windows 설치**

[Git for Windows 다운로드 페이지](https://gitforwindows.org/)에서 설치 프로그램을 받아 설치합니다. 설치 옵션은 모두 기본값으로 두고 진행해도 됩니다.

이미 설치되어 있는지 확인하려면 PowerShell에서:

```powershell
Test-Path "C:\Program Files\Git\bin\bash.exe"
```

`True`가 출력되면 설치된 것입니다.

**단계 2: Orbitron 설정 파일 수정**

`C:\Users\<사용자명>\.orbitron.json` 파일을 메모장 등으로 엽니다. 파일이 없다면 새로 만들면 됩니다.

`shell.path`를 Git Bash 경로로 변경합니다.

```diff
  "shell": {
    "args": ["-l"],
-   "path": "/bin/bash"
+   "path": "C:\\Program Files\\Git\\bin\\bash.exe"
  },
```

> ⚠️ JSON 경로의 백슬래시는 반드시 `\\` (두 번)로 작성해야 합니다.

**단계 3: Orbitron 재시작**

PowerShell 창을 완전히 닫고 새로 연 후 orbitron을 다시 실행합니다.

### 동작 확인

AI에게 AWS 명령을 요청해보세요:

```
AWS S3 버킷 목록 조회해줘
```

정상적으로 버킷 목록이 출력되면 설정이 완료된 것입니다.

***

## 🔍 완전 재설치

모든 방법이 실패하면 완전히 제거 후 재설치하세요:

**Unix/Linux/macOS:**

```bash
# 1. 모든 Orbitron 파일 제거
rm -rf ~/.local/bin/orbitron*
rm -rf ~/.local/share/orbitron
rm -rf ~/.local/state/orbitron
rm -rf ~/.orbitron

# 2. 터미널 재시작
exec $SHELL

# 3. 재설치
curl -fsSL https://orbitron.megaone.com/api/install.sh | bash
```

**Windows:**

```powershell
# 1. 모든 Orbitron 파일 제거
Remove-Item -Recurse -Force "$env:USERPROFILE\.local\bin\orbitron*"
Remove-Item -Recurse -Force "$env:USERPROFILE\.local\share\orbitron"
Remove-Item -Recurse -Force "$env:USERPROFILE\.local\state\orbitron"
Remove-Item -Recurse -Force "$env:USERPROFILE\.orbitron"

# 2. PowerShell 재시작

# 3. 재설치
irm https://orbitron.megaone.com/api/install.ps1 | iex
```

> 💡 재설치가 아니라 Orbitron을 완전히 제거하려면 아래 [완전 삭제](#orbitron-완전-삭제-제거) 섹션을 참고하세요.

***

## 🗑️ Orbitron 완전 삭제 (제거)

Orbitron을 설정, 데이터, 저장된 시크릿까지 포함하여 시스템에서 완전히 제거하는 방법입니다.

{% hint style="warning" %}
삭제 순서가 중요합니다. **설정 파일 확인 → 실제 데이터 경로 확인 → 삭제** 순서로 진행하세요. 설정 파일을 먼저 지우면 커스텀 데이터 경로를 찾을 수 없게 됩니다.
{% endhint %}

### 단계 1: 커스텀 데이터 경로 확인

데이터 저장 경로를 기본값에서 변경한 적이 있다면, 그 경로는 설정 파일에 기록되어 있습니다. 설정 파일을 지우기 전에 먼저 확인하세요:

```bash
# 1) 전역 설정에서 커스텀 데이터 경로 확인
cat ~/.orbitron.json | grep -A2 '"data"'

# 또는 jq 사용 시
jq '.data.directory' ~/.orbitron.json

# 2) 프로젝트별 로컬 설정도 확인 (Orbitron을 사용한 각 프로젝트에서)
jq '.data.directory' <프로젝트 경로>/.orbitron.json
```

확인 결과에 따라:

* **절대 경로**로 설정되어 있으면 → 해당 경로를 삭제 대상에 추가하세요
* **상대 경로**(기본값 `.orbitron`)면 → Orbitron을 실행했던 각 프로젝트 디렉토리 아래에 데이터가 생성되어 있습니다
* **값이 없으면** → 아래 기본 경로만 삭제하면 됩니다

커스텀 경로 사용자가 추가로 확인할 사항:

* **절대 경로로 변경했더라도** hooks 설정(`hooks.json`)은 항상 각 프로젝트의 `.orbitron/` 디렉토리에 저장됩니다. 각 프로젝트의 `.orbitron/`도 함께 확인하세요.
* **커스텀 상대 경로**(예: `mydata`)를 사용한 경우, MCP 캐시(`mcp_cache.json`)는 프로젝트가 아니라 **홈 디렉토리 기준**(`~/mydata/`)에 생성됩니다. 홈 아래 해당 디렉토리도 확인하세요.

### 단계 2: 삭제 대상 전체 목록

| 구분                       | 경로                                                    |
| ------------------------ | ----------------------------------------------------- |
| 실행 바이너리(심볼릭 링크)          | `~/.local/bin/orbitron`                               |
| 버전별 바이너리                 | `~/.local/share/orbitron/`                            |
| 상태 파일(업데이트 체크, 락)        | `~/.local/state/orbitron/`                            |
| 전역 데이터(글로벌 DB, 시크릿, 프로필) | `~/.orbitron/`                                        |
| 전역 설정                    | `~/.orbitron.json`, `~/.orbitron.local.json`          |
| XDG 설정(있는 경우)            | `~/.config/orbitron/` 또는 `$XDG_CONFIG_HOME/orbitron/` |
| 설치 방식 메타데이터              | `~/.local/bin/.orbitron_install_method`               |
| 레거시 설치(구버전)              | `~/.orbitron/bin/orbitron`, `/usr/local/bin/orbitron` |
| 프로젝트별 데이터                | 각 프로젝트의 `.orbitron/` 및 `.orbitron.json`               |

### 단계 3: 삭제 실행

**Unix/Linux/macOS:**

```bash
# 바이너리, 상태 파일, 설치 메타데이터
rm -f ~/.local/bin/orbitron ~/.local/bin/.orbitron_install_method
rm -rf ~/.local/share/orbitron
rm -rf ~/.local/state/orbitron

# 전역 데이터 및 설정
rm -rf ~/.orbitron
rm -f ~/.orbitron.json ~/.orbitron.local.json
rm -rf ~/.config/orbitron
# XDG_CONFIG_HOME을 따로 지정한 경우
rm -rf "$XDG_CONFIG_HOME/orbitron"

# 레거시 설치 (있는 경우)
sudo rm -f /usr/local/bin/orbitron

# 프로젝트별 데이터 (Orbitron을 사용한 각 프로젝트에서)
rm -rf <프로젝트 경로>/.orbitron
rm -f <프로젝트 경로>/.orbitron.json
```

**Windows:**

```powershell
# 바이너리, 상태 파일
Remove-Item -Recurse -Force "$env:USERPROFILE\.local\bin\orbitron*"
Remove-Item -Force "$env:USERPROFILE\.local\bin\.orbitron_install_method" -ErrorAction SilentlyContinue
Remove-Item -Recurse -Force "$env:USERPROFILE\.local\share\orbitron"
Remove-Item -Recurse -Force "$env:USERPROFILE\.local\state\orbitron"

# 전역 데이터 및 설정
Remove-Item -Recurse -Force "$env:USERPROFILE\.orbitron"
Remove-Item -Force "$env:USERPROFILE\.orbitron.json" -ErrorAction SilentlyContinue
Remove-Item -Force "$env:USERPROFILE\.orbitron.local.json" -ErrorAction SilentlyContinue

# 프로젝트별 데이터 (Orbitron을 사용한 각 프로젝트에서)
Remove-Item -Recurse -Force "<프로젝트 경로>\.orbitron"
Remove-Item -Force "<프로젝트 경로>\.orbitron.json" -ErrorAction SilentlyContinue
```

### 단계 4: 셸 PATH 등록 제거 (선택)

**Unix/Linux/macOS**

설치 스크립트는 셸 설정 파일 맨 앞에 아래와 같은 블록을 추가합니다. 파일에서 `# orbitron` 주석을 검색해 해당 블록을 제거하세요:

```bash
# orbitron
export PATH="$HOME/.local/bin:$PATH"
```

(fish 셸의 경우 `fish_add_path $HOME/.local/bin`)

확인할 파일 (사용 중인 셸에 따라 다름):

* `~/.zshrc`, `~/.zshenv`
* `~/.bashrc`, `~/.bash_profile`, `~/.profile`
* `~/.config/fish/config.fish`
* `$XDG_CONFIG_HOME`을 사용하는 경우: `$XDG_CONFIG_HOME/zsh/.zshrc`, `$XDG_CONFIG_HOME/bash/.bashrc` 등

**Windows**

Windows에서는 셸 설정 파일이 아니라 **레지스트리의 사용자 PATH 환경 변수**에 `%USERPROFILE%\.local\bin`이 등록됩니다. PowerShell에서 다음을 실행해 제거하세요:

```powershell
# 사용자 PATH에서 orbitron 경로 제거
$path = [Environment]::GetEnvironmentVariable("Path", "User")
$newPath = ($path -split ';' | Where-Object { $_ -ne "$env:USERPROFILE\.local\bin" }) -join ';'
[Environment]::SetEnvironmentVariable("Path", $newPath, "User")
```

또는 **시스템 설정 > 환경 변수 편집** UI에서 사용자 `Path` 항목의 `%USERPROFILE%\.local\bin`을 직접 삭제해도 됩니다.

레지스트리 등록에 실패한 경우에 한해 PowerShell 프로파일에 기록되었을 수 있습니다. 아래 파일에서 `# Added by orbitron installer` 주석과 그 아래 `$env:Path = ...` 라인을 제거하세요:

* `~\Documents\PowerShell\Microsoft.PowerShell_profile.ps1` (PowerShell 7+)
* `~\Documents\WindowsPowerShell\Microsoft.PowerShell_profile.ps1` (Windows PowerShell 5.x)

### ⚠️ 주의사항

* **파일이 아니라 디렉토리 단위로 삭제하세요.** Orbitron은 SQLite WAL 모드를 사용하므로 `orbitron.db` 옆에 `orbitron.db-wal`, `orbitron.db-shm` 사이드카 파일이 함께 존재합니다. DB 파일 하나만 지우면 사이드카 파일이 남습니다.
* **API 키 완전 삭제:** `~/.orbitron/orbitron_global.db`에는 암호화된 API 키(시크릿)가 저장되어 있습니다. 완전 삭제를 원한다면 `~/.orbitron/` 디렉토리 삭제가 필수입니다.

### 커스텀 경로가 기억나지 않는 경우

설정 파일을 이미 지웠거나 데이터를 어디로 옮겼는지 잊었다면, 홈 디렉토리 전체에서 Orbitron DB 파일을 탐색하세요:

```bash
find ~ -name "orbitron.db" -o -name "orbitron_global.db" -o -name "mcp_cache.json" 2>/dev/null
```

검색 결과로 나온 파일이 속한 디렉토리를 삭제하면 됩니다.

***

## 📝 추가 도움이 필요한 경우

위의 해결 방법으로도 문제가 해결되지 않으면 다음 정보를 수집하여 문의하세요.

### 빠른 정보 수집

<details>

<summary>Unix/Linux/macOS - 진단 정보 수집 스크립트</summary>

터미널에서 다음 명령어를 실행하고 결과를 복사하세요:

```bash
{
  echo "=== Orbitron 진단 정보 ==="
  echo "날짜: $(date)"
  echo ""
  echo "시스템: $(uname -a)"
  echo ""
  echo "버전: $(orbitron --version 2>&1 | grep -v WARN)"
  echo ""
  echo "위치: $(which orbitron)"
  echo ""
  if [ -L ~/.local/bin/orbitron ]; then
    echo "심볼릭 링크: $(readlink ~/.local/bin/orbitron)"
  else
    echo "심볼릭 링크: 없음 (일반 파일)"
  fi
  echo ""
  echo "버전 폴더:"
  if [ -d ~/.local/share/orbitron/versions/ ]; then
    ls ~/.local/share/orbitron/versions/
  else
    echo "  없음 (수동 설치)"
  fi
  echo ""
  echo "자동 업데이트: $(orbitron config get autoUpdate 2>&1 | grep -v WARN)"
  echo ""
  if [ -f ~/.local/state/orbitron/last_update_check ]; then
    echo "마지막 체크: $(cat ~/.local/state/orbitron/last_update_check)"
  else
    echo "마지막 체크: 기록 없음"
  fi
  echo ""
  echo "PATH에서 orbitron 관련 경로:"
  echo "$PATH" | tr ':' '\n' | grep -E '\.local|orbitron'
  echo ""
  echo "=== 최근 로그 ==="
  if [ -f ~/.local/state/orbitron/debug.log ]; then
    tail -n 30 ~/.local/state/orbitron/debug.log
  else
    echo "로그 파일 없음"
    echo "디버그 로그를 생성하려면 다음 명령어를 실행하세요:"
    echo "  ORBITRON_DEV_DEBUG=true orbitron -d"
  fi
} > ~/orbitron-debug.txt

echo "✅ 정보가 ~/orbitron-debug.txt에 저장되었습니다"
cat ~/orbitron-debug.txt
```

</details>

<details>

<summary>Windows - 진단 정보 수집 스크립트</summary>

PowerShell에서 다음을 실행하고 결과를 복사하세요:

```powershell
$output = "$env:USERPROFILE\Desktop\orbitron-debug.txt"
"=== Orbitron 진단 정보 ===" | Out-File -FilePath $output -Encoding UTF8
"날짜: $(Get-Date -Format 'yyyy-MM-dd HH:mm:ss')" | Out-File -FilePath $output -Append -Encoding UTF8
"" | Out-File -FilePath $output -Append -Encoding UTF8
"시스템: " | Out-File -FilePath $output -Append -Encoding UTF8 -NoNewline
try {
    (Get-ComputerInfo -ErrorAction Stop).WindowsVersion | Out-File -FilePath $output -Append -Encoding UTF8
} catch {
    "Windows" | Out-File -FilePath $output -Append -Encoding UTF8
}
"" | Out-File -FilePath $output -Append -Encoding UTF8
"버전: " | Out-File -FilePath $output -Append -Encoding UTF8 -NoNewline
try {
    $version = orbitron --version 2>&1 | Select-String -Pattern '^\d+\.\d+\.\d+' | Select-Object -First 1
    if ($version) {
        $version.Line | Out-File -FilePath $output -Append -Encoding UTF8
    } else {
        "확인 실패" | Out-File -FilePath $output -Append -Encoding UTF8
    }
} catch {
    "orbitron 실행 실패" | Out-File -FilePath $output -Append -Encoding UTF8
}
"" | Out-File -FilePath $output -Append -Encoding UTF8
"위치: " | Out-File -FilePath $output -Append -Encoding UTF8 -NoNewline
try {
    where.exe orbitron 2>$null | Out-File -FilePath $output -Append -Encoding UTF8
} catch {
    "찾을 수 없음" | Out-File -FilePath $output -Append -Encoding UTF8
}
"" | Out-File -FilePath $output -Append -Encoding UTF8
"설치 방법 메타데이터: " | Out-File -FilePath $output -Append -Encoding UTF8 -NoNewline
$metadataFile = "$env:USERPROFILE\.local\bin\.orbitron_install_method"
if (Test-Path $metadataFile) {
    Get-Content $metadataFile -ErrorAction SilentlyContinue | Out-File -FilePath $output -Append -Encoding UTF8
} else {
    "없음 (수동 설치)" | Out-File -FilePath $output -Append -Encoding UTF8
}
"" | Out-File -FilePath $output -Append -Encoding UTF8
"버전 폴더:" | Out-File -FilePath $output -Append -Encoding UTF8
$versionsPath = "$env:USERPROFILE\.local\share\orbitron\versions"
if (Test-Path $versionsPath) {
    Get-ChildItem $versionsPath -ErrorAction SilentlyContinue | ForEach-Object {
        "  $($_.Name)" | Out-File -FilePath $output -Append -Encoding UTF8
    }
} else {
    "  없음" | Out-File -FilePath $output -Append -Encoding UTF8
}
"" | Out-File -FilePath $output -Append -Encoding UTF8
"자동 업데이트: " | Out-File -FilePath $output -Append -Encoding UTF8 -NoNewline
try {
    $autoUpdate = orbitron config get autoUpdate 2>&1 | Select-String -Pattern 'true|false' | Select-Object -First 1
    if ($autoUpdate) {
        $autoUpdate.Line | Out-File -FilePath $output -Append -Encoding UTF8
    } else {
        "확인 실패" | Out-File -FilePath $output -Append -Encoding UTF8
    }
} catch {
    "확인 실패" | Out-File -FilePath $output -Append -Encoding UTF8
}
"" | Out-File -FilePath $output -Append -Encoding UTF8
"마지막 체크: " | Out-File -FilePath $output -Append -Encoding UTF8 -NoNewline
$checkFile = "$env:USERPROFILE\.local\state\orbitron\last_update_check"
if (Test-Path $checkFile) {
    Get-Content $checkFile -ErrorAction SilentlyContinue | Out-File -FilePath $output -Append -Encoding UTF8
} else {
    "기록 없음" | Out-File -FilePath $output -Append -Encoding UTF8
}
"" | Out-File -FilePath $output -Append -Encoding UTF8
"대기 중인 업데이트: " | Out-File -FilePath $output -Append -Encoding UTF8 -NoNewline
$newExe = "$env:USERPROFILE\.local\bin\orbitron.exe.new"
if (Test-Path $newExe) {
    "예 (다음 실행 시 적용됨)" | Out-File -FilePath $output -Append -Encoding UTF8
} else {
    "없음" | Out-File -FilePath $output -Append -Encoding UTF8
}
"" | Out-File -FilePath $output -Append -Encoding UTF8
"=== 최근 로그 ===" | Out-File -FilePath $output -Append -Encoding UTF8
$logFile = "$env:USERPROFILE\.orbitron\debug.log"
if (Test-Path $logFile) {
    Get-Content $logFile -Tail 30 -ErrorAction SilentlyContinue | Out-File -FilePath $output -Append -Encoding UTF8
} else {
    "로그 파일 없음" | Out-File -FilePath $output -Append -Encoding UTF8
    "" | Out-File -FilePath $output -Append -Encoding UTF8
    "디버그 로그를 생성하려면 다음 명령어를 실행하세요:" | Out-File -FilePath $output -Append -Encoding UTF8
    "  `$env:ORBITRON_DEV_DEBUG = 'true'" | Out-File -FilePath $output -Append -Encoding UTF8
    "  orbitron -d" | Out-File -FilePath $output -Append -Encoding UTF8
}
Write-Host ""
Write-Host "✅ 정보가 $output 에 저장되었습니다" -ForegroundColor Green
Write-Host ""
Get-Content $output
```

</details>

### 디버그 로그 생성 (로그가 없는 경우)

**Unix/Linux/macOS**

```bash
# 디버그 모드로 실행
ORBITRON_DEV_DEBUG=true orbitron -d

# 로그 확인
tail -n 50 ~/.local/state/orbitron/debug.log
```

**Windows**

```powershell
# 디버그 모드로 실행
$env:ORBITRON_DEV_DEBUG = "true"
orbitron -d

# 로그 확인
Get-Content "$env:USERPROFILE\.local\state\orbitron\debug.log" -Tail 50
```

## 🔗 관련 문서

* [설치 가이드](https://github.com/AlphaCode-AI/orbitron-docs/tree/main/docs/ko/user-guide/installation/README.md) - Orbitron 설치 방법
* [자동 업데이트 가이드](/orbitron-docs/documentation/ko/user-guide/installation/auto-update.md) - 자동 업데이트 설정 및 사용
* [마이그레이션 가이드](/orbitron-docs/documentation/ko/user-guide/installation/migration-guide.md) - 레거시 버전에서 업그레이드
