[Errno 111] Connection refused

Hi,

I just started working on confd. Started confd with command

       confd --foreground --verbose

Confd started with following end statement

Starting to listen for NETCONF SSH on myIP:2022
Starting to listen for NETCONF TCP on myIP:2023
Starting to listen for CLI SSH on myIP:2024
ConfD started vsn: 6.4

When I execute ‘netconf-console --hello’

it gives me

Failed to connect to localhost: [Errno 111] Connection refused

Did I miss anything ? Please help.

Hello, please can you test with netconf-console-tcp ?

In confd.conf ypu need to enable TCP transport

<netconf>     
         <transport> 
            <tcp>
                <enabled>true</enabled>
                <ip>127.0.0.1</ip>
                <port>2023</port>
            </tcp>
        </transport>
</netconf>     

I get Connection refused error

netconf-console-tcp --hello
Failed to connect to localhost: [Errno 111] Connection refused

Already edited confd.conf

<tcp>
        <enabled>true</enabled>
        <ip>myip</ip>
        <port>2023</port>
      </tcp>
    </transport>

The problem is that if you configure a specific IP-address (other than 127.0.0.1) in confd.conf, you can’t (per standard socket semantics) connect to it with 127.0.0.1 as target address (which is what netconf-console does per default, as can be seen from the “Failed to connect to localhost” error).

I.e. either configure the wildcard address like the examples do for the SSH transport, i.e. <ip>0.0.0.0</ip> (but use only loopback <ip>127.0.0.1</ip> for TCP transport since there is no authentication) - or give the specific IP address you configured with the --host option to netconf-console, e.g. --host=192.168.1.1.

Thanks, that helped. I have set ip to 127.0.0.1

Question - myip is the IP address of confd running server.

I have changed following tags as well. Should I change them to 127.0.0.1 ?


<ssh>
        <enabled>true</enabled>
        <ip>myip</ip>
        <port>2022</port>
      </ssh>

Though I have the same configuration of what you have mentioned here, still i could get the same error. please help me to resolve this error

image
still the same error continues please help in resolving this.

If you modify confd.conf you must tell ConfD to reload its configuration using the command

confd --reload

or restart ConfD.

Also, please describe exactly

  1. The complete command you are giving.

  2. Where you are giving that command, i.e. on the same host that ConfD is running on or somewhere else.

  3. The complete error message that you get.

Thank You !
Now it works