
Common Issues
Quick solutions for frequently encountered problems.
Agent Won't Start
Port Already in Use
Error: listen tcp 0.0.0.0:4433: bind: address already in use
Solution:
# Find what's using the port
lsof -i :4433
netstat -tlnp | grep 4433
# Kill the process or use a different port
kill <PID>
# Or change config
listeners:
- address: "0.0.0.0:4434" # Different port
Configuration Error
Error: invalid configuration: ...
Solution:
# Validate YAML syntax
yamllint config.yaml
# Check for common issues:
# - Incorrect indentation
# - Missing quotes around values with special chars
# - Invalid CIDR notation
# - Missing required fields
Certificate Not Found
Error: open ./certs/agent.crt: no such file or directory
Solution:
# Generate certificates
muti-metroo cert ca -n "My CA"
muti-metroo cert agent -n "agent-1"
# Or fix path in config
tls:
cert: "/absolute/path/to/agent.crt"
key: "/absolute/path/to/agent.key"
Permission Denied
Error: open ./data/agent_id: permission denied
Solution:
# Fix ownership
chown -R $(whoami) ./data
# Or fix permissions
chmod 700 ./data
# If running as service user
chown -R muti-metroo:muti-metroo /var/lib/muti-metroo
Connection Issues
Peer Won't Connect
Symptoms:
peers: 0in health check- Logs show connection attempts but no success
Solutions:
-
Check network connectivity:
# Can you reach the peer?
nc -zv peer-address 4433
ping peer-address -
Check firewall:
# Is port open?
sudo iptables -L -n | grep 4433 -
Check TLS:
# Verify certificate
openssl s_client -connect peer-address:4433 -
Check peer ID:
# Is the ID correct?
peers:
- id: "correct-peer-id..." # Must match peer's agent_id
Connection Refused
Error: connection refused to peer-address:4433
Solutions:
- Peer not running or not listening
- Wrong address/port
- Firewall blocking connection
- Wrong transport type
TLS Handshake Failed
Error: tls: handshake failure
Solutions:
-
Certificate not signed by trusted CA:
openssl verify -CAfile ca.crt peer.crt -
Certificate expired:
openssl x509 -enddate -noout -in agent.crt -
Wrong hostname/IP in certificate:
openssl x509 -text -noout -in agent.crt | grep -A1 "Subject Alternative Name"
SOCKS5 Issues
No Route to Host
Error: no route to 1.2.3.4
Cause: No exit agent with matching route.
Solutions:
-
Check exit is running and connected:
curl http://localhost:8080/healthz | jq '.peers, .routes' -
Check exit has route configured:
exit:
enabled: true
routes:
- "0.0.0.0/0" # Or specific CIDR -
Trigger route advertisement:
curl -X POST http://exit-agent:8080/routes/advertise
Connection Timeout
Error: connection timeout
Causes:
- Slow network
- Too many hops
- Exit agent overloaded
Solutions:
-
Increase timeout:
limits:
stream_open_timeout: 60s # Default 30s -
Reduce hop count
-
Check exit agent health
Authentication Failed
Error: SOCKS5 authentication failed
Solutions:
-
Check username/password:
curl -x socks5://user:password@localhost:1080 https://example.com -
Verify password hash in config is correct
-
Check for special characters needing escaping
Exit Issues
DNS Resolution Failed
Error: DNS lookup failed for example.com
Solutions:
-
Check DNS servers are configured:
exit:
dns:
servers:
- "8.8.8.8:53" -
Check DNS servers are reachable from exit host:
dig @8.8.8.8 example.com -
Increase DNS timeout:
exit:
dns:
timeout: 10s
Destination Not Allowed
Error: destination not in allowed routes
Solution: Add route to exit config:
exit:
routes:
- "0.0.0.0/0" # Or specific CIDR matching destination
RPC Issues
Command Rejected
Error: command not in whitelist
Solution: Add command to whitelist:
rpc:
whitelist:
- whoami
- your-command # Add needed command
RPC Authentication Failed
Error: RPC authentication failed
Solutions:
-
Check password:
muti-metroo rpc -p correct-password agent-id whoami -
Verify password hash in config matches
File Transfer Issues
Path Not Allowed
Error: path not in allowed paths
Solution: Add path prefix to allowed_paths:
file_transfer:
allowed_paths:
- /tmp
- /path/to/your/files
File Too Large
Error: file exceeds maximum size
Solution: Increase max_file_size or use 0 for unlimited:
file_transfer:
max_file_size: 0 # Unlimited
Performance Issues
See Performance Troubleshooting for:
- Slow connections
- High latency
- Memory usage
- CPU usage
Debug Mode
Enable debug logging for detailed diagnostics:
muti-metroo run -c config.yaml --log-level debug
Or in config:
agent:
log_level: "debug"
Getting Help
If these solutions don't work:
- Check logs with debug level
- Review the specific troubleshooting guides
- Check the protocol and limits documentation
- Search existing issues
- Open a new issue with:
- Configuration (redacted)
- Logs (debug level)
- Steps to reproduce