Manpages

Manpage of bzfls

bzfls

Section: Games and Demos (6)
Index
Return to Main Contents
 

NAME

bzfls - BZFlag game server-list server  

SYNOPSIS

bzfls [-d] [-help] [-p port] [-version] [bootstrap-list]  

DESCRIPTION

Bzfls keeps a list of bzfs servers. It's used to help BZFlag clients find available servers on the internet.  

Options

-d
Increases the debugging level. The option may appear multiple times to increase the amount of debugging information printed. It should not be used in normal circumstances.
-help
Print the version and usage information then exit.
-p port
Listen for requests on port instead of the default port.
-version
Print version information and exit.
bootstrap-list
Initialize the server list with the servers listed in the file bootstrap-list. This is normally used when restarting the server to avoid having to wait for servers to register themselves again.
 

Notes

Public bzfs servers (i.e. those that used the -public option) register themselves with bzfls servers at regular intervals and update their information, such as the number of current players, as it changes. BZFlag clients query the bzfls servers to provide the user a list of available servers. Working together these programs provide users an easy way to find games.

Game servers (bzfs) will also unregister themselves when they exit. However, since it's possible for the servers to be unable to unregister themselves, bzfls will drop servers that it hasn't heard from in a certain amount of time. Normally bzfs will send updates more often than this, even if nothing has changed. If bzfls is stopped and restarted, the listed bzfs servers will not know this and they won't show up on the list until they send an update.

Both clients and servers use a built-in url to find a list of bzfls servers (see URLs below). This url is maintained by the BZFlag author and lists a number of bzfls servers. Only these servers are required for game clients and servers to provide automatic server finding. You do not need to run your own bzfls under normal circumstances.

If you want a private list of servers then you can run bzfls but you must also get clients and servers to use it. BZFlag uses the -list url option to specify an alternate bzfls server. Bzfs uses -publiclist url. See URLs below for a description of the url format.  

URLs

The BZFlag family understands URLs with the standard syntax but supports a non-standard set of protocols.
http://hostname[:port][path]
file:path
bzflist://hostname[:port]

The http protocol is the standard HTTP protocol but only a subset of responses are understood. The reply must either be 200 (okay) with one or more URLs in the above form, one per line; or a 302 (object moved) with the new http URL.

The file protocol names a file on the system that contains one or more URLs in the above form, one per line.

The bzflist protocol names a bzfls server and an optional port. Unlike the other protocols, this type of URL does not list more URLs. Instead it points to an actual bzfls server.

Note that the http and file protocols can be used to list multiple bzfls servers. The built-in url does this; each bzfls server acts as a backup for the others. Any number of URLs may be given, but only a certain number of bzflist URLs will be used (the exact number is compiled into bzflag and bzfs).  

Protocol

The bzfls protcol is very simple, with just 5 messages. See the source code for details. One message worth noting here is GET. You can request the server list from a bzfls server using a protocol similar to HTTP. Sending a message with the first line of the form "GET url HTTP/*", where the * stands for any sequence of characters, causes bzfls to send an HTTP reply with the server list. The GET line may be followed by any number of lines; they are ignored. Most web browsers can successfully query the server list; just change bzflist in a URL to http. Note that the url in the GET line is ignored.  

Signals

Bzfls handles the following signals:
SIGUSR1
Causes bzfls to write the current server list to /tmp/bzfls.lst. This list can be used as a bootstrap file.
SIGUSR2
Causes bzfls to write network statistics to /tmp/bzfls.cnt.
 

FILES

/tmp/bzfls.cnt
The network statistics dumped by SIGUSR2.
/tmp/bzfls.lst
The server list dumped by SIGUSR1.
 

SEE ALSO

bzflag(6), bzfs(6)


 

Index

NAME
SYNOPSIS
DESCRIPTION
Options
Notes
URLs
Protocol
Signals
FILES
SEE ALSO

This document was created by man2html, using the manual pages.
Time: 08:30:21 GMT, April 26, 2024