How to launch Photon LB (My Cloud) as application programmatically?

I have a Photon plugin running on the remote server. But sometimes it unexpectedly becomes stopped, without any visible reason. Logs show nothing. If I manually start it again - it runs until the next stop (it happens several times per month).

For now, my idea is to run some console application as a worker that checks if Photon is running, and if not - launches it as an application programmatically.

Is it possible to do? Maybe with some bash commands?

Answers

  • hi, @PolinaLiolia

    those unexpected stops is something abnormal. bin_Win64/log folder should contain something. Look there. It might be that it contains dumps. if there is no dump file please zip log files and share them with us. Do not forget to share time when 'stop' happened.

    One of possible reasons for such stops could be StackOverflow exceptions.

    about starting it programmatically. Sure you can do it. In sdk tests we do this. Look for PhotonStarter.cs in sdk folder. also you can register you photon as service and it will be restarted by system.

    also we have in bin_Win64 folder 'cmd' files to start and stop photon.


    best,

    ilya

  • Hi Ilya, thank you for a quick response!

    I've found some logs in deploy/bin_Win64/log, that could be related to the stop:

    It looks like the stop happened 29.12.2021 at 13:13.

    Also, I'm attaching other zipped logs.

    Could you provide some suggestions about crash reasons?

  • chvetsov
    chvetsov mod
    edited January 2022

    @PolinaLiolia please check PhotonCLR.log file in win_Bin64 folder. it contains all your exceptions that lead to server crash


    best,

    ilya

  • There are no logs from 29.12.2021 in PhotonCLR.log

    The last entry in PhotonCLR.log before server restart was on 28.12.2021, and according to GSGame.log game sessions were handled till 29.12.2021

  • @PolinaLiolia I see exception from yesterday and few days before. Those exceptions are unhandled and lead to server stop. So, If they are not fixed yet. They should be fixed first.

    Than what we could do is upgrading to SDK 5 because version you are using is very old.

    And next step would be cleaning bin_Win64 folder from old dumps and starting server. So, if you will get something like CPhotonPeer.Send exception you will also get dumps that help us to understand better what is going on.

    best,

    ilya

  • Okay, thank you, I'll try to follow these steps and let you know the results.