This document is about: SERVER 5
SWITCH TO

4.x to 5.0 BETA Upgrade Guide

This guide is for migrating from v4 to v5 BETA.

Overview of Major Changes

If you did not have a license before and were using the server using the 20 free CCU bootstrap license, you need to get one license now to be able to use the new server version. Other than that, some configuration changes need to be reviewed:

License Updates and Upgrades

When upgrading to a new major version of the Photon SDK or when using an older SDK version with a newly purchased license file, you should make sure ahead of time before going into production, that your Photon SDK runs with that license.

The easiest way to do this is to put the license file in question into the Photon SDK folder you plan to use and start Photon via the Photon Control application. You should then check the license information shown in the tray app and additionally check the logs for licensing errors.

PhotonServer.config Changes

  • We now recommend using the new syntax for defining server application instances: Instead of:

    XML

    <Configuration>
      <InstanceName>
      </InstanceName>
    </Configuration>
    

    Do:

    XML

    <Configuration>
      <Instance Name="InstanceName">
      </Instance>
    </Configuration>
    
  • Remove Application nodes' obsolete attributes:

    • RestartDelayMilliseconds
    • WatchFiles
    • ExcludeFiles
  • Remove Application nodes' obsolete attributes (or at least set to false):

    • EnableShadowCopy
    • EnableAutoRestart
    • ForceAutoRestart
  • Remove TCPListener's obsolete attributes:

    • MaxQueuedBuffers
    • MaxPendingWrites
  • Remove MMO instance.

  • Replace "UnhandledExceptionPolicy" value "ReloadDomain" with "Ignore" or "TerminateProcess".

  • For the LoadBalancing instance, the default application is now NameServer and no longer Master as it used to be in v4.

Secure Listeners Setup

Since we have moved from Secure Channel (Schannel) to OpenSSL, certificate format and configuration for secure listeners have changed.

  • Remove the obsolete attributes:
    • StoreName
    • UseMachineStore
    • CertificateName

Replace with the new settings for certificates setup. Read more on Certificate Setup.

LoadBalancing Configuration Changes

Plugins Configuration

Move plugins configuration from "deploy\Loadbalancing\GameServer\bin\Photon.LoadBalancing.dll.config" to "deploy\LoadBalancing\GameServer\bin\plugin.config".

NameServer (NEW)

In v5 we added the NameServer application which was available in Photon Cloud only before. Its configuration is done using two files:

  • one file for the actual application. Custom authentication is now done on the NameServer and not on the MasterServer anymore. So move custom authentication settings (<AuthSettings>) from the MasterServer's configuration file to the NameServer's configuration file: "deploy\NameServer\bin\Photon.NameServer.dll.config"

  • one file for the list of regions (MasterServer) to be associated with that NameServer. The file can be changed in 'NameServerConfig' setting in "deploy\NameServer\bin\Photon.NameServer.dll.config". Default is: "deploy\Nameserver.json"

'NameServer' is now the default application for the LoadBalancing instance in PhotonServer.config replacing 'Master' as it used to be in v4.

LoadBalancer and Workload Configuration Changes

Level Name Update

In v4 only 5 levels existed. Those level names were 'Lowest', 'Low', 'Middle', 'High' and 'Highest'.

Now we use 'Level0', 'Level1', 'Level2', ..., 'Level9'. 'Lowest' is replaced with 'Level0'. 'Highest' is replaced with 'Level9'.

Workload Configuration Change

The GameServer setting "WorkloadConfigFile" sets the path for the LoadBalancer configuration file. By default in v5 it's "deploy\Workload.1Gbps.config" (used to be "Workload.config"). Another example file is available in the SDK as well: "Workload.config".

Controller Setup Update

Old controller setup:

XML

<add Name="{ControllerName}" InitialInput="0" InitialLevel="Lowest">
  <FeedbackLevels>
    <add Level="Lowest" Value="{LowestValue}"/>
    <add Level="Low" Value="{LowValue}"/>
    <add Level="Normal" Value="{NormalValue}"/>
    <add Level="High" Value="{HighValue}"/>
    <add Level="Highest" Value="{HighestValue}"/>
  </FeedbackLevels>
</add>

New controller setup:

XML

<Controller Name="{ContollerName}" InitialInput="0" InitialLevel="Lowest">
  <FeedbackLevels>
    <Level name="0" Level="Level0" Value="{Value0}" ValueDown="{ValueDown0}"/>
    <Level name="1" Level="Level1" Value="{Value1}" ValueDown="{ValueDown1}"/>
    <Level name="2" Level="Level2" Value="{Value2}" ValueDown="{ValueDown2}"/>
    <Level name="3" Level="Level3" Value="{Value3}" ValueDown="{ValueDown3}"/>
    <Level name="4" Level="Level4" Value="{Value4}" ValueDown="{ValueDown4}"/>
    <Level name="5" Level="Level5" Value="{Value5}" ValueDown="{ValueDown5}"/>
    <Level name="6" Level="Level6" Value="{Value6}" ValueDown="{ValueDown6}"/>
    <Level name="7" Level="Level7" Value="{Value7}" ValueDown="{ValueDown7}"/>
    <Level name="8" Level="Level8" Value="{Value8}" ValueDown="{ValueDown8}"/>
    <Level name="9" Level="Level9" Value="{Value9}" ValueDown="{ValueDown9}"/>
  </FeedbackLevels>
</Controller>

LoadBalancer Configuration Change

The LoadBalancer configuration file is "deploy\LoadBalancer.config".

XML

<?xml version="1.0" encoding="utf-8" ?>
<LoadBalancer>
  <LoadBalancerWeights>
    <add Level="Lowest" Value="{LowestValue}"/>
    <add Level="Low" Value="{LowValue}"/>
    <add Level="Normal" Value="{NormalValue}"/>
    <add Level="High" Value="{HighValue}"/>
    <add Level="Highest" Value="{HighestValue}"/>
  </LoadBalancerWeights>
</LoadBalancer>

New structure:

XML

<?xml version="1.0" encoding="utf-8" ?>
  <LoadBalancer ReserveRatio="{ReserveRatio}" ValueUp="{ValueUp}">
    <LoadBalancerWeights>
      <Level name="0" Level="Level0" Value="{Value0}" />
      <Level name="1" Level="Level1" Value="{Value1}"/>
      <Level name="2" Level="Level2" Value="{Value2}"/>
      <Level name="3" Level="Level3" Value="{Value3}"/>
      <Level name="4" Level="Level4" Value="{Value4}"/>
      <Level name="5" Level="Level5" Value="{Value5}"/>
      <Level name="6" Level="Level6" Value="{Value6}"/>
      <Level name="7" Level="Level7" Value="{Value7}"/>
      <Level name="8" Level="Level8" Value="{Value8}"/>
      <Level name="9" Level="Level9" Value="{Value9}"/>
    </LoadBalancerWeights>
  </LoadBalancer>
Back to top