[AWS] AWS and systemd on RPi2 debian jessie
Armin Danziger
it-d at nziger.de
Fri Apr 17 17:49:57 CEST 2015
Good morning,
I hope this is the right place where to ask for help with my following
problem (?) .. :
I have written an application with AWS3.2.0 (great software, by the way)
running on the raspberry pi 2 (debian jessie) using TLS and websockets
and finally wanted to get it running with systemd. Until now I simply
used the terminal to start it.
The problem now is, the port won't open. I tried ports 8080, 3975 and
39875 (-> this won't be the problem), also tried starting the
application as root via systemd (and of course set the correct working
directory). Next, I jumped with gdb into the running process (which was
started by systemd), and there was no thread calling "poll" in libc.
Actually, a bunch of aws-threads were simply missing. Running the
application on the terminal (so without systemd), the following is the
list of threads:
(gdb) info threads
Id Target Id Frame
13 Thread 0x74c80450 (LWP 3452) "image_resizer" 0x7560b534 in
__libc_do_syscall () from /lib/arm-linux-gnueabihf/libpthread.so.0
12 Thread 0x74a80450 (LWP 3453) "listener" 0x7560b534 in
__libc_do_syscall () from /lib/arm-linux-gnueabihf/libpthread.so.0
11 Thread 0x74819450 (LWP 3466) "A1391b(1)" 0x7560b534 in
__libc_do_syscall () from /lib/arm-linux-gnueabihf/libpthread.so.0
10 Thread 0x744ff450 (LWP 3467) "A1391b(2)" 0x751486a0 in poll ()
from /lib/arm-linux-gnueabihf/libc.so.6 9 Thread 0x741ff450 (LWP
3468) "A1391b(3)" 0x7560b534 in __libc_do_syscall ()
from /lib/arm-linux-gnueabihf/libpthread.so.0 8 Thread 0x73eff450
(LWP 3469) "A1391b(4)" 0x7560b534 in __libc_do_syscall ()
from /lib/arm-linux-gnueabihf/libpthread.so.0 7 Thread 0x73bff450
(LWP 3470) "A1391b(5)" 0x7560b534 in __libc_do_syscall ()
from /lib/arm-linux-gnueabihf/libpthread.so.0 6 Thread 0x738ff450
(LWP 3471) "cleaner_task" 0x7560b534 in __libc_do_syscall ()
from /lib/arm-linux-gnueabihf/libpthread.so.0 5 Thread 0x736ff450
(LWP 3472) "cleaner_task" 0x7560b534 in __libc_do_syscall ()
from /lib/arm-linux-gnueabihf/libpthread.so.0 4 Thread 0x734ff450
(LWP 3473) "message_watcher" 0x7560b534 in __libc_do_syscall ()
from /lib/arm-linux-gnueabihf/libpthread.so.0 3 Thread 0x732ff450
(LWP 3474) "message_readers" 0x7560b534 in __libc_do_syscall ()
from /lib/arm-linux-gnueabihf/libpthread.so.0 2 Thread 0x730ff450
(LWP 3475) "message_readers" 0x7560b534 in __libc_do_syscall ()
from /lib/arm-linux-gnueabihf/libpthread.so.0
* 1 Thread 0x74c81210 (LWP 3451) "server" 0x7560957e in read ()
from /lib/arm-linux-gnueabihf/libpthread.so.0
But with systemd, Threads 2 to 11 are not existing, so there are
just the "server", "listener" and "image_resizer" threads.
Now, as I have no idea where to look for the errors, I tried the same
with two demos shipping with the aws-download, the "hello-world" and
"dispatch". The first worked, but for the second, the following
exception is raised:
raised ADA.IO_EXCEPTIONS.END_ERROR : a-textio.adb:608
Now, I am not really sure what to examine next, and it feels a bit
strange to simply detach a screen-session, to simulate the application
running as daemon.
Do you have some idea, which pitfall I have not seen (or created
myself), when in comes to systemd and aws, or maybe a hint, where to
look for the error / another approach to hunt it down?
Greetings,
Armin
More information about the AWS
mailing list