aws1 Min Read

Troubleshoot AWS Lambda unknown error!

Gorav Singal

August 22, 2017

TL;DR

If your Lambda silently dies with no error, check the timeout setting. Lambda kills the process when it exceeds the configured timeout, with no exception trace — just a silent stop.

Troubleshoot AWS Lambda unknown error!

After 2 days, there was my demo. I deployed my nodejs code on lambda function, and trying testing it. It abruptly stops in between, and no error or exception trace.

My application looked suspicious. I looked at my code, all looked good. I put a new try-catch statement, and some promised catch blocks. Deployed it again. Same behavior.

I started blaming newly developed components. Few days back, I incorporated newrelic components. I tried lot of modifications, debug statements, and even removed this component. But, still problem persists.

I tried running same application from my machine, it worked well. I wonder what is going on. I even thought of spinning an AWS EC2 instance, and try it there.

Problem

Each time, my application runs, and it stopped at one line only, with no trace, or error message. Troubleshoot AWS Lambda unknown error!

I was scanning through the configurations of lambda function. Suddenly, I found that the execution time value of lambda function was set to 1 min only.

Holy Crap!

I increased that time, and deployed my application again, it worked. My bad.

Tip for Lambda debugging

Always check lambda timeout value.

But

AWS people should show something in logs indicating that the app is shutting down due to timeout. It irked me a lot.
Share

Related Posts

Python SMTP Email Code - Sender Address Rejected - Not Owned By User

Python SMTP Email Code - Sender Address Rejected - Not Owned By User

Introduction In a normal email sending code from python, I’m getting following…

How to upload files on AWS S3 by using curl, without having command line aws or other tool

How to upload files on AWS S3 by using curl, without having command line aws or other tool

Introduction There were few files that I need to take backup from a machine that…

Static Website Hosting with AWS S3 and Cloudflare

Static Website Hosting with AWS S3 and Cloudflare

Static websites have several advantages over dyanamic websites. If you are…

How to Fix Drupal Mysql error - Communication link failure: 1153 Got a packet bigger than 'max_allowed_packet' bytes

How to Fix Drupal Mysql error - Communication link failure: 1153 Got a packet bigger than 'max_allowed_packet' bytes

Introduction While this topic may applicable to all mysql/mariadb users who…

Solving Jboss Wildfly Oracle JDBC driver problem, with Dockerfile

Solving Jboss Wildfly Oracle JDBC driver problem, with Dockerfile

Assuming your web application is using oracle, and you are deploying your app on…

React JS router not working on Nginx docker container

React JS router not working on Nginx docker container

Problem Statement I developed a simple ReactJS application where I have used…

Latest Posts

AI Video Generation in 2025 — Models, Costs, and How to Build a Cost-Effective Pipeline

AI Video Generation in 2025 — Models, Costs, and How to Build a Cost-Effective Pipeline

AI video generation went from “cool demo” to “usable in production” in 2024-202…

AI Models in 2025 — Cost, Capabilities, and Which One to Use

AI Models in 2025 — Cost, Capabilities, and Which One to Use

Choosing the right AI model is one of the most impactful decisions you’ll make…

AI Image Generation in 2025 — Models, Costs, and How to Optimize Spend

AI Image Generation in 2025 — Models, Costs, and How to Optimize Spend

Generating one image with AI costs between $0.002 and $0.12. That might sound…

AI Coding Assistants in 2025 — Every Tool Compared, and Which One to Actually Use

AI Coding Assistants in 2025 — Every Tool Compared, and Which One to Actually Use

Two years ago, AI coding meant one thing: GitHub Copilot autocompleting your…

AI Agents Demystified — It's Just Automation With a Better Brain

AI Agents Demystified — It's Just Automation With a Better Brain

Let’s cut through the noise. If you read Twitter or LinkedIn, you’d think “AI…

Supply Chain Security — Protecting Your Software Pipeline

Supply Chain Security — Protecting Your Software Pipeline

In 2024, a single malicious contributor nearly compromised every Linux system on…