Ping + Port Routine? [英] Ping+Port Routine?

查看:83
本文介绍了Ping + Port Routine?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

嗨!我正在尝试为在线游戏网站写一个小应用程序

(飞行模拟),人们可以将他们的本地服务器添加到列表中。


基本上,我只需要能够循环/ ping每个相应的服务器

- 通过特定端口(2934或2935)查看服务器是否仍然是b
直播,所以主持人不必在网站上手动更新他们的

状态。


我看到的一切看起来都过于复杂。到目前为止的努力已经通过传统的PING返回了信息,但我似乎无法找到一种简单的获得所需*端口*信息的方式。该脚本必须从常规托管网站运行

,因此我无法访问

服务器的内部。 />

有什么想法吗?


TIA - Adam。

Hi! I''m trying to write a small application for an online gaming site
(flight sims), where people can add their local server to a list.

Basically, I just need to be able to loop/ping each respective server
- via a specific port (2934 or 2935) to see whether the server is
still "live", so the hosters don''t have to manually update their
status on the site.

Everything I''ve seen seems overly complex. Efforts so far have
returned info via a traditional PING, but I can''t seem to find an easy
way of getting the required *port* info. The script would have to run
from a regular hosted site, so I wouldn''t have much access to the
server''s "innards".

Any ideas?

TIA - Adam.

推荐答案

Adam写道:
嗨!我正在尝试为在线游戏网站写一个小应用程序
(飞行模拟),人们可以将他们的本地服务器添加到列表中。

基本上,我只需要成为能够循环/ ping每个相应的服务器
- 通过一个特定的端口(2934或2935)来查看服务器是否仍然现场,所以主机人员不必手动更新他们的
在网站上的状态。

我看到的一切看起来都过于复杂。到目前为止的努力已经通过传统的PING返回信息,但我似乎无法找到一种简单的方法来获取所需的*端口*信息。该脚本必须从常规托管站点运行
,因此我无法访问
服务器的内部。

任何想法?

TIA - Adam。
Hi! I''m trying to write a small application for an online gaming site
(flight sims), where people can add their local server to a list.

Basically, I just need to be able to loop/ping each respective server
- via a specific port (2934 or 2935) to see whether the server is
still "live", so the hosters don''t have to manually update their
status on the site.

Everything I''ve seen seems overly complex. Efforts so far have
returned info via a traditional PING, but I can''t seem to find an easy
way of getting the required *port* info. The script would have to run
from a regular hosted site, so I wouldn''t have much access to the
server''s "innards".

Any ideas?

TIA - Adam.




Ping使用内部定义的端口进行响应 - 而不仅仅是任何端口。

你不能ping一个特定的端口 - 它不知道如何回应。


可能最简单的方法是使用fsockopen打开一个套接字到

相应的系统/端口。


-

================= =

删除x来自我的电子邮件地址

Jerry Stuckle

JDS计算机培训公司
js ******* @ attglobal.net

==================



Ping uses an internally defined port for responses - not just any port.
You can''t ping a specific port - it wouldn''t know how to respond.

Probably the easiest way would be to use fsockopen to open a socket to
the appropriate system/port.

--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
js*******@attglobal.net
==================


2005年9月21日星期三07:05:41 -0500,Jerry Stuckle写道:
On Wed, 21 Sep 2005 07:05:41 -0500, Jerry Stuckle wrote:
Adam写道:
嗨!我正在尝试为在线游戏网站写一个小应用程序
(飞行模拟),人们可以将他们的本地服务器添加到列表中。

基本上,我只需要成为能够循环/ ping每个相应的服务器
- 通过一个特定的端口(2934或2935)来查看服务器是否仍然现场,所以主机人员不必手动更新他们的
在网站上的状态。

我看到的一切看起来都过于复杂。到目前为止的努力已经通过传统的PING返回信息,但我似乎无法找到一种简单的方法来获取所需的*端口*信息。该脚本必须从常规托管站点运行
,因此我无法访问
服务器的内部。

任何想法?TAN - Adam。
Hi! I''m trying to write a small application for an online gaming site
(flight sims), where people can add their local server to a list.

Basically, I just need to be able to loop/ping each respective server
- via a specific port (2934 or 2935) to see whether the server is
still "live", so the hosters don''t have to manually update their
status on the site.

Everything I''ve seen seems overly complex. Efforts so far have
returned info via a traditional PING, but I can''t seem to find an easy
way of getting the required *port* info. The script would have to run
from a regular hosted site, so I wouldn''t have much access to the
server''s "innards".

Any ideas?

TIA - Adam.



Ping使用内部定义的端口进行响应 - 而不仅仅是任何端口。
你不能ping特定端口 - 它不知道如何响应。

可能最简单的方法是使用fsockopen打开一个套接字来连接相应的系统/端口。



Ping uses an internally defined port for responses - not just any port.
You can''t ping a specific port - it wouldn''t know how to respond.

Probably the easiest way would be to use fsockopen to open a socket to
the appropriate system/port.




谢谢你。我设法发送了一个初始的握手。数据包

使用以下内容输出到游戏服务器:



Thanks for that. I''ve managed to send an initial "handshake" packet
out to the game server using:


handle = fsockopen(" udp://
handle = fsockopen("udp://


这篇关于Ping + Port Routine?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆