@Bluefox:
Что говорит "iobroker list instances" ? `
root@cubietruck:~# iobroker list instances
events.js:160
throw er; // Unhandled 'error' event
^
Error: listen EADDRINUSE 127.0.0.1:9001
at Object.exports._errnoException (util.js:1020:11)
at exports._exceptionWithHostPort (util.js:1043:20)
at Server._listen2 (net.js:1258:14)
at listen (net.js:1294:10)
at net.js:1404:9
at _combinedTickCallback (internal/process/next_tick.js:83:11)
at process._tickCallback (internal/process/next_tick.js:104:9)
root@cubietruck:~#
error говорит. Как лечить?
Вроде бы это"Error: listen EADDRINUSE 127.0.0.1:9001" говорит о том что этот порт уже используется. Это странно, потому что я никаких изменений, которые могли привести к появлению еще каких-то служб, слушающих порты, не делал.
root@cubietruck:~# netstat -tunlp
! Active Internet connections (only servers)
! Proto Recv-Q Send-Q Local Address Foreign Address State PID/Program name
! tcp 0 0 0.0.0.0:1880 0.0.0.0:* LISTEN 19221/node-red
! tcp 0 0 127.0.0.1:9000 0.0.0.0:* LISTEN 31520/iobroker.js-c
! tcp 0 0 127.0.0.1:9001 0.0.0.0:* LISTEN 31520/iobroker.js-c
root@cubietruck:~# netstat -a -o | grep 9001
! tcp 0 0 localhost:9001 : LISTEN off (0.00/0/0)
! tcp 0 0 localhost:9001 localhost:36746 TIME_WAIT timewait (46.55/0/0)
! tcp 0 0 localhost:50000 localhost:9001 ESTABLISHED off (0.00/0/0)
! tcp 294 341548 localhost:9001 localhost:36938 ESTABLISHED unkn-4 (0.21/0/0)
! tcp 0 0 localhost:54468 localhost:9001 ESTABLISHED off (0.00/0/0)
! tcp 0 0 localhost:49990 localhost:9001 ESTABLISHED off (0.00/0/0)
! tcp 0 0 localhost:9001 localhost:36866 TIME_WAIT timewait (46.66/0/0)
! tcp 0 0 localhost:49930 localhost:9001 ESTABLISHED off (0.00/0/0)
! tcp 0 0 localhost:50074 localhost:9001 ESTABLISHED off (0.00/0/0)
! tcp 788238 49 localhost:36938 localhost:9001 ESTABLISHED on (0.24/0/0)
! tcp 0 0 localhost:9001 localhost:50006 ESTABLISHED off (0.00/0/0)
! tcp 0 0 localhost:9001 localhost:50074 ESTABLISHED off (0.00/0/0)
! tcp 0 0 localhost:9001 localhost:54468 ESTABLISHED off (0.00/0/0)
! tcp 0 0 localhost:9001 localhost:50000 ESTABLISHED off (0.00/0/0)
! tcp 0 0 localhost:9001 localhost:36936 TIME_WAIT timewait (49.51/0/0)
! tcp 0 0 localhost:9001 localhost:49930 ESTABLISHED off (0.00/0/0)
! tcp 0 0 localhost:50006 localhost:9001 ESTABLISHED off (0.00/0/0)
! tcp 0 0 localhost:9001 localhost:36940 TIME_WAIT timewait (49.66/0/0)
! tcp 0 0 localhost:9001 localhost:49990 ESTABLISHED off (0.00/0/0)
! root@cubietruck:~#
root@cubietruck:~# lsof -i tcp:9001
! COMMAND PID USER FD TYPE DEVICE SIZE/OFF NODE NAME
! io.megadd 2507 root 12u IPv4 3675984 0t0 TCP localhost:49990->localhost:9001 (ESTABLISHED)
! io.node-r 2513 root 12u IPv4 3675998 0t0 TCP localhost:50000->localhost:9001 (ESTABLISHED)
! io.web.0 9540 root 11u IPv4 3676213 0t0 TCP localhost:50074->localhost:9001 (ESTABLISHED)
! io.admin. 12873 root 11u IPv4 3882172 0t0 TCP localhost:37720->localhost:9001 (ESTABLISHED)
! node-red 19221 root 13u IPv4 3693851 0t0 TCP localhost:54468->localhost:9001 (ESTABLISHED)
! io.megadd 20337 root 11u IPv4 3675902 0t0 TCP localhost:49930->localhost:9001 (ESTABLISHED)
! io.discov 20343 root 11u IPv4 3676001 0t0 TCP localhost:50006->localhost:9001 (ESTABLISHED)
! iobroker. 31520 root 12u IPv4 399252 0t0 TCP localhost:9001 (LISTEN)
! iobroker. 31520 root 13u IPv4 3675985 0t0 TCP localhost:9001->localhost:49990 (ESTABLISHED)
! iobroker. 31520 root 15u IPv4 3674837 0t0 TCP localhost:9001->localhost:50000 (ESTABLISHED)
! iobroker. 31520 root 19u IPv4 3674841 0t0 TCP localhost:9001->localhost:50006 (ESTABLISHED)
! iobroker. 31520 root 23u IPv4 3694711 0t0 TCP localhost:9001->localhost:54468 (ESTABLISHED)
! iobroker. 31520 root 26u IPv4 3882173 0t0 TCP localhost:9001->localhost:37720 (ESTABLISHED)
! iobroker. 31520 root 28u IPv4 3674924 0t0 TCP localhost:9001->localhost:50074 (ESTABLISHED)
! iobroker. 31520 root 30u IPv4 3675914 0t0 TCP localhost:9001->localhost:49930 (ESTABLISHED)
! root@cubietruck:~#
Останавливаю Iobroker и на порту 9001 сервисов не видно. Но запустить его не получается из-за вышеописанной ошибки.
root@cubietruck:~# iobroker stop
Stopping iobroker controller daemon…
iobroker controller daemon stopped.
Exit code for "killall.sh": 0
root@cubietruck:~# netstat -tunlp
! Active Internet connections (only servers)
! Proto Recv-Q Send-Q Local Address Foreign Address State PID/Program name
! tcp 0 0 127.0.0.1:3306 0.0.0.0:* LISTEN 1236/mysqld
! tcp 0 0 0.0.0.0:80 0.0.0.0:* LISTEN 799/nginx -g daemon
! tcp 0 0 0.0.0.0:8881 0.0.0.0:* LISTEN 915/motion
! tcp 0 0 0.0.0.0:8882 0.0.0.0:* LISTEN 915/motion
! tcp 0 0 0.0.0.0:22 0.0.0.0:* LISTEN 642/sshd
! tcp6 0 0 :::5880 :::* LISTEN 25028/apache2
! tcp6 0 0 :::80 :::* LISTEN 799/nginx -g daemon
! tcp6 0 0 :::22 :::* LISTEN 642/sshd
! udp 0 0 0.0.0.0:20466 0.0.0.0:* 679/dhclient
! udp 0 0 0.0.0.0:68 0.0.0.0:* 679/dhclient
! udp 0 0 192.168.55.2:123 0.0.0.0:* 820/ntpd
! udp 0 0 127.0.0.1:123 0.0.0.0:* 820/ntpd
! udp 0 0 0.0.0.0:123 0.0.0.0:* 820/ntpd
! udp6 0 0 ::1:123 :::* 820/ntpd
! udp6 0 0 fe80::45:6ff:fe42:9:123 :::* 820/ntpd
! udp6 0 0 :::123 :::* 820/ntpd
! udp6 0 0 :::27484 :::* 679/dhclient
! root@cubietruck:~#