-
Notifications
You must be signed in to change notification settings - Fork 318
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
cannot create context, error code 111 #1145
Comments
Wondering - can you check if iiod is still running when you get 111? |
Hmm yes, good idea, maybe it's just an iiod crash. I will check when it happens next time. |
@mhennerich I checked it, iiod was not running anymore. Does iiod store logs somewhere, or can I start it with command line parameters to enable logging? |
when I restart iiod manually with -d and provoke the crash again I can see this output: New client connected from 192.168.137.1
New client connected from 192.168.137.1
New client connected from 192.168.137.1
DEBUG: Buffer 0 created.
New client connected from 192.168.137.1
Client exited
DEBUG: Buffer 0 created.
Client exited
Client exited
Client exited
New client connected from 192.168.137.1
New client connected from 192.168.137.1
New client connected from 192.168.137.1
DEBUG: Buffer 0 created.
New client connected from 192.168.137.1
Client exited
DEBUG: Buffer 0 created.
New client connected from 192.168.137.1
Client exited
DEBUG: Buffer 0 created.
New client connected from 192.168.137.1
DEBUG: Buffer 0 created.
Client exited
DEBUG: Block 0 freed.
Segmentation fault
# |
can you run it (and make it crash) in gdb, so you can get a backtrace? |
I think gdb is not included in the pluto buildroot, so I would have to cross-compile it first right? |
There was already a gdb package available in buildroot. I added it to my board config and ran it again. I could not provoke the crash anymore. The weird thing is that the crash also does not happen anymore if I run iiod without gdb. It might have been a faulty buildroot build-state, buildroot is quite sensitive if one does not do clean rebuilds all the time. |
The crash happened again. I managed to reproduce it while running iiod in gdb. This is the output: @rgetz Stack back trace does not show much, because the stack is corrupted I am using 7ae4836 (and I don't see any relevant commits after this that could probably fix this crash) |
I think the crash is caused by a call to |
I used to call the following functions in this order
the crash does not happen anymore when I change the order to this:
@pcercuei is this behaviour correct? |
The crash also happens if I just call |
@pcercuei I mean this issue <3 |
I think the problem is that there are some iio_block_dequeue commands queued that get executed even after blocks are already freed. |
I think I have some new information. The crash seems to happen that a call to |
Hi @catkira, |
Sometimes when I do weird things, ie my remote libiio app crashes without closing the network context, I cannot create another context to my plutosdr connected via network.
The error message I get when I do
iio_info -u ip:192.168.137.2
isERROR: Unable to create IIO context ip:192.168.137.2: Connection refused (111)
I have to reboot plutosdr to recover from this.
The text was updated successfully, but these errors were encountered: