macOS 和 Windows 错误
launchd、Gatekeeper、托盘、sc.exe 和 Windows 服务错误及最简单的修复方法。
wantasticd 服务开机自动运行,且 wantasticd status 显示 Connected。
开始之前
- macOS 上使用 sudo,Windows 上以管理员身份运行 PowerShell。
开始之前
- macOS:使用快速安装进行安装和认领。日志位于 /Library/Logs/Wantastic/wantasticd.log。
- Windows:使用令牌安装。Windows 上不显示认领二维码。
- Windows 没有日志文件。在前台运行一次服务以查看错误。
curl -fsSL https://get.wantastic.app/install.sh | sudo sh; sudo wantasticd genkey
# after "Device claimed": press Ctrl+C, then:
sudo launchctl kickstart -k system/com.wantastic.wantasticd检查要点
wantasticd status
tail -n 50 /Library/Logs/Wantastic/wantasticd.log
sudo launchctl kickstart -k system/com.wantastic.wantasticdPS C:\Users\you> irm https://get.wantastic.app/install.ps1 | iexAdministrator privileges are required.1Right-click PowerShell, choose 'Run as administrator', and run again:
- 1未以管理员身份打开
PS C:\Windows\system32> irm https://get.wantastic.app/install.ps1 | iexwantasticd v1.0.54+377f3c0 is installed and running as a Windows Service.1
- 1成功
速查表
| 错误 | 最简单的修复方法 |
|---|---|
| Error: on macOS the installer needs root. | 在 sh 前加上 sudo。 |
| Interface name must be utun[0-9]* | 取消设置 WANTASTIC_TUN_NAME。 |
| Killed by Gatekeeper / "cannot be opened" | 移除隔离标记并签名。 |
| 托盘显示 "Status: Daemon not running" | 重启服务。 |
| Failed to <action> (sc.exe exit code N). | 关闭 services.msc 或重启。 |
| The service is installed but not started because this device is not logged in yet. | wantasticd login --no-connect, then Start-Service wantasticd. |
| Administrator privileges are required. | 通过 Run as administrator(以管理员身份运行)打开 PowerShell。 |
| Error creating interface: … (Wintun) | 以管理员身份运行;在杀毒软件中放行。 |
验证结果
错误与解决方法
macOS 安装立即停止。Error: on macOS the installer needs root.install.sh (macOS)
安装程序没有使用 sudo 运行。
在 sh 前加上 sudo 运行快速安装,然后认领设备。
- 1运行该命令。
- 2打开 Claim URL,登录并点击 Claim Device。
- 3出现 "Device claimed" 后,按 Ctrl+C。
- 4运行:sudo launchctl kickstart -k system/com.wantastic.wantasticd
curl -fsSL https://get.wantastic.app/install.sh | sudo sh; sudo wantasticd genkeymacOS:已认领,但设备仍为 Offline。wantasticd genkey (macOS)
genkey 未使用 sudo 运行,因此配置保存在 ~/Library/Application Support/Wantastic,而服务不会读取该位置。
使用 sudo 重新运行 genkey,重新认领,然后重启服务。
sudo wantasticd genkey
# after "Device claimed": press Ctrl+C, then:
sudo launchctl kickstart -k system/com.wantastic.wantasticdmacOS 拒绝自定义 TUN 名称。Interface name must be utun[0-9]*wantasticd 日志(macOS)
WANTASTIC_TUN_NAME 设置的名称不是以 utun 开头。
删除该设置。macOS 会自动选择 utun 名称。
unset WANTASTIC_TUN_NAME
sudo launchctl kickstart -k system/com.wantastic.wantasticdmacOS 终止了二进制文件,或提示无法打开。macOS Gatekeeper
手动复制后,文件带有隔离标记或签名无效。
移除隔离标记并为二进制文件签名。
sudo xattr -d com.apple.quarantine /usr/local/bin/wantasticd
sudo codesign -f -s - /usr/local/bin/wantasticd
sudo launchctl kickstart -k system/com.wantastic.wantasticd设备已列出,但从 Mac 上无法访问。macOS
隧道已断开,或路由没有经过 utun。
重启服务,然后检查路由。
sudo launchctl kickstart -k system/com.wantastic.wantasticd
wantasticd status
route -n get <peer-ip>托盘提示守护进程未运行。Status: Daemon not runningmacOS 菜单栏应用
服务已停止或崩溃。
重启服务并检查日志。
sudo launchctl kickstart -k system/com.wantastic.wantasticd
tail -n 50 /Library/Logs/Wantastic/wantasticd.logmacOS 防火墙阻止了 P2P。[P2P] Could not add … to the application firewallwantasticd 日志(macOS)
macOS 防火墙拒绝了该规则。"Could not allow …" 情况类似。
在 System Settings → Network → Firewall → Options 中,允许 wantasticd 的传入连接。
Wi-Fi 名称显示为已隐藏。控制台 / 设备信息(macOS)
wantasticd 的定位服务已关闭。
在 System Settings → Privacy & Security 中为 wantasticd 开启定位服务。
旧的日志位置。macOS
1.0.50 之前的版本,日志位于 /var/log/wantasticd.log。
当前版本请使用 /Library/Logs/Wantastic/wantasticd.log。
安装过程中 sc.exe 步骤失败。Failed to <action> (sc.exe exit code N).install.ps1
通常为退出码 1072:服务管理器(services.msc)或其他工具占用了该服务。
关闭服务管理器、任务管理器和事件查看器,或重启。然后重新运行 install.ps1。
irm https://get.wantastic.app/install.ps1 | iex安装后 Windows 服务未运行。The wantasticd service did not reach the Running state.install.ps1
登录失败,因此配置只是占位内容。
使用新令牌登录,然后重启服务。
& "C:\Program Files\Wantastic\wantasticd.exe" login --no-connect --token <TOKEN>
Restart-Service wantasticd服务未在开机时启动。The wantasticd service was not configured for automatic startup.install.ps1
设置失败,或被策略修改。
手动设置为自动启动。
sc.exe config wantasticd start= auto安装后服务不存在。The wantasticd service was not found after installation.install.ps1
PowerShell 未以管理员身份运行,或被策略阻止。
以管理员身份在 PowerShell 中重新运行 install.ps1。
irm https://get.wantastic.app/install.ps1 | iexWindows 安装期间登录失败。Login did not complete (exit N).install.ps1
浏览器中的批准未及时完成或被拒绝,或令牌被拒绝。
重新登录并批准设备,然后启动服务。
wantasticd login --no-connect
Start-Service wantasticd安装程序立即停止。Administrator privileges are required.install.ps1
PowerShell 未以管理员身份打开。
点击开始,输入 powershell,点击 Run as administrator,再点击 Yes,然后重新粘贴这一行。
irm https://get.wantastic.app/install.ps1 | iexWindows 服务管理器错误。windows service failed: …事件查看器 / 前台运行
服务包装程序失败。"failed to determine if interactive session" 与此相关。
使用 -v 在前台运行以查看真正的错误,然后以管理员身份重新安装。
无法创建 Wintun 适配器。Error creating interface: …wantasticd (Windows)
PowerShell 未提升权限,或杀毒软件阻止了 Wintun 驱动。
以管理员身份运行,并在安全软件中放行 C:\Program Files\Wantastic。
Windows 上看不到二维码或登录提示。install.ps1 · wantasticd login (Windows)
Windows 上较旧的 wantasticd 版本无法向 PowerShell 输出内容。
按 Ctrl+C,在 Account → Secrets 中创建令牌,然后用它安装。
& ([scriptblock]::Create((irm https://get.wantastic.app/install.ps1))) -Token <TOKEN>在 Windows 上卸载。Windows
没有卸载脚本。
停止并删除服务,然后删除相关文件夹。
sc.exe stop wantasticd; sc.exe delete wantasticd
Remove-ItemProperty -Path HKLM:\Software\Microsoft\Windows\CurrentVersion\Run -Name Wantastic -ErrorAction SilentlyContinue
Remove-Item -Recurse -Force "C:\Program Files\Wantastic","C:\ProgramData\Wantastic"继续阅读
仍然无法解决?
请通过邮件发送设备名称、平台和完整的错误文本。切勿发送令牌、密钥或密码。