Hi Stefano,

Starting it as root isn't a problem as long as you allow it to drop
privileges to another user. In some cases it may be required for
opening privileged network ports for example.

By default mosquitto will try to drop privileges to the "mosquitto"
user. This is by design. If you want it to stay running as root you
should put "user root" into mosquitto.conf. Specifying the "user"
option with no user is invalid and will result in the broker being
unable to load the config file, exactly as you have found.

Could you address problems like this to the mqtt-users mailing list?
It isn't well named, but is for discussion of mosquitto user based
issues. The mosquitto-devel mailing list is intended for people
developing mosquitto itself.

Best regards,

Roger


On Mon, Jun 18, 2012 at 2:35 PM, stefano costa
<[email protected]> wrote:
> Hello,
> I'm running "mosquitto -d -c /etc/mosquitto/mosquitto.conf" as root on a ARM
> system. I know this is not recommended; anyway I'm seeing an error:
>
> mosquitto.conf containing "user mosq" (example)
> --> Error: Invalid user 'mosq'. (correct!)
>
> mosquitto.conf containing NO "user" statement
> --> Error: Invalid user 'mosquitto'. (not correct! maybe some unintentional
> default?)
>
> mosquitto.conf containing "user" statement without any user specified
> --> Error: Empty user value in configuration.  (correct?)
> --> Error: Unable to open configuration file.  (correct?)
>
> Is this correct on 0.16
>
> --
>  Stefano Costa, R&D Manager
>  M +39 335 6565749
>  Skype stefanocosta.bluewind
>  http://www.bluewind.it/stefanoco?code=11
>
>
> --
> Mailing list: https://launchpad.net/~mosquitto-devel
> Post to     : [email protected]
> Unsubscribe : https://launchpad.net/~mosquitto-devel
> More help   : https://help.launchpad.net/ListHelp

-- 
Mailing list: https://launchpad.net/~mosquitto-devel
Post to     : [email protected]
Unsubscribe : https://launchpad.net/~mosquitto-devel
More help   : https://help.launchpad.net/ListHelp

Reply via email to