Pectics 你确定你访问wings后端的电脑可以同时访问 面板 吗?你需要保证面板能够与wings正常通讯,并且面板和wings都能与你电脑正常通讯。
wings的守护进程端口是能用浏览器正常访问的,比如 https://cn-zz.peckot.com:48080 这个你可以通过浏览器访问

确实无法在浏览器正常访问https://cn-zz.peckot.com:48080,那这样的情况还是让我感觉很迷,端口映射已经配置为内外网同48080端口,宝塔面板防火墙已经关闭,wings配置中的SSL证书也没有问题,那会是哪里的问题呢……?

    Pectics 你可以尝试其他的端口,没有被用过的端口

    守护进程端口
    检查节点界面,查看是绿色爱心还是红色爱心,如果是红色原因同下。
    检查节点的关于页面,是否有守护进程版本、系统版本、总 CPU 线程等信息是否有显示,如果没有则守护进程端口有问题,要么是端口被占用、防火墙关闭了此端口、服务商上游路由器中屏蔽、如果使用域名代替ip有可能是域名未过白名单。

    守护进程 SFTP 端口
    如果服务器在文件页面出现连接错误等信息可能是守护进程 SFTP 端口有问题,要么是端口被占用、防火墙关闭了此端口、服务商上游路由器中屏蔽(大概率,8080大部分服务商都会屏蔽)。
    所以请尝试其他端口。

    引用:https://pterodactyl.top/community/faq.html#%E5%89%8D%E7%AB%AF%E6%97%A0%E6%B3%95%E8%AE%BF%E9%97%AE%E5%90%8E%E7%AB%AF

    飒爽师叔 我重新尝试了一下,不再使用服务商提供的端口映射,而是重新尝试使用admin.peckot.com相同的natfrp方式,将内网8080端口映射到了cn-zz.peckot.com:34807,并修改了面板节点设置和wings配置文件的相关内容,但仍然出现这样的情况。
    btw,在本地查询8080端口占用时没有返回任何内容,我猜测是wings没有对8080端口进行监听……
    或者说是我在运行wings –debug的过程中会对8080进行一段时间的监听,然后wings会去调用面板的api,但是面板反过来访问cn-zz.peckot.com:34807的时候才出现了问题??
    另外面板的错误日志好像发生了一点变化:https://ptero.co/omaqimimux

      Pectics 如果有用该节点开过服务器,那请服务器页面打开f12控制台然后截图,如果没有那请进入节点的关于页面打开f12控制台截图

      Pectics 下次请通过回复功能,否则我们无法第一时间获得你发的消息
      请尝试其他端口,不要使用8080等端口,全部换了,比如守护进程端口10000,sftp端口10001这两个端口,都行
      内外网端口需要一致,不能内网一个端口,外网又是一个端口

        飒爽师叔 我尝试重新在新的服务器上部署了一个面板,但配置完成后在wings –debug时出现了这样的报错:

        DEBUG: [Jul  9 19:41:31.324] running in debug mode
         INFO: [Jul  9 19:41:31.324] loading configuration from file config_file=/etc/pterodactyl/config.yml
         INFO: [Jul  9 19:41:31.324] configured wings with system timezone timezone=Etc/UTC
        DEBUG: [Jul  9 19:41:31.324] ensuring root data directory exists path=/var/lib/pterodactyl
        DEBUG: [Jul  9 19:41:31.324] ensuring server data directory exists path=/var/lib/pterodactyl/volumes
        DEBUG: [Jul  9 19:41:31.324] ensuring archive data directory exists path=/var/lib/pterodactyl/archives
        DEBUG: [Jul  9 19:41:31.324] ensuring backup data directory exists path=/var/lib/pterodactyl/backups
         INFO: [Jul  9 19:41:31.324] checking for pterodactyl system user username=pterodactyl
         INFO: [Jul  9 19:41:31.324] configured system user successfully gid=997 uid=997 username=pterodactyl
         INFO: [Jul  9 19:41:31.325] fetching list of servers from API
        DEBUG: [Jul  9 19:41:31.325] making request to external HTTP endpoint endpoint=https://admin.pexil.cn/api/remote/servers?page=0&per_page=50 headers=map[Accept:[application/vnd.pterodactyl.v1+json] Authorization:[(redacted)] Content-Type:[application/json] User-Agent:[Pterodactyl Wings/v1.11.14.0 (id:smUfOlkWOc0qPV3j)]] method=GET
         INFO: [Jul  9 19:41:31.891] processing servers returned by the API total_configs=0
        DEBUG: [Jul  9 19:41:31.891] using 4 workerpools to instantiate server instances
         INFO: [Jul  9 19:41:31.891] finished processing server configurations duration=95.694µs
         INFO: [Jul  9 19:41:31.892] creating missing pterodactyl0 interface, this could take a few seconds...
        FATAL: [Jul  9 19:41:31.893] failed to configure docker environment error=Error response from daemon: invalid pool request: Pool overlaps with other one on this address space
        
        Stacktrace:
        Error response from daemon: invalid pool request: Pool overlaps with other one on this address space

        我不太明白这里的报错意味着什么,通过文档也未能查询到相关的解决方案

          Pectics 你这个新服务器是不是已经有docker项目了?比如配置了1panel?,wings默认分配ip与1panel默认的相同,你可以进入wings的配置文件中在network部分将ip改变,比如把其中的19改为20,然后再重新启动wings

            飒爽师叔 好的,现在wings已经能够正常启动了,但是节点列表仍然出现红色心形,f12能看到如图报错:

            前端storage/logs里的报错如下:

            https://ptero.co/equjijajug

            已确认wings所在服务器的33333端口处于监听状态,且端口映射不存在阻塞
            另附/etc/pterodactyl/config.yml文件:

            debug: false
            app_name: Pterodactyl
            uuid: cf655473-4fa3-4437-b8b6-a8a4ee301ae5
            token_id: smUfOlkWOc0qPV3j
            token: vYHj5r1jh2XMsy67hCyZUq6mrIeFew4Pi0fzDbQy9tvViXwFqoZoO6xMc6akIDkg
            api:
              host: 127.0.0.1
              port: 33333
              ssl:
                enabled: true
                cert: /etc/pterodactyl/ssl/cert.crt
                key: /etc/pterodactyl/ssl/cert.key
              disable_remote_download: false
              upload_limit: 100
              trusted_proxies: []
            system:
              root_directory: /var/lib/pterodactyl
              log_directory: /var/log/pterodactyl
              data: /var/lib/pterodactyl/volumes
              archive_directory: /var/lib/pterodactyl/archives
              backup_directory: /var/lib/pterodactyl/backups
              tmp_directory: /tmp/pterodactyl
              username: pterodactyl
              timezone: Etc/UTC
              user:
                rootless:
                  enabled: false
                  container_uid: 0
                  container_gid: 0
                uid: 997
                gid: 997
              disk_check_interval: 150
              activity_send_interval: 60
              activity_send_count: 100
              check_permissions_on_boot: true
              enable_log_rotate: true
              websocket_log_count: 150
              sftp:
                bind_address: 127.0.0.1
                bind_port: 44444
                read_only: false
              crash_detection:
                enabled: true
                detect_clean_exit_as_crash: true
                timeout: 60
              backups:
                write_limit: 0
                compression_level: best_speed
              transfers:
                download_limit: 0
              openat_mode: auto
            docker:
              network:
                interface: 172.19.0.1
                dns:
                - 1.0.0.1
                - 223.5.5.5
                - 8.8.8.8
                - 114.114.114.114
                name: pterodactyl_nw
                ispn: false
                driver: bridge
                network_mode: pterodactyl_nw
                is_internal: false
                enable_icc: true
                network_mtu: 1500
                interfaces:
                  v4:
                    subnet: 172.19.0.0/16
                    gateway: 172.19.0.1
                  v6:
                    subnet: fdba:17c8:6c94::/64
                    gateway: fdba:17c8:6c94::1011
              domainname: ""
              registries: {}
              tmpfs_size: 100
              container_pid_limit: 512
              installer_limits:
                memory: 1024
                cpu: 100
              overhead:
                override: false
                default_multiplier: 1.05
                multipliers: {}
              use_performant_inspect: true
              userns_mode: ""
              log_config:
                type: local
                config:
                  compress: "false"
                  max-file: "1"
                  max-size: 5m
                  mode: non-blocking
            throttles:
              enabled: true
              lines: 2000
              line_reset_interval: 100
            remote: https://admin.pexil.cn
            remote_query:
              timeout: 30
              boot_servers_per_page: 50
            allowed_mounts: []
            allowed_origins: []
            allow_cors_private_network: false
            ignore_panel_config_updates: false

            问题已解决,成功将面板与Wings后端连接。

            对于前面提到的SSL问题,我想是因为建站使用了natfrp端口映射导致HTTPS请求转发到本地服务器的过程中,将HTTPS请求还原成了HTTP请求,才会出现报错诸如http: server gave HTTP response to HTTPS client这样的内容。解决方案为:不要使用端口映射服务来搭建面板网站!

            对于后面我更换了全新的用于建站的、带有独立公网IP的服务器来搭建的面板服务,其中主要出现了两个问题:

            1. 我的docker服务之前有容器在使用某个网络配置,而Wings所需要占用的本地IP可能被另外的服务所占用。我的解决方案:删除其他docker服务,清理无用的网络配置
            2. 我的前端面板访问后端Wings的过程中,频繁出现Gateway timeout 504、Connection refused这样的报错,经过网络排查,其实际原因是我使用的服务商提供的端口映射的本地IP为0.0.0.0,而我在/etc/pterodactyl/config.yml中配置的后端本地IP并非是0.0.0.0。解决方案:修改config.yml中的api.host和system.sftp.bind_address为0.0.0.0

            以上就是我对本次项目探索的总结吧,希望能够帮到大家、少走弯路,特别是natfrp那个,坑还是蛮大的……

            貌似仍然存在一些问题:

            无法正常创建服务器,且关于界面f12能看见system-infomation时常出现504,但是是概率性事件,刚才有一次刷新是获取成功了的,没改任何配置

            文中出现的节点密钥记得重置一遍,否则会有安全隐患(毕竟此网站是公开的)