douyinWEB/scripts/probe_s3_covers.py
eric a360eec2ba Document slots/covers/PB ops UX and sync feature pass to main.
Ship zombie reconcile, S3 covers, session end/drill-down, rooms ops, and refresh README for production.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-08-08 20:07:15 -05:00

23 lines
1.3 KiB
Python

# -*- coding: utf-8 -*-
import paramiko
c = paramiko.SSHClient()
c.set_missing_host_key_policy(paramiko.AutoAddPolicy())
c.connect("107.173.30.245", 22, "root", "Xiao4669805", timeout=30, allow_agent=False, look_for_keys=False)
cmds = [
"which minio mc rclone aws 2>/dev/null; ls /opt 2>/dev/null | head",
"ss -lntp | grep -Ei '9000|9001|8333|7480|4566|9292' || true",
"docker ps --format '{{.Names}} {{.Ports}}' 2>/dev/null | head -20",
"systemctl list-units --type=service --state=running | grep -Ei 'minio|s3|oss|seaweed|garage' || true",
"ls /etc/systemd/system/*minio* /etc/systemd/system/*s3* 2>/dev/null; cat /etc/systemd/system/minio.service 2>/dev/null | head -40",
"find /opt /home /root -maxdepth 3 -iname '*minio*' 2>/dev/null | head",
"curl -s --max-time 5 http://127.0.0.1:8014/api/sessions/active | python3 -c \"import sys,json; d=json.load(sys.stdin); print('total',d.get('total'));\n[print(s.get('anchor_name'), s.get('cover_url'), s.get('cover_path')) for s in (d.get('sessions') or [])[:5]]\"",
"ls -la /opt/douyinWEB/backend/data/covers | head",
]
for cmd in cmds:
print("\n====", cmd[:90], flush=True)
_, o, _ = c.exec_command(cmd, timeout=60, get_pty=True)
print(o.read().decode("utf-8", errors="replace")[-2500:], flush=True)
c.close()