|
Flash Media Server Resources |
Performing general configuration tasksEnable checkpoint logging eventsMany companies use statistics from the access log to bill customers. If your programming includes live events or 24/7 programming, the events you use to calculate billing might not occur within a billing cycle. To solve this problem, you can enable checkpoint events. Checkpoint events log bytes periodically during an event. The following are available as checkpoint events: connect-continue, play-continue, and publish-continue. You must enable checkpoint events at the server level in the
Server.xml file. You can disable checkpoints at the vhost and application
level in the Vhost.xml and Application.xml files. You can also override
the logging interval at the vhost and application levels. For more
information, see the comments in the XML files located in the RootInstall/conf
folder.
Allow Administration API methods to be called over HTTPYou must specify each Administration API method that may be called over HTTP.
Allow application debugging connectionsTo play back streams and obtain data from shared objects, the Administration Console must make a special debugging connection to the server. By default, the server does not allow this connection.
Configuring IPv6IPv6 (Internet Protocol version 6) is a new version of Internet Protocol that supports 128-bit addresses. The current version of Internet Protocol, IPv4, supports 32-bit addresses. IPv6 alleviates the address shortage problem on the Internet. A system that only runs IPv6 can't communicate with a system that only runs IPv4. Important: In Red Hat® Linux
systems, you must update the NETWORKING_IPV6 value in /etc/sysconfig/network when installing or uninstalling IPv6.
Activate IPv6 on the network interface card.IPv6 is embedded in all operating systems that the server supports. You may need to activate IPv6 on the interfaces. For more information, see the operating system’s Help. Allow the server to listen on IPv6 sockets.Open the RootInstall/conf/fms.ini file and set the SERVER.NetworkingIPV6 enable attribute to "true". Restart the server. Enclose numeric IPv6 addresses in URLs in brackets.Wherever a numeric IPv6 address is used in a client-side script, server-side script, or in the server configuration files, enclose it in brackets: rtmp://[fd5e:624b:4c18:ffff:0:5efe:10.133.128.108]:1935/streamtest You must specify the interface zone index for a link-local address: rtmp://[fe80::204:23ff:fe14:da1c%4]:1935/streamtest It’s a good idea to register the RTMP, RTMPS, and
RTMPE protocols with a network services database and use a service
name (or decimal port number, if necessary) in the server configuration
files.Check the logs.When the server starts, it logs available stack configuration, host name, and all available IP addresses for the host in the master.xx.log, edge.xx.log, and admin.xx.log files (located in the RootInstall/logs/ directory). The following x-comment fields from a sample edge log file indicate that the IPv6 stack and the IPv4 stack are available, and that the server host has dual addresses and is listening on both interfaces: FMS detected IPv6 protocol stack! FMS config <NetworkingIPv6 enable=true> FMS running in IPv6 protocol stack mode! Host: fmsqewin2k3-02 IPv4: 10.133.192.42 IPv6: fe80::204:23ff:fe14:da1c%4 Listener started ( _defaultRoot__? ) : 19350/v6 Listener started ( _defaultRoot__? ) : 19350/v4 Listener started ( _defaultRoot__? ) : 1935/v6 Listener started ( _defaultRoot__? ) : 1935/v4 Note: On IPv6-enabled Linux, if you are using an IPv4
host name (a host name that resolves to IPv4) on an RTMPT or RTMPTE
connection, you should configure the Adaptor.xml appropriately to
resolve connections quickly. See HTTPIdent2.
Defining Application object propertiesYou can define properties for the server-side Application object in the server’s Application.xml configuration files. If you define properties in the default Application.xml file, the properties are available for all applications on a virtual host. If you define properties in an Application.xml file in an application folder, the properties are available only for that application. To define a property, create an XML tag in the JSEngine section of the Application.xml file. The property name corresponds to the tag’s name, and the property value corresponds to the tag’s contents. For example, the following XML fragment defines the properties user_name and dept_name, with the values jdoe and engineering, respectively: <Application>
<JSEngine>
<config>
<user_name>jdoe</user_name>
<dept_name>engineering</dept_name>
</config>
</JSEngine>
</Application>
To access the property in server-side code, use the syntax in either of these examples: application.config.prop_name application.config["prop_name"] Note: The properties you define are accessible from application.config.property,
not from application.property.
For example, given the previous XML fragment, the following trace() statements are valid: trace("I am " + application.config.user_name + " and I work in the " + application.config.dept_name + " department.");
trace("I am " + application.config["user_name"] + " and I work in the " + application.config["dept_name"] + " department.");
The output from either statement would be as follows: I am jdoe and I work in the engineering department. You can also use environment variables and symbols you define in the substitution.xml file. For example, assume that the environment variable COMPUTERNAME is equal to jsmith01, and you have defined a symbol named DEPT in the substitution.xml file: <Root>
<Symbols>
<DEPT>Engineering</DEPT>
</Symbols>
</Root>
In addition, the following XML appears in the Application.xml file: <Application>
<JSEngine>
<config>
<compName>${%COMPUTERNAME%}</compName>
<dept>${DEPT}</dept>
</config>
</JSEngine>
</Application>
In a server-side script, the following trace statements are valid: trace("My computer's name is: " + application.config.compName);
trace("My department is: " + application.config.dept);
The output is as follows: My computer's name is: jsmith01 My department is: Engineering Note: Server-side ActionScript trace()statements
display in the Live Log panel of the Administration Console.
Configure or disable native bandwidth detectionThe server can detect a client’s bandwidth in the core server code (called native bandwidth detection), or in a server-side script (called script-based bandwidth detection). Native bandwidth detection is faster than script-based because the core server code is written in C and C++. Also, with native bandwidth detection, if a client connects through edge servers, the outermost edge server detects the bandwidth, which results in more accurate data. Native bandwidth detection is enabled and configured by default. The server detects bandwidth by sending a series of data chunks to the client, each larger than the last. If desired, you can configure the size of the data chunks, the rate at which they’re sent, and the amount of time the server sends data to the client. For more information about detecting bandwidth in an application, see the Developer Guide.
|