So I have a Predix app scaled to 2 instances and instance 0 is down. I'd like to use 'cf restart-app-instance myapp 0' to restart the one crashed instance. But that command never seems to do anything. Logs don't show any activity after the restart-app-instance is issued.
Does that command actually work in the Predix environment? I'm working in AWS West.
Answer by Siva Balan · May 07, 2018 at 01:56 PM
Yes that command works and we have used it successfully many times in US West. You may want to try that command on an instance that is in "running" state to see if it works for you. I cannot recall if I have tried to make it work on an instance that is in "crashed" state.
In Diego, the instances in crashed state are attempted to start in increasing time intervals for a certain number of times before it gives up completely by the health manager. Your instance is probably in a state where it cannot be restarted.
Ok, thanks, that makes sense. It's mainly an issue in our Production environment; we have some high-availability/high-workload apps that run at a larger instance count (6-12) and it'd be nice to be able to restart a crashed instance.by itself. Some of these apps have some weird startup interactions that requires us to start them an instance at a time (by starting with 1-2 instances and scaling until we reach the desired instance count) and these are especially tedious to restore to service.