Comments (5)
Can you upgrade the OTP to 27 and reproduce it there? You may need to compile a non-optimized build in order to see the stacktrace by setting OPTIMIZE=false make
.
from erlexec.
Upgrading OTP is not easy there. I will try to run this with OPTIMIZE=false make
and valgrind
enabled.
Do you think that might be related to the OTP version?
The failures happen now once a day or a week, and I can't find a way yet to reproduce them reliably.
from erlexec.
Not sure. It has been running pretty stably in many uses.
from erlexec.
That's the valgrind's memory detector output.
Unfortunately, I still don't have the Erlexec debug output; it was not written to a file.
==401359== Memcheck, a memory error detector
==401359== Copyright (C) 2002-2017, and GNU GPL'd, by Julian Seward et al.
==401359== Using Valgrind-3.16.1 and LibVEX; rerun with -h for copyright info
==401359== Command: /.../lib/erlexec-2.0.6/priv/x86_64-linux-gnu/exec-port
==401359== Parent PID: 401339
==401359==
==403175== Syscall param ioctl(TCSET{S,SW,SF}) points to uninitialised byte(s)
==403175== at 0x4C77850: tcsetattr (tcsetattr.c:83)
==403175== by 0x119440: ei::start_child(ei::CmdOptions&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >&) (exec_impl.cpp:568)
==403175== by 0x10DCD0: process_command(bool) (exec.cpp:398)
==403175== by 0x10D5B9: main (exec.cpp:291)
==403175== Address 0x1ffefff6f0 is on thread 1's stack
==403175== in frame #0, created by tcsetattr (tcsetattr.c:45)
==403175==
==403175== Conditional jump or move depends on uninitialised value(s)
==403175== at 0x1195A3: ei::start_child(ei::CmdOptions&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >&) (exec_impl.cpp:581)
==403175== by 0x10DCD0: process_command(bool) (exec.cpp:398)
==403175== by 0x10D5B9: main (exec.cpp:291)
==403175==
==404561== Syscall param ioctl(TCSET{S,SW,SF}) points to uninitialised byte(s)
==404561== at 0x4C77850: tcsetattr (tcsetattr.c:83)
==404561== by 0x119440: ei::start_child(ei::CmdOptions&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >&) (exec_impl.cpp:568)
==404561== by 0x10DCD0: process_command(bool) (exec.cpp:398)
==404561== by 0x10D5B9: main (exec.cpp:291)
==404561== Address 0x1ffefff6f0 is on thread 1's stack
==404561== in frame #0, created by tcsetattr (tcsetattr.c:45)
==404561==
==404561== Conditional jump or move depends on uninitialised value(s)
==404561== at 0x1195A3: ei::start_child(ei::CmdOptions&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >&) (exec_impl.cpp:581)
==404561== by 0x10DCD0: process_command(bool) (exec.cpp:398)
==404561== by 0x10D5B9: main (exec.cpp:291)
==404561==
==404561== Conditional jump or move depends on uninitialised value(s)
==404561== at 0x1195AC: ei::start_child(ei::CmdOptions&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >&) (exec_impl.cpp:581)
==404561== by 0x10DCD0: process_command(bool) (exec.cpp:398)
==404561== by 0x10D5B9: main (exec.cpp:291)
==404561==
==404561== Syscall param ioctl(TIOCSWINSZ) points to uninitialised byte(s)
==404561== at 0x4C78277: ioctl (syscall-template.S:120)
==404561== by 0x1145C4: ei::set_winsz(int, int, int) (exec_impl.cpp:182)
==404561== by 0x1195C5: ei::start_child(ei::CmdOptions&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >&) (exec_impl.cpp:582)
==404561== by 0x10DCD0: process_command(bool) (exec.cpp:398)
==404561== by 0x10D5B9: main (exec.cpp:291)
==404561== Address 0x1ffefff740 is on thread 1's stack
==404561== in frame #1, created by ei::set_winsz(int, int, int) (exec_impl.cpp:177)
==404561==
==405903== Syscall param ioctl(TCSET{S,SW,SF}) points to uninitialised byte(s)
==405903== at 0x4C77850: tcsetattr (tcsetattr.c:83)
==405903== by 0x119440: ei::start_child(ei::CmdOptions&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >&) (exec_impl.cpp:568)
==405903== by 0x10DCD0: process_command(bool) (exec.cpp:398)
==405903== by 0x10D5B9: main (exec.cpp:291)
==405903== Address 0x1ffefff6f0 is on thread 1's stack
==405903== in frame #0, created by tcsetattr (tcsetattr.c:45)
==405903==
==405903== Conditional jump or move depends on uninitialised value(s)
==405903== at 0x1195A3: ei::start_child(ei::CmdOptions&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >&) (exec_impl.cpp:581)
==405903== by 0x10DCD0: process_command(bool) (exec.cpp:398)
==405903== by 0x10D5B9: main (exec.cpp:291)
==405903==
==405903== Conditional jump or move depends on uninitialised value(s)
==405903== at 0x1195AC: ei::start_child(ei::CmdOptions&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >&) (exec_impl.cpp:581)
==405903== by 0x10DCD0: process_command(bool) (exec.cpp:398)
==405903== by 0x10D5B9: main (exec.cpp:291)
==405903==
==405903== Syscall param ioctl(TIOCSWINSZ) points to uninitialised byte(s)
==405903== at 0x4C78277: ioctl (syscall-template.S:120)
==405903== by 0x1145C4: ei::set_winsz(int, int, int) (exec_impl.cpp:182)
==405903== by 0x1195C5: ei::start_child(ei::CmdOptions&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >&) (exec_impl.cpp:582)
==405903== by 0x10DCD0: process_command(bool) (exec.cpp:398)
==405903== by 0x10D5B9: main (exec.cpp:291)
==405903== Address 0x1ffefff740 is on thread 1's stack
==405903== in frame #1, created by ei::set_winsz(int, int, int) (exec_impl.cpp:177)
==405903==
from erlexec.
It looks like it's pty
related. Here is a simple case to reproduce:
1> exec:run("/usr/bin/echo asd", [sync, stdout, stderr, pty]).
exec got msg from port: {1,{pid,74130}}
exec added monitor <0.87.0> for OsPid 74130exec got msg from port: {0,{stdout,74130,<<"asd\r\n">>}}
exec got msg from port: {0,{exit_status,74130,0}}
Pid 74130 exited with status: {0,0}
<0.87.0> 74130 got down message ({status,0}) (ismon=true)
{ok,[{stdout,[<<"asd\r\n">>]}]}
Results in valgrind report:
==74130== Syscall param ioctl(TCSET{S,SW,SF}) points to uninitialised byte(s)
==74130== at 0x4C46D10: tcsetattr (tcsetattr.c:83)
==74130== by 0x11DC65: ei::start_child(ei::CmdOptions&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >&) (exec_impl.cpp:568)
==74130== by 0x1121BA: process_command(bool) (exec.cpp:398)
==74130== by 0x10DBC1: main (exec.cpp:291)
==74130== Address 0x1ffeffe300 is on thread 1's stack
==74130== in frame #0, created by tcsetattr (tcsetattr.c:45)
==74130==
==74130== Conditional jump or move depends on uninitialised value(s)
==74130== at 0x11CE50: ei::start_child(ei::CmdOptions&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >&) (exec_impl.cpp:581)
==74130== by 0x1121BA: process_command(bool) (exec.cpp:398)
==74130== by 0x10DBC1: main (exec.cpp:291)
==74130==
==74130== Syscall param ioctl(TIOCSWINSZ) points to uninitialised byte(s)
==74130== at 0x4C4EDED: ioctl (ioctl.c:36)
==74130== by 0x1151FD: ei::set_winsz(int, int, int) (exec_impl.cpp:182)
==74130== by 0x11CE58: ei::start_child(ei::CmdOptions&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >&) (exec_impl.cpp:582)
==74130== by 0x1121BA: process_command(bool) (exec.cpp:398)
==74130== by 0x10DBC1: main (exec.cpp:291)
==74130== Address 0x1ffeffe340 is on thread 1's stack
==74130== in frame #1, created by ei::set_winsz(int, int, int) (exec_impl.cpp:177)
In my case, it's not critical to use the pty
option. It was used accidentally. But I hope that helps.
from erlexec.
Related Issues (20)
- Establishing/Supervising Communications With a Long-Running, Data Streaming Python Process HOT 3
- New release? Resolve port hanging HOT 2
- Exit codes appear to be x256 too large HOT 1
- erlexec on linux slows down when nofile limit is a large value HOT 2
- Mac OS error: use of undeclared identifier 'pipe2' HOT 2
- Could not compile dependency :erlexec HOT 15
- I am running into issues with elixir release HOT 3
- When native stdin process buffer is full, erlexec does not retry HOT 11
- PTY dynamic option test failing HOT 6
- Does 2.0.0 contain a breaking change? HOT 1
- Compile failure on OSX M1 mac HOT 4
- Passing command arguments as list HOT 1
- USE_POLL is not set HOT 1
- Failed build on FreeBSD HOT 9
- Compile fails on arm HOT 4
- Any command terminates with exit status 132 HOT 8
- Issue on ARM Mac HOT 9
- Erlexec compile fails on FreeBSD 14 HOT 1
- `debug(1)` impacts stdout of a command HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from erlexec.