You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
--on-idle hibernate / --on-complete hibernate without --hibernate never configure hibernation, so 'hibernate' silently becomes stop #949
Found while fixing #922. Verified by reading the code; not reproduced live.
cmd/launch_config.go sets config.Hibernate = true, which sends HibernationOptions.Configured=true to RunInstances, only for the --hibernate flag:
--on-idle hibernate and --hibernate-on-idle set only HibernateOnIdle;
--on-complete hibernate sets only OnComplete.
launch_preflight.go checks that the type supports hibernation for hibernate || HibernateOnIdle, but nothing configures it.
At idle or on completion, spored calls StopInstances(Hibernate=true). EC2 rejects that on an instance not configured for hibernation. EC2Provider.Hibernate then falls back to a plain stop and logs "falling back to stop", so the user asked for hibernation, was told it was set up, and got a stop with RAM lost.
For Spot, after #922 a persistent request is interrupted by hibernation only when --hibernate is set, for the same reason.
Suggested fix: when --on-idle hibernate, --hibernate-on-idle or --on-complete hibernate is given, also set config.Hibernate (with the existing preflight) or reject the combination with a clear message. --on-complete hibernate is not covered by the preflight today either.
Activity
Make --on-idle hibernate and --on-complete hibernate configure hibern…
Make --on-idle hibernate and --on-complete hibernate configure hibern…