docker-node icon indicating copy to clipboard operation
docker-node copied to clipboard

why run error

Open aogg opened this issue 2 years ago • 6 comments

docker rm -f temp-node;\
docker run --network common-all -d --entrypoint /usr/bin/bash --name temp-node  \
-v /data/:/data \
node:18 -c "tail -f /etc/hosts"

root@5fe9c6cb883b:/tmp# npm -v
node[18]: ../src/node_platform.cc:68:std::unique_ptr<long unsigned int> node::WorkerThreadsTaskRunner::DelayedTaskScheduler::Start(): Assertion `(0) == (uv_thread_create(t.get(), start_thread, this))' failed.
 1: 0xb83f50 node::Abort() [node]
 2: 0xb83fce  [node]
 3: 0xbf14ee  [node]
 4: 0xbf15d1 node::NodePlatform::NodePlatform(int, v8::TracingController*, v8::PageAllocator*) [node]
 5: 0xb41ed3 node::InitializeOncePerProcess(std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > const&, node::ProcessFlags::Flags) [node]
 6: 0xb4256b node::Start(int, char**) [node]
 7: 0x7e916c7f41ca  [/lib/x86_64-linux-gnu/libc.so.6]
 8: 0x7e916c7f4285 __libc_start_main [/lib/x86_64-linux-gnu/libc.so.6]
 9: 0xac1fee _start [node]
Aborted (core dumped)
root@5fe9c6cb883b:/tmp# 


aogg avatar Aug 24 '23 08:08 aogg

Even I am getting same error with node 18 version

jkevinaxioned avatar Aug 24 '23 10:08 jkevinaxioned

Update - Issue is now resolved for me. The error was due to use of old docker version v19 and updated to docker version v23.

@aogg Try to update your docker version, it should get resolved.

jkevinaxioned avatar Aug 24 '23 11:08 jkevinaxioned

So there is something wrong with your image, not the need to upgrade the node version

aogg avatar Aug 24 '23 11:08 aogg

No nothing wrong with the image, just need to upgrade the docker version.

jkevinaxioned avatar Aug 24 '23 13:08 jkevinaxioned

The current version of docker 20.10.7 is already very new, why do you need to upgrade to version 23 and why do you not support version 20?

And what I found the solution is that I need to turn on the system permissions-- privileged. Add-- privileged will run, it doesn't make sense.

aogg avatar Aug 31 '23 02:08 aogg

--privileged worked? then I'd guess that it is likely a seccomp denial similar to https://github.com/nodejs/docker-node/issues/1931, and https://github.com/nodejs/docker-node/issues/1932, and so https://github.com/docker-library/python/issues/837#issuecomment-1599640563 has some ideas for a temporary workaround (try --security-opt seccomp=unconfined), a longer workaround (try a different base OS, like -bullseye) and fix (update libseccomp and docker).

yosifkit avatar Sep 05 '23 21:09 yosifkit