gchenuet / nest-datagraph

Nest thermostat dashboard and graph charts
MIT License
36 stars 17 forks source link

nest-datagraph_nestdatagraph_1 continual restarts #36

Closed jwjohns closed 5 years ago

jwjohns commented 5 years ago

I setup the ini, built the images, but when i run the app, it fails to start properly and throws nest-datagraph_nestdatagraph_1 exited with code 2 repeatedly.

I try and docker exec -it into the container and it fails as the container is continually restarting. This is posing an issue in debugging it.


Starting nest-datagraph_mariadb_1 ... done
Recreating nest-datagraph_nestdatagraph_1 ... done
Attaching to nest-datagraph_mariadb_1, nest-datagraph_nestdatagraph_1
mariadb_1        | 2019-05-30 21:33:32 0 [Note] mysqld (mysqld 10.3.15-MariaDB-1:10.3.15+maria~bionic) starting as process 1 ...
mariadb_1        | 2019-05-30 21:33:32 0 [Note] InnoDB: Using Linux native AIO
mariadb_1        | 2019-05-30 21:33:32 0 [Note] InnoDB: Mutexes and rw_locks use GCC atomic builtins
mariadb_1        | 2019-05-30 21:33:32 0 [Note] InnoDB: Uses event mutexes
mariadb_1        | 2019-05-30 21:33:32 0 [Note] InnoDB: Compressed tables use zlib 1.2.11
mariadb_1        | 2019-05-30 21:33:32 0 [Note] InnoDB: Number of pools: 1
mariadb_1        | 2019-05-30 21:33:32 0 [Note] InnoDB: Using SSE2 crc32 instructions
mariadb_1        | 2019-05-30 21:33:32 0 [Note] InnoDB: Initializing buffer pool, total size = 256M, instances = 1, chunk size = 128M
mariadb_1        | 2019-05-30 21:33:32 0 [Note] InnoDB: Completed initialization of buffer pool
mariadb_1        | 2019-05-30 21:33:32 0 [Note] InnoDB: If the mysqld execution user is authorized, page cleaner thread priority can be changed. See the man page of setpriority().
mariadb_1        | 2019-05-30 21:33:32 0 [Note] InnoDB: 128 out of 128 rollback segments are active.
mariadb_1        | 2019-05-30 21:33:32 0 [Note] InnoDB: Creating shared tablespace for temporary tables
mariadb_1        | 2019-05-30 21:33:32 0 [Note] InnoDB: Setting file './ibtmp1' size to 12 MB. Physically writing the file full; Please wait ...
mariadb_1        | 2019-05-30 21:33:32 0 [Note] InnoDB: File './ibtmp1' size is now 12 MB.
mariadb_1        | 2019-05-30 21:33:32 0 [Note] InnoDB: Waiting for purge to start
mariadb_1        | 2019-05-30 21:33:32 0 [Note] InnoDB: 10.3.15 started; log sequence number 1630869; transaction id 21
mariadb_1        | 2019-05-30 21:33:32 0 [Note] InnoDB: Loading buffer pool(s) from /var/lib/mysql/ib_buffer_pool
mariadb_1        | 2019-05-30 21:33:32 0 [Note] Plugin 'FEEDBACK' is disabled.
mariadb_1        | 2019-05-30 21:33:32 0 [Note] InnoDB: Buffer pool(s) load completed at 190530 21:33:32
mariadb_1        | 2019-05-30 21:33:32 0 [Note] Server socket created on IP: '::'.
mariadb_1        | 2019-05-30 21:33:32 0 [Warning] 'proxies_priv' entry '@% root@d6a171cf6df1' ignored in --skip-name-resolve mode.
mariadb_1        | 2019-05-30 21:33:32 0 [Note] Reading of all Master_info entries succeded
mariadb_1        | 2019-05-30 21:33:32 0 [Note] Added new Master_info '' to hash table
mariadb_1        | 2019-05-30 21:33:32 0 [Note] mysqld: ready for connections.
mariadb_1        | Version: '10.3.15-MariaDB-1:10.3.15+maria~bionic'  socket: '/var/run/mysqld/mysqld.sock'  port: 3306  mariadb.org binary distribution
: invalid option namentrypoint.sh: line 2: set: pipefail
nest-datagraph_nestdatagraph_1 exited with code 2
nest-datagraph_nestdatagraph_1 exited with code 2
nest-datagraph_nestdatagraph_1 exited with code 2
Gracefully stopping... (press Ctrl+C again to force)
Stopping nest-datagraph_nestdatagraph_1   ... done
Stopping nest-datagraph_mariadb_1         ... done```
gchenuet commented 5 years ago

We merged some PR about Docker bugs. Could you please retry ?

Thanks

jwjohns commented 5 years ago

I am still seeing similar behavior.


docker-compose logs --follow nestdatagraph
Attaching to nest-datagraph_nestdatagraph_1
: invalid option namentrypoint.sh: line 2: set: pipefail
: invalid option namentrypoint.sh: line 2: set: pipefail
: invalid option namentrypoint.sh: line 2: set: pipefail
: invalid option namentrypoint.sh: line 2: set: pipefail
: invalid option namentrypoint.sh: line 2: set: pipefail
: invalid option namentrypoint.sh: line 2: set: pipefail
: invalid option namentrypoint.sh: line 2: set: pipefail
: invalid option namentrypoint.sh: line 2: set: pipefail
: invalid option namentrypoint.sh: line 2: set: pipefail
: invalid option namentrypoint.sh: line 2: set: pipefail
: invalid option namentrypoint.sh: line 2: set: pipefail
: invalid option namentrypoint.sh: line 2: set: pipefail
: invalid option namentrypoint.sh: line 2: set: pipefail
: invalid option namentrypoint.sh: line 2: set: pipefail
: invalid option namentrypoint.sh: line 2: set: pipefail
: invalid option namentrypoint.sh: line 2: set: pipefail
: invalid option namentrypoint.sh: line 2: set: pipefail
: invalid option namentrypoint.sh: line 2: set: pipefail
: invalid option namentrypoint.sh: line 2: set: pipefail
: invalid option namentrypoint.sh: line 2: set: pipefail
: invalid option namentrypoint.sh: line 2: set: pipefail
: invalid option namentrypoint.sh: line 2: set: pipefail
: invalid option namentrypoint.sh: line 2: set: pipefail
: invalid option namentrypoint.sh: line 2: set: pipefail
: invalid option namentrypoint.sh: line 2: set: pipefail
: invalid option namentrypoint.sh: line 2: set: pipefail
: invalid option namentrypoint.sh: line 2: set: pipefail
: invalid option namentrypoint.sh: line 2: set: pipefail
: invalid option namentrypoint.sh: line 2: set: pipefail
: invalid option namentrypoint.sh: line 2: set: pipefail
nest-datagraph_nestdatagraph_1 exited with code 2```

if I can figure it out I will submit a PR
jwjohns commented 5 years ago
docker-compose logs --follow nestdatagraph
Attaching to nest-datagraph_nestdatagraph_1
: invalid option namentrypoint.sh: line 2: set: pipefail
nestdatagraph_1  | /entrypoint.sh: line 3: $'\r': command not found
: invalid option | /entrypoint.sh: line 4: set: -
nestdatagraph_1  | set: usage: set [-abefhkmnptuvxBCHP] [-o option-name] [--] [arg ...]
nestdatagraph_1  | /entrypoint.sh: line 5: $'\r': command not found
nestdatagraph_1  | /entrypoint.sh: line 6: syntax error near unexpected token `$'{\r''
'estdatagraph_1  | /entrypoint.sh: line 6: `check_database_connection() {
: invalid option namentrypoint.sh: line 2: set: pipefail
nestdatagraph_1  | /entrypoint.sh: line 3: $'\r': command not found
: invalid option | /entrypoint.sh: line 4: set: -
nestdatagraph_1  | set: usage: set [-abefhkmnptuvxBCHP] [-o option-name] [--] [arg ...]
nestdatagraph_1  | /entrypoint.sh: line 5: $'\r': command not found
nestdatagraph_1  | /entrypoint.sh: line 6: syntax error near unexpected token `$'{\r''
'estdatagraph_1  | /entrypoint.sh: line 6: `check_database_connection() {
: invalid option namentrypoint.sh: line 2: set: pipefail
nestdatagraph_1  | /entrypoint.sh: line 3: $'\r': command not found
: invalid option | /entrypoint.sh: line 4: set: -
nestdatagraph_1  | set: usage: set [-abefhkmnptuvxBCHP] [-o option-name] [--] [arg ...]
nestdatagraph_1  | /entrypoint.sh: line 5: $'\r': command not found
nestdatagraph_1  | /entrypoint.sh: line 6: syntax error near unexpected token `$'{\r''
'estdatagraph_1  | /entrypoint.sh: line 6: `check_database_connection() {
: invalid option namentrypoint.sh: line 2: set: pipefail
nestdatagraph_1  | /entrypoint.sh: line 3: $'\r': command not found
: invalid option | /entrypoint.sh: line 4: set: -
nestdatagraph_1  | set: usage: set [-abefhkmnptuvxBCHP] [-o option-name] [--] [arg ...]
nestdatagraph_1  | /entrypoint.sh: line 5: $'\r': command not found
nestdatagraph_1  | /entrypoint.sh: line 6: syntax error near unexpected token `$'{\r''
'estdatagraph_1  | /entrypoint.sh: line 6: `check_database_connection() {
: invalid option namentrypoint.sh: line 2: set: pipefail
nestdatagraph_1  | /entrypoint.sh: line 3: $'\r': command not found
: invalid option | /entrypoint.sh: line 4: set: -
nestdatagraph_1  | set: usage: set [-abefhkmnptuvxBCHP] [-o option-name] [--] [arg ...]
nestdatagraph_1  | /entrypoint.sh: line 5: $'\r': command not found
nestdatagraph_1  | /entrypoint.sh: line 6: syntax error near unexpected token `$'{\r''
'estdatagraph_1  | /entrypoint.sh: line 6: `check_database_connection() {
: invalid option namentrypoint.sh: line 2: set: pipefail
nestdatagraph_1  | /entrypoint.sh: line 3: $'\r': command not found
: invalid option | /entrypoint.sh: line 4: set: -
nestdatagraph_1  | set: usage: set [-abefhkmnptuvxBCHP] [-o option-name] [--] [arg ...]
nestdatagraph_1  | /entrypoint.sh: line 5: $'\r': command not found
nestdatagraph_1  | /entrypoint.sh: line 6: syntax error near unexpected token `$'{\r''
'estdatagraph_1  | /entrypoint.sh: line 6: `check_database_connection() {
: invalid option namentrypoint.sh: line 2: set: pipefail
nestdatagraph_1  | /entrypoint.sh: line 3: $'\r': command not found
: invalid option | /entrypoint.sh: line 4: set: -
nestdatagraph_1  | set: usage: set [-abefhkmnptuvxBCHP] [-o option-name] [--] [arg ...]
nestdatagraph_1  | /entrypoint.sh: line 5: $'\r': command not found
nestdatagraph_1  | /entrypoint.sh: line 6: syntax error near unexpected token `$'{\r''
'estdatagraph_1  | /entrypoint.sh: line 6: `check_database_connection() {
: invalid option namentrypoint.sh: line 2: set: pipefail
nestdatagraph_1  | /entrypoint.sh: line 3: $'\r': command not found
: invalid option | /entrypoint.sh: line 4: set: -
nestdatagraph_1  | set: usage: set [-abefhkmnptuvxBCHP] [-o option-name] [--] [arg ...]
nestdatagraph_1  | /entrypoint.sh: line 5: $'\r': command not found
nestdatagraph_1  | /entrypoint.sh: line 6: syntax error near unexpected token `$'{\r''
'estdatagraph_1  | /entrypoint.sh: line 6: `check_database_connection() {
: invalid option namentrypoint.sh: line 2: set: pipefail
nestdatagraph_1  | /entrypoint.sh: line 3: $'\r': command not found
: invalid option | /entrypoint.sh: line 4: set: -
nestdatagraph_1  | set: usage: set [-abefhkmnptuvxBCHP] [-o option-name] [--] [arg ...]
nestdatagraph_1  | /entrypoint.sh: line 5: $'\r': command not found
nestdatagraph_1  | /entrypoint.sh: line 6: syntax error near unexpected token `$'{\r''
'estdatagraph_1  | /entrypoint.sh: line 6: `check_database_connection() {
: invalid option namentrypoint.sh: line 2: set: pipefail
nestdatagraph_1  | /entrypoint.sh: line 3: $'\r': command not found
: invalid option | /entrypoint.sh: line 4: set: -
nestdatagraph_1  | set: usage: set [-abefhkmnptuvxBCHP] [-o option-name] [--] [arg ...]
nestdatagraph_1  | /entrypoint.sh: line 5: $'\r': command not found
nestdatagraph_1  | /entrypoint.sh: line 6: syntax error near unexpected token `$'{\r''
'estdatagraph_1  | /entrypoint.sh: line 6: `check_database_connection() {
nest-datagraph_nestdatagraph_1 exited with code 2
jwjohns commented 5 years ago

@gchenuet I think I figured it out. entrypoint.sh has CRLF line endings. Needed to be LF

nestdatagraph_1  | Starting Nest Datagraph! ...
nestdatagraph_1  | + /usr/bin/supervisord -n -c /etc/supervisor/supervisord.conf
nestdatagraph_1  | 2019-10-15 11:04:00,650 CRIT Set uid to user 0
nestdatagraph_1  | 2019-10-15 11:04:00,689 INFO RPC interface 'supervisor' initialized
nestdatagraph_1  | 2019-10-15 11:04:00,689 CRIT Server 'unix_http_server' running without any HTTP authentication checking
nestdatagraph_1  | 2019-10-15 11:04:00,690 INFO supervisord started with pid 25
nestdatagraph_1  | 2019-10-15 11:04:01,695 INFO spawned: 'php5-fpm' with pid 28
nestdatagraph_1  | 2019-10-15 11:04:01,699 INFO spawned: 'nginx' with pid 29
nestdatagraph_1  | 2019-10-15 11:04:02,920 INFO success: php5-fpm entered RUNNING state, process has stayed up for > than 1 seconds (startsecs)
nestdatagraph_1  | 2019-10-15 11:04:02,920 INFO success: nginx entered RUNNING state, process has stayed up for > than 1 seconds (startsecs)