[Resolved] accept: Bad file descriptor



  • I build a Gateway on Rpi. Post build it was working fine. I reboot and it stops working. Unable to interpret what this means. Please help. I did go through the forum but not able to solve it. I am using the latest 2.2.0 release. I ruled out hardware and radio issues as one of my node was able to communicate and send messages.

    Any help would be appreciated.
    Thanks

    pi@myhome:~/MySensors $ sudo ./bin/mysgw -d
    mysgw: Starting gateway...
    mysgw: Protocol version - 2.2.0
    mysgw: MCO:BGN:INIT GW,CP=RNNGL---,VER=2.2.0
    mysgw: TSF:LRT:OK
    mysgw: TSM:INIT
    mysgw: TSF:WUR:MS=0
    mysgw: TSM:INIT:TSP OK
    mysgw: TSM:INIT:GW MODE
    mysgw: TSM:READY:ID=0,PAR=0,DIS=0
    mysgw: MCO:REG:NOT NEEDED
    mysgw: bind: Address already in use
    mysgw: Failed to bind!
    mysgw: MCO:BGN:STP
    mysgw: MCO:BGN:INIT OK,TSP=1
    mysgw: accept: Bad file descriptor
    mysgw: accept: Bad file descriptor
    mysgw: accept: Bad file descriptor
    mysgw: accept: Bad file descriptor
    mysgw: accept: Bad file descriptor

  • Mod

    That's probably because the service is running in background. Type sudo service mysgw stop then the command you used


  • Mod

    @suresh-mali said in accept: Bad file descriptor:

    bind: Address already in use

    This means something else is already listening on the same port. My guess is that another instance of the gateway has already been started, or some other program is using the same port.

    You can use netstat -l -p to see the process id of the program that is already using the port.



  • Thanks @mfalkvidd and @gohan . That helped.


Log in to reply
 

Suggested Topics

  • 3
  • 15
  • 2
  • 2
  • 3
  • 2

1
Online

11.2k
Users

11.1k
Topics

112.5k
Posts