Idle instances do not turn off automatically. Please help

137 views
Skip to first unread message

Ice13ill

unread,
Nov 23, 2011, 6:30:05 AM11/23/11
to Google App Engine
I deployed yesterday a version of my app for testing purposes. I
checked the number of instances on that version today and I noticed
that there were 5 instances active, each one with 24h of age (aprox.).
But I didn't do any tests in the last 15-16 hours.
I also checked if there the number of requests changed in the last
15-20 minutes and it didn't

I also noticed that on my default version, i have about 5 instances
with 1h20m each... lets say a total of about 6.5 h for the last 1.5
hours (real time). But my dashboard shows a total of 4.6 hours. (the
counter was reset 3.5 hours ago, relative to the time when i'm writing
this post).
Until today, everything was fine. I set the number of idle instances
to 1 (max idle instances, about a week and a half ago) and on my
default version were 2, or 3 maximum instances active. It's like the
instance scheduler is not working correctly.

Barry Hunter

unread,
Nov 23, 2011, 6:40:49 AM11/23/11
to google-a...@googlegroups.com
Check the green line on the 'instances' graph.

You should not be billed for these idle instances. So don't worry about them

> --
> You received this message because you are subscribed to the Google Groups "Google App Engine" group.
> To post to this group, send email to google-a...@googlegroups.com.
> To unsubscribe from this group, send email to google-appengi...@googlegroups.com.
> For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en.
>
>

Andrei Cosmin Fifiiţă

unread,
Nov 23, 2011, 6:58:25 AM11/23/11
to Google App Engine
I also noticed that on my default version there are two instances with 1h53m age and one is with 1 request, the other with 2.
Another instance with 1h33m age has 4 requests... so the instances will not shutdown after 15 min of inactivity.

Ice13ill

unread,
Nov 23, 2011, 11:17:44 AM11/23/11
to Google App Engine
Yes, the billing seams OK, but the instances displayed in the
"Instances" tab are indeed active ? or is there just a "refresh"
problem ?

On Nov 23, 1:58 pm, Andrei Cosmin Fifiiţă <andrei.fifi...@gmail.com>
wrote:


> I also noticed that on my default version there are two instances with
> 1h53m age and one is with 1 request, the other with 2.
> Another instance with 1h33m age has 4 requests... so the instances will not
> shutdown after 15 min of inactivity.
>

Amy Unruh

unread,
Nov 23, 2011, 5:38:16 PM11/23/11
to google-a...@googlegroups.com
hi,

As Barry noted, see the green line in the 'instances' graph (from the admin console Dashboard, select 'Instances' from the 'Charts' menu).  This indicates the instances you're actually billed for, which should match your settings.  

WallyDD

unread,
Nov 24, 2011, 1:48:34 AM11/24/11
to Google App Engine
I am having something of similar problem with instances not turning
off.

The resident instances do nothing and stay idle while other instances
serve. Not entirely sure if it is related to your issue.

I get charged for mine :(

Brandon Wirtz

unread,
Nov 24, 2011, 2:02:55 AM11/24/11
to google-a...@googlegroups.com

Oh, you mean like this?

 

 

Sure… Put all the requests on my Dynamic instances. Don’t put any on the two basically idle instances they are felling lazy….  Oh and that 2nd instance… It is magic it serves all requests in 0ms  Maybe all requests should be served by it… instead of that 6th instance which has all the errors…

--

image002.jpg

Gerald Tan

unread,
Nov 24, 2011, 3:54:52 AM11/24/11
to google-a...@googlegroups.com
That can't be right. What's your min/max idle instance setting, how many dynamic and resident instances do you have, and how many instances does the instance chart say you are being charged for?


On Thursday, November 24, 2011 2:48:34 PM UTC+8, WallyDD wrote:
I am having something of similar problem with instances not turning
off.

The resident instances do nothing and stay idle while other instances
serve. Not entirely sure if it is related to your issue.

I get charged for mine :(

Ice13ill

unread,
Nov 24, 2011, 4:33:32 AM11/24/11
to Google App Engine
It's been two days now, since those instances were activated, on my
testing version...
The billing seams ok indeed, but I kinda need those stats.


On Nov 24, 9:02 am, "Brandon Wirtz" <drak...@digerat.com> wrote:
> Oh, you mean like this?
>

> Sure. Put all the requests on my Dynamic instances. Don't put any on the two
> basically idle instances they are felling lazy..  Oh and that 2nd instance.


> It is magic it serves all requests in 0ms  Maybe all requests should be

> served by it. instead of that 6th instance which has all the errors.


>
>
>
>
>
>
>
> -----Original Message-----
> From: google-a...@googlegroups.com
>
> [mailto:google-a...@googlegroups.com] On Behalf Of WallyDD
> Sent: Wednesday, November 23, 2011 10:49 PM
> To: Google App Engine
> Subject: [google-appengine] Re: Idle instances do not turn off
> automatically. Please help
>
> I am having something of similar problem with instances not turning off.
>
> The resident instances do nothing and stay idle while other instances serve.
> Not entirely sure if it is related to your issue.
>
> I get charged for mine :(
>

> On Nov 23, 6:30 am, Ice13ill < <mailto:andrei.fifi...@gmail.com>


> andrei.fifi...@gmail.com> wrote:
>
> > I deployed yesterday a version of my app for testing purposes. I
>
> > checked the number of instances on that version today and I noticed
>
> > that there were 5 instances active, each one with 24h of age (aprox.).
>
> > But I didn't do any tests in the last 15-16 hours.
>
> > I also checked if there the number of requests changed in the last
>
> > 15-20 minutes and it didn't
>
> > I also noticed that on my default version, i have about 5 instances
>
> > with 1h20m each... lets say a total of about 6.5 h for the last 1.5
>
> > hours (real time). But my dashboard shows a total of 4.6 hours. (the
>
> > counter was reset 3.5 hours ago, relative to the time when i'm writing
>
> > this post).
>
> > Until today, everything was fine. I set the number of idle instances
>
> > to 1 (max idle instances, about a week and a half ago) and on my
>
> > default version were 2, or 3 maximum instances active. It's like the
>
> > instance scheduler is not working correctly.
>
> --
>
> You received this message because you are subscribed to the Google Groups
> "Google App Engine" group.
>
> To post to this group, send email to

> <mailto:google-a...@googlegroups.com>


> google-a...@googlegroups.com.
>
> To unsubscribe from this group, send email to

> <mailto:google-appengi...@googlegroups.com>


> google-appengi...@googlegroups.com.
>
> For more options, visit this group at

> <http://groups.google.com/group/google-appengine?hl=en>http://groups.google.com/group/google-appengine?hl=en.
>
>
>
>  image002.jpg
> 19KViewDownload

WallyDD

unread,
Nov 24, 2011, 1:00:11 PM11/24/11
to Google App Engine
Looks very familiar, all the way to serving in 0ms.

I logged an issue the other day.
http://code.google.com/p/googleappengine/issues/detail?id=6390

My original post with Anands response.
http://groups.google.com/group/google-appengine/browse_thread/thread/92e9e8e46806a3c


On Nov 24, 2:02 am, "Brandon Wirtz" <drak...@digerat.com> wrote:
> Oh, you mean like this?
>

> Sure. Put all the requests on my Dynamic instances. Don't put any on the two
> basically idle instances they are felling lazy..  Oh and that 2nd instance.

> It is magic it serves all requests in 0ms  Maybe all requests should be

> served by it. instead of that 6th instance which has all the errors.


>
>
>
>
>
>
>
> -----Original Message-----
> From: google-a...@googlegroups.com
>
> [mailto:google-a...@googlegroups.com] On Behalf Of WallyDD
> Sent: Wednesday, November 23, 2011 10:49 PM
> To: Google App Engine
> Subject: [google-appengine] Re: Idle instances do not turn off
> automatically. Please help
>
> I am having something of similar problem with instances not turning off.
>
> The resident instances do nothing and stay idle while other instances serve.
> Not entirely sure if it is related to your issue.
>
> I get charged for mine :(
>

> On Nov 23, 6:30 am, Ice13ill < <mailto:andrei.fifi...@gmail.com>


> andrei.fifi...@gmail.com> wrote:
>
> > I deployed yesterday a version of my app for testing purposes. I
>
> > checked the number of instances on that version today and I noticed
>
> > that there were 5 instances active, each one with 24h of age (aprox.).
>
> > But I didn't do any tests in the last 15-16 hours.
>
> > I also checked if there the number of requests changed in the last
>
> > 15-20 minutes and it didn't
>
> > I also noticed that on my default version, i have about 5 instances
>
> > with 1h20m each... lets say a total of about 6.5 h for the last 1.5
>
> > hours (real time). But my dashboard shows a total of 4.6 hours. (the
>
> > counter was reset 3.5 hours ago, relative to the time when i'm writing
>
> > this post).
>
> > Until today, everything was fine. I set the number of idle instances
>
> > to 1 (max idle instances, about a week and a half ago) and on my
>
> > default version were 2, or 3 maximum instances active. It's like the
>
> > instance scheduler is not working correctly.
>
> --
>
> You received this message because you are subscribed to the Google Groups
> "Google App Engine" group.
>
> To post to this group, send email to

> <mailto:google-a...@googlegroups.com>


> google-a...@googlegroups.com.
>
> To unsubscribe from this group, send email to

> <mailto:google-appengi...@googlegroups.com>


> google-appengi...@googlegroups.com.
>
> For more options, visit this group at

Nick Johnson

unread,
Nov 24, 2011, 8:57:39 PM11/24/11
to google-a...@googlegroups.com
On Thu, Nov 24, 2011 at 5:48 PM, WallyDD <shan...@gmail.com> wrote:
I am having something of similar problem with instances not turning
off.

This isn't a problem - you're not being charged for those instances. You'll only be charged if demand requires sending traffic to them, in which case you've been saved the overhead of starting up a new instance.
 

The resident instances do nothing and stay idle while other instances
serve. Not entirely sure if it is related to your issue.

If you've specified a 'min idle instances' greater than 0, then this is behaving as documented. The point of requesting idle instances is to handle sudden increases in traffic volume while more instances are being spun up in the background; naturally this means that they have to remain idle while waiting for a traffic spike that will require them.

-Nick Johnson
 

I get charged for mine :(

On Nov 23, 6:30 am, Ice13ill <andrei.fifi...@gmail.com> wrote:
> I deployed yesterday a version of my app for testing purposes. I
> checked the number of instances on that version today and I noticed
> that there were 5 instances active, each one with 24h of age (aprox.).
> But I didn't do any tests in the last 15-16 hours.
> I also checked if there the number of requests changed in the last
> 15-20 minutes and it didn't
>
> I also noticed that on my default version, i have about 5 instances
> with 1h20m each... lets say a total of about 6.5 h for the last 1.5
> hours (real time). But my dashboard shows a total of 4.6 hours. (the
> counter was reset 3.5 hours ago, relative to the time when i'm writing
> this post).
> Until today, everything was fine. I set the number of idle instances
> to 1 (max idle instances, about a week and a half ago) and on my
> default version were 2, or 3 maximum instances active. It's like the
> instance scheduler is not working correctly.

--
You received this message because you are subscribed to the Google Groups "Google App Engine" group.
To post to this group, send email to google-a...@googlegroups.com.
To unsubscribe from this group, send email to google-appengi...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en.




--
Nick Johnson, Developer Programs Engineer, App Engine


Ice13ill

unread,
Nov 25, 2011, 5:09:16 AM11/25/11
to Google App Engine
My settings for idle instances are: Automatic - 1

On Nov 25, 3:57 am, Nick Johnson <nickjohn...@google.com> wrote:

WallyDD

unread,
Nov 26, 2011, 11:16:42 AM11/26/11
to Google App Engine
Hi Nick,

Thanks for responding and looking into this.
See my response below;

On Nov 24, 8:57 pm, Nick Johnson <nickjohn...@google.com> wrote:


> On Thu, Nov 24, 2011 at 5:48 PM, WallyDD <shaneb...@gmail.com> wrote:
> > I am having something of similar problem with instances not turning
> > off.
>
> This isn't a problem - you're not being charged for those instances. You'll
> only be charged if demand requires sending traffic to them, in which case
> you've been saved the overhead of starting up a new instance.

I am very much being charged for these instances.

> > The resident instances do nothing and stay idle while other instances
> > serve. Not entirely sure if it is related to your issue.
>
> If you've specified a 'min idle instances' greater than 0, then this is
> behaving as documented. The point of requesting idle instances is to handle
> sudden increases in traffic volume while more instances are being spun up
> in the background; naturally this means that they have to remain idle while
> waiting for a traffic spike that will require them.

The second instance fires up when traffic overloads the resident
instance(s). The new dynamic instance(s) then stay on, permanently. So
I get charged for both instances, one of which does nothing.

If it is behaving as documented, which part of the documentation
should I be looking at?

- sb

> -Nick Johnson
>

Nick Johnson

unread,
Nov 26, 2011, 6:20:23 PM11/26/11
to google-a...@googlegroups.com
You set your "min idle instances" to 1; therefore, 1 instance will be idle, in order to handle traffic spikes. If you don't want this behaviour, set min idle instances to 0.

-Nick Johnson


If it is behaving as documented, which part of the documentation
should I be looking at?

- sb

> -Nick Johnson
>

--
You received this message because you are subscribed to the Google Groups "Google App Engine" group.
To post to this group, send email to google-a...@googlegroups.com.
To unsubscribe from this group, send email to google-appengi...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en.

Brandon Wirtz

unread,
Nov 26, 2011, 6:33:08 PM11/26/11
to google-a...@googlegroups.com

I believe it is min idle “automatic” I don’t get “0”  as an option.

 

I have noticed that if Max is set to 2 and min is set to “automatic” that sending a single request to an app results quite often in that instance using 18-23 minutes of time on python 2.5

 

The testing is too slow, and I don’t care enough to test the complete set of possibilities.   I don’t experience this on 2.7.

 

Also If I have an app that 90% of the time needs 8 instances, and Peaks at needing 12.   I’m can’t set Min Idle to 8 so that I always have 8 and 4 “idle” so that I only really get to 12 for brief times.   Setting to Min 8 Max 8 means that I peak at 20 instead of 12.   I can kind of get there with “automatic and 4” but this seems very counter intuitive.

sb

unread,
Nov 26, 2011, 6:47:43 PM11/26/11
to Google App Engine
It doesn't behave this way at all.

It just fires up a new instance once the resident instance get
overloaded. The resident instance goes idle.

The new instance then handles all the traffic, and when that gets
overloaded another instance is created, while the original resident
instance is just sitting their completely idle. So I am getting billed
for three instances one of which is doing nothing and never will do
anything until I manually intervene.

On Nov 26, 6:20 pm, Nick Johnson <nickjohn...@google.com> wrote:

Brandon Wirtz

unread,
Nov 26, 2011, 7:38:56 PM11/26/11
to google-a...@googlegroups.com

Oh, and just so we are clear that I’m not Attacking… 

 

2.7 works really well with instances turning off.  AND not burning me on spin-up by “Over compensating” for spikes.

 

When you are “sizing” your app it doesn’t appear there is any advantage in picking more than 2 Idle instances.  And honestly I’m having a hard time coming up with a reason to set more than 1 min idle instance.  This information is specific to 2.7 Thread Safe Python. I haven’t tried this test on other configurations.

 

 

 

-----Original Message-----
From: google-a...@googlegroups.com [mailto:google-a...@googlegroups.com] On Behalf Of sb
Sent: Saturday, November 26, 2011 3:48 PM
To: Google App Engine

image003.jpg

Nick Johnson

unread,
Nov 27, 2011, 4:34:59 AM11/27/11
to google-a...@googlegroups.com
What is your setting for min idle instances?

-Nick

sb

unread,
Nov 27, 2011, 9:05:46 AM11/27/11
to Google App Engine
Right now Automatic.

In the case described, one.

Nick Johnson

unread,
Nov 27, 2011, 4:27:18 PM11/27/11
to google-a...@googlegroups.com
On Mon, Nov 28, 2011 at 1:05 AM, sb <shan...@gmail.com> wrote:
Right now Automatic.

In the case described, one.

As I explained, then, this is expected behaviour: You asked for one idle instance, so one instance remains idle. If your traffic increases rapidly enough that existing instances can't handle it, that instance will soak up the additional traffic until more instances can be brought online.

-Nick Johnson

sb

unread,
Nov 28, 2011, 11:34:57 AM11/28/11
to Google App Engine
When I start an application with it set to one idle instance, I get
one resident instance serving. I get zero idle instances.

I don't get an idle instance until the resident instance is
overloaded. It could be quite some time until this happens.


On Nov 27, 4:27 pm, Nick Johnson <nickjohn...@google.com> wrote:

Reply all
Reply to author
Forward
0 new messages