Closed warddaniel closed 6 years ago
@warddaniel: Looks like this issue is caused by the machine running out of address space. You can try: Increasing number of threads per process in linux
@jmelberg-okta What if increasing the number of threads in not an option (for example, in case of hosting on a shared server)? is there an alternate option?
Closing, as this was related to the old version of this sample.
@niketpathak I am the same boat as you, did you solve it? If so, how?
I am also face same problem anybody got soluation?
node[849]: pthread_create: Resource temporarily unavailable
Hi @Sebastian-Nielsen , @vthink123 , could you tell me more about the environments that you're using, e.g. which OS, are you using docker, etc? Thanks!
Hi @Sebastian-Nielsen , @vthink123 , could you tell me more about the environments that you're using, e.g. which OS, are you using docker, etc? Thanks!
@robertjd Windows 10, it's running on a heroku server. I found that it only occurs when I create too many requests/threads at once. If I run one at time everything works fine. So I guess the reason for the error - at least in my case - is exactly as the error message phrased it: "resource temporarily unavailable" -> I got to either slow down or optimize the code to run more efficiently.
Trying to run sample. Got below error Running on Windows 8 Steps followed
info it worked if it ends with ok 1 verbose cli [ 'C:\\Program Files\\nodejs\\node.exe', 1 verbose cli 'C:\\Users\\Suresh\\AppData\\Roaming\\npm\\node_modules\\npm\\bin\\npm-cli.js', 1 verbose cli 'run', 1 verbose cli 'okta-hosted-login-server' ] 2 info using npm@6.4.1 3 info using node@v9.3.0 4 verbose run-script [ 'preokta-hosted-login-server', 4 verbose run-script 'okta-hosted-login-server', 4 verbose run-script 'postokta-hosted-login-server' ] 5 info lifecycle @okta/samples-nodejs-express-4@3.0.0~preokta-hosted-login-server: @okta/samples-nodejs-express-4@3.0.0 6 info lifecycle @okta/samples-nodejs-express-4@3.0.0~okta-hosted-login-server: @okta/samples-nodejs-express-4@3.0.0 7 verbose lifecycle @okta/samples-nodejs-express-4@3.0.0~okta-hosted-login-server: unsafe-perm in lifecycle true 8 verbose lifecycle @okta/samples-nodejs-express-4@3.0.0~okta-hosted-login-server: PATH: C:\Users\Suresh\AppData\Roaming\npm\node_modules\npm\node_modules\npm-lifecycle\node-gyp-bin;C:\dev\CRMApp\OktaSample\samples-nodejs-express-4\node_modules\.bin;C:\Program Files\Git\mingw64\bin;C:\Program Files\Git\usr\bin;C:\Users\Suresh\bin;C:\ProgramData\Oracle\Java\javapath;C:\Program Files (x86)\HP SimplePass\x64;C:\Program Files (x86)\HP SimplePass;C:\Program Files (x86)\Intel\iCLS Client;C:\Program Files\Intel\iCLS Client;C:\Program Files (x86)\NVIDIA Corporation\PhysX\Common;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\WINDOWS\System32\WindowsPowerShell\v1.0;C:\Program Files (x86)\Windows Live\Shared;C:\Program Files (x86)\Intel\OpenCL SDK\3.0\bin\x86;C:\Program Files (x86)\Intel\OpenCL SDK\3.0\bin\x64;C:\Program Files\Intel\Intel(R) Management Engine Components\DAL;C:\Program Files\Intel\Intel(R) Management Engine Components\IPT;C:\Program Files (x86)\Intel\Intel(R) Management Engine Components\DAL;C:\Program Files (x86)\Intel\Intel(R) Management Engine Components\IPT;C:\Program Files (x86)\Windows Kits\8.1\Windows Performance Toolkit;C:\Program Files\Microsoft SQL Server\110\Tools\Binn;C:\Program Files (x86)\FSharp-2.0.0.0\bin;C:\Program Files\TortoiseSVN\bin;C:\Program Files (x86)\Subversion\bin;C:\keenops\bin ;C:\Program Files\Intel\WiFi\bin;C:\Program Files\Common Files\Intel\WirelessCommon;C:\Program Files\Git\cmd;C:\Program Files\Microsoft\Web Platform Installer;C:\Program Files (x86)\Microsoft SDKs\TypeScript\1.0;C:\Program Files\Microsoft SQL Server\120\Tools\Binn;C:\Program Files (x86)\QuickTime\QTSystem;C:\Program Files (x86)\LINQPad4;C:\Program Files (x86)\Microsoft SQL Server\110\Tools\Binn\ManagementStudio;C:\Program Files (x86)\Microsoft SQL Server\110\Tools\Binn;C:\Program Files (x86)\Microsoft SQL Server\110\DTS\Binn;C:\Program Files (x86)\Skype\Phone;C:\Program Files (x86)\Sudowin\Clients\Console;C:\Program Files\nodejs;C:\Program Files\Microsoft SQL Server\130\Tools\Binn;C:\Program Files\dotnet;C:\Program Files (x86)\Microsoft VS Code\bin;C:\Users\Suresh\AppData\Roaming\npm;C:\Users\Suresh\AppData\Local\GitHubDesktop\bin 9 verbose lifecycle @okta/samples-nodejs-express-4@3.0.0~okta-hosted-login-server: CWD: C:\dev\CRMApp\OktaSample\samples-nodejs-express-4 10 silly lifecycle @okta/samples-nodejs-express-4@3.0.0~okta-hosted-login-server: Args: [ '/d /s /c', 'node okta-hosted-login/server.js' ] 11 silly lifecycle @okta/samples-nodejs-express-4@3.0.0~okta-hosted-login-server: Returned: code: 1 signal: null 12 info lifecycle @okta/samples-nodejs-express-4@3.0.0~okta-hosted-login-server: Failed to exec okta-hosted-login-server script 13 verbose stack Error: @okta/samples-nodejs-express-4@3.0.0 okta-hosted-login-server:
node okta-hosted-login/server.js 13 verbose stack Exit status 1 13 verbose stack at EventEmitter.<anonymous> (C:\Users\Suresh\AppData\Roaming\npm\node_modules\npm\node_modules\npm-lifecycle\index.js:301:16) 13 verbose stack at EventEmitter.emit (events.js:159:13) 13 verbose stack at ChildProcess.<anonymous> (C:\Users\Suresh\AppData\Roaming\npm\node_modules\npm\node_modules\npm-lifecycle\lib\spawn.js:55:14) 13 verbose stack at ChildProcess.emit (events.js:159:13) 13 verbose stack at maybeClose (internal/child_process.js:943:16) 13 verbose stack at Process.ChildProcess._handle.onexit (internal/child_process.js:220:5) 14 verbose pkgid @okta/samples-nodejs-express-4@3.0.0 15 verbose cwd C:\dev\CRMApp\OktaSample\samples-nodejs-express-4 16 verbose Windows_NT 6.3.9600 17 verbose argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Users\\Suresh\\AppData\\Roaming\\npm\\node_modules\\npm\\bin\\npm-cli.js" "run" "okta-hosted-login-server" 18 verbose node v9.3.0 19 verbose npm v6.4.1 20 error code ELIFECYCLE 21 error errno 1 22 error @okta/samples-nodejs-express-4@3.0.0 okta-hosted-login-server:
node okta-hosted-login/server.js 22 error Exit status 1 23 error Failed at the @okta/samples-nodejs-express-4@3.0.0 okta-hosted-login-server script. 23 error This is probably not a problem with npm. There is likely additional logging output above. 24 verbose exit [ 1, true ]
I am reporting this bug which throws an error but little else by way of error handling to detect root cause.