Windows-Containers icon indicating copy to clipboard operation
Windows-Containers copied to clipboard

Are throttle events logged?

Open Hvid opened this issue 3 years ago • 35 comments

If i setup a container with limits on cpu count and memory:

C:\>docker inspect testcontainer --format "Name: {{.Name}} | CpuCount: {{.HostConfig.CpuCount}} | Memory: {{json .HostConfig.Memory}} | Isolation: {{.HostConfig.Isolation}}"
Name: /testcontainer| CpuCount: 4 | Memory: 4294967296 | Isolation: process

Are the throttle/kill/restart events logged anywhere?

Hvid avatar Oct 29 '21 08:10 Hvid

This issue has been open for 30 days with no updates. , please provide an update or close this issue.

ghost avatar Nov 28 '21 16:11 ghost

Ping

Hvid avatar Nov 29 '21 07:11 Hvid

This issue has been open for 30 days with no updates. @brasmith-ms, please provide an update or close this issue.

ghost avatar Dec 30 '21 16:12 ghost

Ping?

Hvid avatar Jan 04 '22 07:01 Hvid

This issue has been open for 30 days with no updates. @brasmith-ms, please provide an update or close this issue.

ghost avatar Feb 03 '22 16:02 ghost

ping??

Hvid avatar Feb 04 '22 09:02 Hvid

This issue has been open for 30 days with no updates. @brasmith-ms, please provide an update or close this issue.

ghost avatar Mar 06 '22 16:03 ghost

This issue has been open for 30 days with no updates. @brasmith-ms, please provide an update or close this issue.

ghost avatar Apr 06 '22 16:04 ghost

This issue has been open for 30 days with no updates. @brasmith-ms, please provide an update or close this issue.

ghost avatar May 07 '22 16:05 ghost

This issue has been open for 30 days with no updates. @brasmith-ms, please provide an update or close this issue.

ghost avatar Jun 06 '22 16:06 ghost

This issue has been open for 30 days with no updates. @brasmith-ms, please provide an update or close this issue.

ghost avatar Jul 06 '22 16:07 ghost

This issue has been open for 30 days with no updates. @brasmith-ms, please provide an update or close this issue.

ghost avatar Aug 05 '22 16:08 ghost

This issue has been open for 30 days with no updates. @brasmith-ms, please provide an update or close this issue.

ghost avatar Sep 05 '22 16:09 ghost

This issue has been open for 30 days with no updates. @brasmith-ms, please provide an update or close this issue.

ghost avatar Oct 06 '22 16:10 ghost

This issue has been open for 30 days with no updates. @brasmith-ms, please provide an update or close this issue.

ghost avatar Nov 06 '22 16:11 ghost

This issue has been open for 30 days with no updates. @brasmith-ms, please provide an update or close this issue.

ghost avatar Dec 06 '22 16:12 ghost

This issue has been open for 30 days with no updates. @brasmith-ms, please provide an update or close this issue.

ghost avatar Jan 06 '23 16:01 ghost

This issue has been open for 30 days with no updates. @brasmith-ms, please provide an update or close this issue.

This issue has been open for 30 days with no updates. @brasmith-ms, please provide an update or close this issue.

Has this project been abandoned?

Hvid avatar Apr 22 '23 10:04 Hvid

Definitely not abandoned. Apologies for the long wait. Have you checked docker events? The actions you mentioned should be listed there.

vrapolinario avatar Apr 22 '23 13:04 vrapolinario

In fact, just tested. I ran docker events and created and removed a container. This is what I got:

PS C:\Users\viniap> docker events
2023-04-22T15:06:04.605477400+02:00 container create b9da6d9803b0e7e297eb736e702b2fcd8b4d1175bcd79532bef8e27d02a24bb0 (image=iismonitorimage:v1, name=modest_rubin)
2023-04-22T15:06:04.663299200+02:00 network connect bd980384df16661537d1d65ca2e7f6429ac078151317cb58df7f1131c22af524 (container=b9da6d9803b0e7e297eb736e702b2fcd8b4d1175bcd79532bef8e27d02a24bb0, name=nat, type=nat)
2023-04-22T15:06:07.633370700+02:00 container start b9da6d9803b0e7e297eb736e702b2fcd8b4d1175bcd79532bef8e27d02a24bb0 (image=iismonitorimage:v1, name=modest_rubin)
2023-04-22T15:06:07.918513600+02:00 container exec_create: cmd.exe /C ECHO 172.16.25.208    host.docker.internal >> %systemroot%\system32\drivers\etc\hosts & ECHO 172.16.25.208    gateway.docker.internal >> %systemroot%\system32\drivers\etc\hosts b9da6d9803b0e7e297eb736e702b2fcd8b4d1175bcd79532bef8e27d02a24bb0 (execID=de63332190528a8e6fd55953c87be374c44933023e271f806f6a2b6584fed16a, image=iismonitorimage:v1, name=modest_rubin)
2023-04-22T15:06:07.921660900+02:00 container exec_start: cmd.exe /C ECHO 172.16.25.208    host.docker.internal >> %systemroot%\system32\drivers\etc\hosts & ECHO 172.16.25.208    gateway.docker.internal >> %systemroot%\system32\drivers\etc\hosts b9da6d9803b0e7e297eb736e702b2fcd8b4d1175bcd79532bef8e27d02a24bb0 (execID=de63332190528a8e6fd55953c87be374c44933023e271f806f6a2b6584fed16a, image=iismonitorimage:v1, name=modest_rubin)
2023-04-22T15:07:26.680259400+02:00 container kill b9da6d9803b0e7e297eb736e702b2fcd8b4d1175bcd79532bef8e27d02a24bb0 (image=iismonitorimage:v1, name=modest_rubin, signal=9)
2023-04-22T15:07:26.681971500+02:00 container die b9da6d9803b0e7e297eb736e702b2fcd8b4d1175bcd79532bef8e27d02a24bb0 (exitCode=4294967295, image=iismonitorimage:v1, name=modest_rubin)
2023-04-22T15:07:26.733914600+02:00 network disconnect bd980384df16661537d1d65ca2e7f6429ac078151317cb58df7f1131c22af524 (container=b9da6d9803b0e7e297eb736e702b2fcd8b4d1175bcd79532bef8e27d02a24bb0, name=nat, type=nat)
2023-04-22T15:07:26.751586400+02:00 container destroy b9da6d9803b0e7e297eb736e702b2fcd8b4d1175bcd79532bef8e27d02a24bb0 (image=iismonitorimage:v1, name=modest_rubin)

Also worth noticing that it was logged in Event Viewer as well under the source docker.

vrapolinario avatar Apr 22 '23 13:04 vrapolinario

I did check docker events and eventlogs on the host. There does not seem to be an info on when CPU is throttled.

Hvid avatar Apr 23 '23 10:04 Hvid

If container is restarted because of a memory limit, it doesn't state the reason either.

Hvid avatar Apr 24 '23 11:04 Hvid

That CPU/memory throttling information isn't exposed anywhere that I know of. It might be possible to query the job object for those notifications: https://learn.microsoft.com/en-us/windows/win32/api/winnt/ns-winnt-jobobject_notification_limit_information if the underlying jobobject that backs the Container has notfications turned on (I don't know).

@kevpar or @plooploops might know?

jsturtevant avatar Apr 26 '23 18:04 jsturtevant

This issue has been open for 30 days with no updates. @brasmith-ms, please provide an update or close this issue.

This issue has been open for 30 days with no updates. @brasmith-ms, please provide an update or close this issue.

This issue has been open for 30 days with no updates. @brasmith-ms, please provide an update or close this issue.

This issue has been open for 30 days with no updates. @brasmith-ms, please provide an update or close this issue.

Still looking into this.

ntrappe-msft avatar Jun 28 '23 20:06 ntrappe-msft