CLI Reference
For Advanced Users
Most users never need the CLI. The IDE plugin handles everything automatically. This reference is for automation, scripting, and troubleshooting scenarios.
When to Use CLI
Заголовок раздела «When to Use CLI»| Scenario | Why CLI? |
|---|---|
| IDE can’t find JVM | Run galataj doctor |
| Headless servers | No IDE available |
| Docker | Manual attach |
| Debugging | Check status, logs |
Essential Commands
Заголовок раздела «Essential Commands»galataj doctor
Заголовок раздела «galataj doctor»Diagnose system issues. Run this first when something doesn’t work.
galataj doctor✓ CLI: v1.0.0✓ Java: Found (17.0.1)✓ Controller: Found✓ Agent: Found✓ Controller: Running✓ Ports: Availablegalataj status
Заголовок раздела «galataj status»Check what’s running.
galataj statusController: Running (PID: 12345)HTTP Port: 9877TCP Port: 9876
Attached JVMs: 1- abc123 (PID: 67890) - MyAppgalataj jvms
Заголовок раздела «galataj jvms»List available JVMs.
galataj jvmsFound 2 JVM(s):
1. com.example.MyApp ID: abc123 PID: 12345
2. order-service ID: def456 Environment: dockergalataj attach
Заголовок раздела «galataj attach»Attach profiler to a JVM.
# By PIDgalataj attach --pid 12345
# By JVM IDgalataj attach --jvm-id abc123galataj detach
Заголовок раздела «galataj detach»Stop profiling a JVM.
galataj detach --jvm-id abc123Controller Management
Заголовок раздела «Controller Management»# Start controllergalataj controller start
# Start with custom portgalataj controller start --port 8888
# Stop controllergalataj controller stopLicense Commands
Заголовок раздела «License Commands»# Check statusgalataj license status
# Activate licensegalataj license login YOUR-LICENSE-KEY
# Open purchase pagegalataj license purchase
# Validate licensegalataj license validateJSON Output
Заголовок раздела «JSON Output»Most commands support --json for scripting:
galataj jvms --jsongalataj status --jsongalataj license status --jsongalataj doctor --jsonExit Codes
Заголовок раздела «Exit Codes»| Code | Meaning |
|---|---|
| 0 | Success |
| 1 | General error |
| 2 | Controller not running |
| 3 | JVM not found |
| 4 | Attach failed |
| 5 | License error |