problem: when adding some project files, run the project with NPM run dev, the project run error as shown below:
reason: project running out of memory
solution: find node_modules> .bin> Webpack-dev-server. CMD file, add –max-old-space-size=8192
original file:
@IF EXIST "%~dp0\node.exe" (
"%~dp0\node.exe" "%~dp0\..\webpack-dev-server\bin\webpack-dev-server.js" %*
) ELSE (
@SETLOCAL
@SET PATHEXT=%PATHEXT:;.JS;=;%
node "%~dp0\..\webpack-dev-server\bin\webpack-dev-server.js" %*
)
is modified to:
@IF EXIST "%~dp0\node.exe" (
"%~dp0\node.exe" "%~dp0\..\webpack-dev-server\bin\webpack-dev-server.js" %*
) ELSE (
@SETLOCAL
@SET PATHEXT=%PATHEXT:;.JS;=;%
node --max-old-space-size=8192 "%~dp0\..\webpack-dev-server\bin\webpack-dev-server.js" %*
)
div>
Read More:
- Ineffective mark-compacts near heap limit Allocation failed – JavaScript heap out of memory
- Hbase Native memory allocation (mmap) failed to map xxx bytes for committing reserved memory
- The difference, cause and solution of memory overflow and memory leak
- WebHost failed to process a request.Memory gates checking failed because the free memory (140656640 …
- Out of memory overflow solution for idea running error
- Kvm internal error: process exited :cannot set up guest memory ‘pc.ram‘:Cannot allocate memory
- os::commit_memory(0x0000000538000000, 11408506880, 0) failed; error=‘Cannot allocate memory‘
- Tomcat memory overflow in Eclipse: Java. Lang. outofmemoryerror: permgen space solution:
- [PostgreSQL tutorial] · out of memory issue
- Error: 701 use DAC connection when out of memory
- CUDA error:out of memory
- MobaXterm error cuda:out of memory
- Oracle 11g installation prompt ora-27102: out of memory
- RuntimeError: CUDA out of memory. Tried to allocate 600.00 MiB (GPU 0; 23.69 GiB total capacity)
- Runtimeerror using Python training model: CUDA out of memory error resolution
- RuntimeError: CUDA error: out of memory solution (valid for pro-test)
- FATAL ERROR: Ineffective mark-compacts near heap limit Allocation failed
- CentOS execution command error: – bash: fork: cannot allocate memory processing / viewing process number
- Idea pop-up window out of memory, modify the parameters and start the no response solution
- Swap off failed: cannot allocate memory