An agent writes some Python, runs it in an E2B sandbox, and the run fails with this error:
TimeoutException: The sandbox is running but port is not open ...
This error is likely due to sandbox timeout.
The error says timeout, so you raise the timeout. Nothing changes. The sandbox never timed out: the process inside it ran out of memory and was killed. From the agent's side, the two look the same.
E2B can tell them apart, since it runs the sandbox. E2B now exports sandbox telemetry over OpenTelemetry, and Oodle has a native E2B integration to receive it.
What E2B sees that your agent can't

Your agent sees a sandbox only through the E2B SDK. The code inside the sandbox stops reporting the moment it is killed. E2B watches the VM from outside, so it sees the whole life of the sandbox:
| Question | Your agent | E2B |
|---|---|---|
| Why did the run fail? | The SDK reports a timeout or a closed connection | Out of memory: process was killed |
| Is the sandbox still up? | Can't tell | Yes, until it logs Sandbox stopped |
| How much memory did it use? | Can't tell | e2b_, sampled every 5 seconds |
| How many sandboxes are running? | Only the ones it thinks it holds | e2b_ |
| Why did a sandbox end? | Can't tell | kill_: request or timeout |
How the E2B integration works
- Your app starts sandboxes with the E2B SDK, exactly as it does today.
- E2B samples each sandbox from outside the VM and logs its lifecycle: created, paused, resumed, killed, stopped.
- E2B sends the metrics and logs over OTLP straight to Oodle. Nothing extra runs in your sandboxes or your cluster.
- In Oodle, every metric and log line carries
sandbox_id. If your agent logs it too, a failed run leads straight to E2B's logs for that sandbox.
How to send E2B telemetry to Oodle
The E2B tile on Oodle's integrations page shows these values with your instance filled in:
endpoint: "https://<OODLE_INSTANCE>-otlp.collector.oodle.ai"
protocol: "http/protobuf"
headers:
X-OODLE-INSTANCE: "<OODLE_INSTANCE>"
X-API-KEY: "<OODLE_API_KEY>"
- Send them to E2B support or to
enterprise@e2b.dev. The export is part of E2B's Enterprise and BYOC plans, and the E2B team turns it on. There is no setting for it in the E2B console. - Start a sandbox. E2B only sends data while sandboxes run.
- From the same tile, provision the E2B Sandboxes dashboard and the recommended monitors.
What you can do with E2B telemetry in Oodle
Debug sandbox OOM kills that look like timeouts
When code needs more memory than the sandbox has, Linux kills the process, but the sandbox stays up. The SDK only sees the connection drop. Filter Oodle's logs on the sandbox_id and service: e2b, and the cause is right there:
Sandbox created
Process with pid 1633 started
Out of memory: process was killed process=python
There's no Sandbox stopped line, so it wasn't a timeout. The sandbox's memory chart agrees: memory climbs, then falls to idle at the kill.
Catch leaked sandboxes before they hit your concurrency limit
It's easy for an agent to give up on a failed run without killing its sandbox. That sandbox keeps running, and billing, until its timeout, and the agent never counts it. e2b_team_sandbox_running shows what is really running, and kill_reason on each Killing sandbox log tells you whether your code killed it or it expired.
Leaks add up quietly. Once running sandboxes reach your team's limit, every new one fails, for every user:
429: Rate limit exceeded ... you have reached the maximum number of concurrent E2B sandboxes (20).

The fix on your side is small: kill sandboxes in a finally block.
Debug each sandbox with high-cardinality metrics
Every E2B sandbox metric carries a sandbox_id label, and sandboxes are short-lived. An agent that starts thousands of sandboxes a day creates thousands of new series a day for every metric. That is high cardinality, and the usual advice is to drop a label like that to keep the bill down. As Premature Cost Optimization Is the Root of All Blind Spots puts it, you then find out in the next incident that the signal you need isn't there.
Oodle is built to keep high-cardinality labels, so you don't have to drop sandbox_id. Introducing Oodle AI explains the architecture behind it, and Has ClickHouse conquered metrics? benchmarks it on 25M high-cardinality series.
With sandbox_id on every metric, a fleet average stops hiding the one sandbox that is in trouble:
-
Which sandbox ran out of memory? Open the memory chart for that
sandbox_id, right next to its OOM log. -
Which sandboxes are close to the limit right now? Rank them:
topk(10, max by (sandbox_id) (e2b_sandbox_ram_used / e2b_sandbox_ram_total)) -
Which sandboxes leaked? Look for sandboxes that are still running but doing nothing, and check their
kill_reasonwhen they end. -
Which user or session was it? If your agent's metrics and logs carry the same
sandbox_id, you can go from one sandbox to the request that started it.
Right-size sandbox CPU and memory
The dashboard shows running sandboxes, starts, and vCPUs and memory used against what you allocated, with the busiest sandboxes below. If most sandboxes use a fraction of their memory, a smaller template costs less. If they sit near the limit, the next large input gets killed.
Alert on sandbox CPU, memory and disk
The tile provisions three monitors:
| Monitor | Fires when |
|---|---|
| CPU saturated | A sandbox uses more than 90% of its vCPUs for 10 minutes |
| Memory near limit | A sandbox uses more than 85% (warning) or 95% (critical) of its memory for 5 minutes |
| Disk near full | A sandbox uses more than 85% (warning) or 95% (critical) of its disk for 5 minutes |
Two more are worth adding: a log monitor on Out of memory: process was killed, and a metric monitor on e2b_team_sandbox_running set below your team's limit.
Demo: debugging an E2B sandbox OOM
This video shows both problems in a sample AI data analyst that runs pandas code in E2B. The code is in oodle-onboarding.
Parting thoughts
More and more agents run code that an LLM wrote a few seconds earlier. When that code crashes inside a sandbox, the error your agent gets is often wrong, and the sandbox platform is the one system that knows what happened. That's why we wanted E2B's telemetry in the same place as the agent's traces and logs.
If you're on E2B Enterprise or BYOC, turning this on is one email to E2B. Start with the E2B integration docs, and see how Oodle's Agent Observability covers the agent side. New to it? Start with What is agent observability?
Frequently asked questions
How do I monitor E2B sandboxes?
Ask E2B to turn on its OpenTelemetry export and point it at your Oodle endpoint. E2B then sends CPU, memory and disk metrics and lifecycle logs for every sandbox. The E2B tile in Oodle sets up a dashboard and monitors on top of them.
Which E2B plans include the telemetry export?
Enterprise and BYOC. The E2B team turns it on for your team, and for BYOC it sends the data from your own environment.
Why does my E2B sandbox report a timeout when it ran out of memory?
When a process in the sandbox uses more memory than the sandbox has, Linux kills it, but the sandbox keeps running. The SDK only sees the connection drop and reports a timeout. E2B logs Out of memory: process was killed for that sandbox.
Does the export slow down my sandboxes?
No. E2B collects the data from outside the VM, so nothing extra runs inside your sandbox. E2B calls the export best effort: if Oodle can't be reached, some data may arrive late or be dropped.




