-
Notifications
You must be signed in to change notification settings - Fork 11
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
Segmentation fault upon request #2
Comments
It seems you don't have all files in place. It is a bug however so I will Do you still have it when you set up the shadow file with
|
Yes, same issue.
revorpcd output (still segfaults upon request):
JUCI console log:
|
Does it work better if you specify the plugin dir like this: revorpcd -p /usr/lib/juci/api? Are you starting and stopping directly or using /etc/init.d/juci? |
I started and stopped it directly.
When started using the init script, it just dies after opening/reloading JUCI. |
Why do you have netmode.lua there? That is not an openwrt-compatible plugin and it is not in latest default build either. Did you select all juci plugins instead of just selecting juci-full-openwrt and jucid? |
Yes, all plugins were selected during build. I'll unselect them and try again. |
You should not select any inteno plugins. They are only for iopsys builds. I will remove them in next version to avoid such confusion.. |
It has been removed. I have just removed it from the menu as well. It was On Tue, Apr 5, 2016 at 6:13 PM, Jason notifications@github.com wrote:
|
I have the same problem with a clean build:
Packages generated by build:
strace: https://github.com/mk-f/logs/blob/master/revorpcd_strace |
GDB-Trace:
|
what does "bt" say? I was not able to reproduce your bug. I did fix a few bugs in the json You can also run with "-vvv" to print more information. On Thu, Apr 7, 2016 at 4:14 PM, Fabian Müller-Knapp <
|
Thanks for the reply, i'm currently not in town, i will look in to this next week. |
Here comes the gdb-output:
in a fresh run:
|
Okay, for some reason |
no. If it was a threading issue, making them global would certainly not
|
I tried with v2.16.04 which crashed the same as master. After making the same changes to
|
Looks like you don't have a password setup. Check /etc/juci-shadow for a On Tue, Apr 19, 2016 at 1:58 PM, Fabian Müller-Knapp <
|
I have:
which is the result of: |
admin a94a8fe5ccb19ba61c4c0873d391e987982fbbd3 You can only use sha1sum. md5sum was a typo. |
Server sends you a token which is unique for each connection. Your browser does sha1(token + sha1(password)) and sends back the result (which is what you are seeing up there 4afe9637dfee32211bbf1945ede1362582946725). Server does the same thing but using the hash in the shadow file. If both are the same you will be logged in. Looks like something goes wrong somewhere inbetween for you. Are you sure it is not the changes you have made to json library? |
I tried with sha1 already - same result. Actually im not sure if this also concerns the json-library, ill keep digging. |
As valgrind is not available for armv5, i have build jucid against d.u.m.a (http://duma.sourceforge.net/) in hope of caching some memory corruptions but i had no luck. Jucid does now segfault as soon as it tries to load plugins:
I doubt that luaS_* is realy the culprit - again this looks like touching already freed memory, ts is somehow not accessible. Do you have any idea what could cause this? juci-openwrt-feed v2.16.05 |
Full backtrace:
|
That does not say much. It could be a faulty lua plugin. I have run it
|
I don't think so. The same error happens for each plugin if i disable them consecutively |
Okay, this has nothing to do with lua or the json-parsing. Musl assigns by default 80k stack-space to new threads which is just not enough for juci, resulting in inaccessible memory and segfaults. Increasing the stack-size to 128k fixes this (#5) |
Ah nice. Actually the extra memory can be freed up if necessary, it is
|
The server seems to start up just fine but as soon as it receives a request (when JUCI is opened) it segfaults.
The text was updated successfully, but these errors were encountered: