I copied the example mosquitto.conf to /etc/mosquitto then added these 
lines:

listener 1883
allow_anonymous true

and now the broker is working again. Thanks very much for the help.

On Monday, December 27, 2021 at 11:37:59 AM UTC-7 Greg Troxel wrote:

>
> Timothy Buchanan <timothye...@gmail.com> writes:
>
> > When I start mosquitto manually, it will work only locally, that is, 
> from 
> > one instance of terminal to another, but will not pick up subscribed 
> > messages published by a device on the same LAN. Do these error messages 
> on 
> > install tell me how to troubleshoot mosquitto? Thanks for any help.
>
> As Karen says, this is probably due to a change in default behavior for
> mosquitto 2. Basically, it's a bug for a program to listen on the
> network by default, when it can make sense to only be on localhost.
> Certainly one can make mosquitto 2.0.x listen on the network beyond
> localhost.
>
> It sounds like you do not have a configuration file and have not
> configured authentication or an explicit listener. Basically, don't do
> that - read the docs and set up mosquitto intentionally.
>
>
> Note the man page
>
> -p, --port
> Listen on the port specified. May be specified up to 10 times to
> open multiple sockets listening on different ports.
>
> Important
> In version 1.6.x and earlier, the listener defined by -p (or
> the default port of 1883) would be bound to all interfaces and
> so be accessible from any network. It could also be used in
> combination with -c.
>
> From version 2.0 onwards, the listeners defined with -p are
> bound to the loopback interface only, and so can only be
> connected to from the local machine. If both -p is used and a
> listener is defined in a configuration file, then the -p
> options are IGNORED.
>
> See also ChangeLog.txt in the sources
>
> 2.0.0 - 2020-12-03
> ==================
>
> Breaking changes:
>
> - When the Mosquitto broker is run without configuring any listeners it 
> will
> now bind to the loopback interfaces 127.0.0.1 and/or ::1. This means that
> only connections from the local host will be possible.
>
> - All listeners now default to `allow_anonymous false` unless explicitly 
> set
> to true in the configuration file. This means that when configuring a
> listener the user must either configure an authentication and access 
> control
> method, or set `allow_anonymous true`. When the broker is run without a
> configured listener, and so binds to the loopback interface, anonymous
> connections are allowed.
>

-- 
You received this message because you are subscribed to the Google Groups 
"weewx-user" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to weewx-user+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/weewx-user/c4887d55-13eb-45a7-8ef2-f20a65069d8en%40googlegroups.com.

Reply via email to