activated session shut down when scale up fleet manually

0

Hi, our team implemented session based game with unity and use gamelift as well. But when we scale up the fleet manually(not waiting for target based auto scale up), some activated session suddenly shut down. Why this happend and how can i prevent this situation?

gefragt vor 2 Monaten100 Aufrufe
1 Antwort
0
Akzeptierte Antwort

Hi owen,

Possible Reasons:

  1. Instance Termination: When you manually scale up or down, GameLift might terminate instances to bring the fleet to the desired capacity. If there are active sessions on these instances, they may get terminated as part of this process.

  2. Graceful Shutdown: GameLift usually attempts to terminate instances gracefully, but if the scaling action is too abrupt, some sessions might not have enough time to complete their operations before being terminated.

  3. Health Check Failures: Sometimes, when scaling up, new instances might fail initial health checks, causing the GameLift service to terminate those instances and any sessions running on them.

How to Prevent This:

  1. Use Auto-Scaling: Instead of manual scaling, consider configuring target-based auto-scaling policies. Auto-scaling is designed to scale fleets up or down more smoothly, reducing the risk of sudden terminations.

  2. Instance Protection: Consider using instance protection during scaling activities. This can prevent GameLift from terminating instances with active game sessions during a scaling event. You can find more information on this in the GameLift documentation.

  3. Graceful Session Shutdown: Ensure that your game servers can handle shutdown requests gracefully. When an instance is terminated, GameLift sends a ProcessTerminate signal. Make sure your game server processes this signal correctly, allowing it to complete ongoing sessions or notify players of the termination.

  4. Monitoring and Logging: Enable detailed logging and monitoring to track why instances are being terminated. CloudWatch logs can provide insights into whether instances are failing health checks or being terminated due to other reasons.

Further Reading:

I hope this helps! 😁

beantwortet vor 2 Monaten
  • Instance Protection? I will try this. thank you for your answer!

Du bist nicht angemeldet. Anmelden um eine Antwort zu veröffentlichen.

Eine gute Antwort beantwortet die Frage klar, gibt konstruktives Feedback und fördert die berufliche Weiterentwicklung des Fragenstellers.

Richtlinien für die Beantwortung von Fragen