Skip to content
Advertisement

Work Around or Fix for NPM lite-server on Linux error when running Angular 2 Quick Start

I am unable to start the lite-server 2.1.0 using npm on Ubuntu 14.04. I am trying to run the Angular2 Quick Start example.

This problem may be specific to Linux and only started to occur after a recent update to Ubuntu. I am able to run the Angular2 Quick Start successfully on Windows 8.1. I have tried various different versions of NPM and Node with no changes in my results. Running the Angular Heroes example also fails with the same issue.

Any solution or temporary work around would be greatly appreciated.

After successfully transpiling typescript to javascript, here is the result of attempting to start lite-server via npm:

JavaScript

Here’s the package.json. I did upgrade lite-server to 2.1.0 to see if that would help, but it did not.

JavaScript

Here’s the typescript config:

JavaScript

Here’s the error message portion from the npm-debug.log:

JavaScript

Advertisement

Answer

I had the same error and I can solve it in ubuntu with the next steps:

Edit the file /etc/sysctl.conf and add the next line:

JavaScript

Save the file and type:

JavaScript

And try again run npm start. 🙂

Advertisement