# MMC up but not responding

**URL:** <https://forum.cedalo.com/t/mmc-up-but-not-responding/983>\
**Category:** Broker management and monitoring\
**Created:** [May 10, 2024, 9:29am UTC](https://forum.cedalo.com/t/mmc-up-but-not-responding/983 "2024-05-10T09:29:30Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![BarCar](https://yyz2.discourse-cdn.com/flex030/user_avatar/forum.cedalo.com/barcar/32/552_2.png) [@BarCar](https://forum.cedalo.com/u/BarCar)\
**Post date:** [May 10, 2024, 9:29am UTC](https://forum.cedalo.com/t/mmc-up-but-not-responding/983/1 "2024-05-10T09:29:30Z")

</div>

I’m running Mosquitto in Docker on a Raspberry Pi 5 and trying to add MMC. The MMC part of my compose file looks like this:

```auto
  management-center:
    image: cedalo/management-center:dev
    container_name: management-center
    environment:
        # Do not change these settings for the moment!
        CEDALO_MC_BROKER_ID: mosquitto-2.0
        CEDALO_MC_BROKER_NAME: Mosquitto 2.0
        CEDALO_MC_BROKER_URL: mqtt://${MQTT_HOST}:1883
        CEDALO_MC_BROKER_USERNAME: ${MQTT_USERNAME}
        CEDALO_MC_BROKER_PASSWORD: ${MQTT_PASSWORD}
        CEDALO_MC_PROXY_CONFIG_DIR: /management-center/config/config.json
    ports:
        - 1888:8088
    depends_on:
        - mosquitto
    network_mode: bridge   

```

The container starts ok - logs show this - some warnings that I think I can ignore:

```auto
2024-05-10T09:22:13.711205331Z Starting Management Center for Eclipse Mosquitto
2024-05-10T09:22:14.087775203Z No license key found or provided.
2024-05-10T09:22:14.283389587Z Fri, 10 May 2024 09:22:14 GMT express-session deprecated undefined resave option; provide resave option at start.js:180:10
2024-05-10T09:22:14.283466217Z Fri, 10 May 2024 09:22:14 GMT express-session deprecated undefined saveUninitialized option; provide saveUninitialized option at start.js:180:10
2024-05-10T09:22:14.286913024Z Connecting to "Mosquitto 2.0" on mqtt://myhostname.domain.com:1883
2024-05-10T09:22:14.312367896Z Started Mosquitto proxy at http://localhost:8088
2024-05-10T09:22:14.321776888Z "CEDALO_MC_PLUGIN_DIR" is not set. Skipping loading of plugins
2024-05-10T09:22:14.326667013Z Mosquitto proxy server started on port 8088
2024-05-10T09:22:14.334005980Z Connected to 'Mosquitto 2.0' at mqtt://myhostname.domain.com:1883

```

But when I try to browse to [http://myhostname.domain.com:1888](http://myhostname.domain.com:1888) I get “connection refused”.

I’ve seen other logs where I can see core and login plugins loading. I tried setting CEDALO\_MC\_PLUGIN\_DIR to /management-center/src/plugins but that didn’t help.

Am I missing something to make the MMC front-end listen on all interfaces?

---

<div class="post-metadata">

**Author:** ![Tizian](https://yyz2.discourse-cdn.com/flex030/user_avatar/forum.cedalo.com/tizian/32/33_2.png) [@Tizian](https://forum.cedalo.com/u/Tizian)\
**Post date:** [May 15, 2024, 7:04am UTC](https://forum.cedalo.com/t/mmc-up-but-not-responding/983/2 "2024-05-15T07:04:51Z")

</div>

Hello BarCar,

Can you set the following EnvVar: `CEDALO_MC_PROXY_HOST: ` `0.0.` `0.0`  
This is because by default MMC listens on localhost and inside docker localhost interfaces are not forwarded to the host machine.

---

<div class="post-metadata">

**Author:** ![BarCar](https://yyz2.discourse-cdn.com/flex030/user_avatar/forum.cedalo.com/barcar/32/552_2.png) [@BarCar](https://forum.cedalo.com/u/BarCar)\
**Post date:** [May 15, 2024, 8:38am UTC](https://forum.cedalo.com/t/mmc-up-but-not-responding/983/3 "2024-05-15T08:38:03Z")

</div>

Thanks for that suggestion Tizian.

I had already tried that with no change in behaviour.

---

<div class="post-metadata">

**Author:** ![sey](https://avatars.discourse-cdn.com/v4/letter/s/f4b2a3/32.png) [@sey](https://forum.cedalo.com/u/sey)\
**Post date:** [May 16, 2024, 8:20am UTC](https://forum.cedalo.com/t/mmc-up-but-not-responding/983/4 "2024-05-16T08:20:52Z")

</div>

Hi BarCar,

In my experience setting `CEDALO_MC_PROXY_HOST` variable to `"0.0.0.0"` should resolve the issue.  
I tried it out and it worked fine for me.

Here is my full setup:

docker-compose.yml:

```auto
version: '3.8'

services:
  mosquitto:
      container_name: mosquitto
      image: eclipse-mosquitto:2
      ports:
          - 1883:1883
          - 9001:9001
      volumes:
          - ./mosquitto/config:/mosquitto/config
          - ./mosquitto/data:/mosquitto/data
      networks:
          - mosquitto
  management-center:
    container_name: management-center
    image: cedalo/management-center:dev
    container_name: management-center
    environment:
        CEDALO_MC_BROKER_ID: mosquitto-2.0
        CEDALO_MC_PROXY_HOST: "0.0.0.0"
        CEDALO_MC_BROKER_NAME: Mosquitto 2.0
        CEDALO_MC_BROKER_URL: mqtt://${MQTT_HOST}:1883
        CEDALO_MC_BROKER_USERNAME: ${MQTT_USERNAME}
        CEDALO_MC_BROKER_PASSWORD: ${MQTT_PASSWORD}
        CEDALO_MC_USERNAME: ${MMC_USERNAME}
        CEDALO_MC_PASSWORD: ${MMC_PASSWORD}
    ports:
        - 1888:8088
    networks:
        - mosquitto
networks:
    mosquitto:
        name: mosquitto
        driver: bridge

```

directory structure:

```auto
.
├── docker-compose.yml
├── env.sh
└── mosquitto
    ├── config
    │ ├── mosquitto.conf
    │ └── passwd_file
    └── data

```

mosquitto.conf:

```auto
persistence true
persistence_location /mosquitto/data/
log_type subscribe
log_type unsubscribe
log_type websockets
log_type error
log_type warning
log_type notice
log_type information
log_dest stdout

password_file /mosquitto/config/passwd_file
allow_anonymous false

# MQTT Default listener
listener 1883 0.0.0.0

# MQTT over WebSockets
listener 9001 0.0.0.0
protocol websockets

```

env.sh:

```auto
export MQTT_USERNAME="admin"
export MQTT_PASSWORD="password"
export MQTT_HOST="mosquitto"
export MMC_USERNAME="cedalo"
export MMC_PASSWORD="password"

```

Steps to run the setup:

- install mosquitto\_psswd with `mosquitto` or `mosquitto-clients` package (`sudo apt install mosquitto-client` / `brew install mosquitto` etc)
- Generate mosquitto password file with `mosquitto_passwd -c ./mosquitto/passwd_file admin` (in this case I use username admin)
- Export the environment variables used in docker compose: `source ./env.sh`
- Run the docker compose: `docker-compose up -d`
- Check management-center logs with: `docker logs management-center`. In my case I get the following logs:

```auto
Starting Management Center for Eclipse Mosquitto
No license key found or provided.
Thu, 16 May 2024 08:00:32 GMT express-session deprecated undefined resave option; provide resave option at start.js:180:10
Thu, 16 May 2024 08:00:32 GMT express-session deprecated undefined saveUninitialized option; provide saveUninitialized option at start.js:180:10
Connecting to "Mosquitto 2.0" on mqtt://mosquitto:1883
Started Mosquitto proxy at http://localhost:8088
"CEDALO_MC_PLUGIN_DIR" is not set. Skipping loading of plugins
Mosquitto proxy server started on port 8088
Connected to 'Mosquitto 2.0' at mqtt://mosquitto:1883

```

- Go to `http://localhost:1888` and login with credentials defined with `MMC_USERNAME` and `MMC_PASSWORD` environment variables.

However, if I remove `CEDALO_MC_PROXY_HOST` from the docker compse file, I get behavior that you describe and cannot reach MMC.  
Note that you can of course also have mosquitto running externally on some other machine in your network and not necessarily define in the same docker-compose. I use it just as a proof of concept

---

<div class="post-metadata">

**Author:** ![BarCar](https://yyz2.discourse-cdn.com/flex030/user_avatar/forum.cedalo.com/barcar/32/552_2.png) [@BarCar](https://forum.cedalo.com/u/BarCar)\
**Post date:** [May 19, 2024, 11:10am UTC](https://forum.cedalo.com/t/mmc-up-but-not-responding/983/5 "2024-05-19T11:10:11Z")

</div>

Thanks sey.

I’m not sure what changed but it all started working when I rebuilt everything per your steps. The config looked the same but presumably I missed something.
