If you use Mosquitto MQTT Broker, turn off Saved Messages using the official method provided by Mosquitto.
First find the mosquitto.conf file
(In my Ubuntu / EC2 instance, it is stored in the / etc / mosquitto directory, I assume that the path to the mosquitto.conf file is / etc / mosquitto / mosquitto.conf)
Edit with your favorite text editor, my nano.
sudo nano /etc/mosquitto/mosquitto.conf
and in this file replace “constancy is false” instead of “constancy is true”
persistence false
Now save the file (if you use nano, press Ctrl + O and then type to save, Ctrl + X to exit)
Now restart the mosquito using the commands below
sudo service mosquitto stop sudo service mosquitto start
Note: If this configuration path does not exist in your case, find the configuration file using this command-
sudo find / -name mosquitto.conf

source share