Comment désinstaller Jmqtt avec installation locale mosquitto sur Atlas?

Salut,
J’ai installé Jmqtt sur mon Atlas et j’ai coché l’installation de mosquitto sur le plugin.
Après quelques essais je souhaite tout désinstaller et retrouver un système sans mosquitto.
J’ai trouvé un post sur la désinstallation de mosquitto mais je ne suis pas sûre du résultat.
Est-ce qu’en supprimant le plugin tout va se désinstaller (jmqtt et le mosquitto installé) où dois-je faire une manipulation particulière ?

Merci d’avance pour votre aide

Tu peux dejà désinstaller le plugin et ensuite lancer un

sudo apt-get purge --remove mosquitto*

(si tu es sur qu’il n’est pas utilisé par ailleurs)

1 « J'aime »

Salut,
Merci, comment vérifier qu’il a bien était supprimer stp ?

Bonjour,

Vérifier que cette commande ne renvoit rien :

systemctl status mosquitto.service

Salut,
Pour le moment l’Atlas renvoie ce résultat

mosquitto.service - Mosquitto MQTT v3.1/v3.1.1 Broker
   Loaded: loaded (/lib/systemd/system/mosquitto.service; enabled; vendor preset: enabled)
   Active: active (running) since Sun 2022-10-30 15:25:41 CET; 3 days ago
     Docs: man:mosquitto.conf(5)
           man:mosquitto(8)
 Main PID: 1641 (mosquitto)
    Tasks: 1 (limit: 4462)
   Memory: 2.3M
   CGroup: /system.slice/mosquitto.service
           `-1641 /usr/sbin/mosquitto -c /etc/mosquitto/mosquitto.conf

tu peux regarder si il y a encore des fichiers qui contiennent mosquitto dans le nom par exemple

sudo find / -iname mosquitto -print
1 « J'aime »

J’ai ce résultat

/var/log.hdd/mosquitto
/var/log/mosquitto
/var/lib/mosquitto
/usr/sbin/mosquitto
/usr/share/doc/mosquitto
/etc/logrotate.d/mosquitto
/etc/init.d/mosquitto
/etc/mosquitto

Mais tu as lancé la commandé donnée par @ngrataloup ?

Oui mais elle a demandé une confirmation, j’ai relancé et je viens d’avoir ce retour

Reading package lists...
Building dependency tree...
Reading state information...
Package 'mosquitto-clients' is not installed, so not removed
Package 'mosquitto-dev' is not installed, so not removed
The following packages were automatically installed and are no longer required:
  libev4 libhttp-parser2.8 libstd-rust-1.41 libstd-rust-dev libuv1
  libwebsockets8
Use 'sudo apt autoremove' to remove them.
The following packages will be REMOVED:
  mosquitto*
0 upgraded, 0 newly installed, 1 to remove and 135 not upgraded.
After this operation, 357 kB disk space will be freed.
(Reading database ... 
(Reading database ... 5%
(Reading database ... 10%
(Reading database ... 15%
(Reading database ... 20%
(Reading database ... 25%
(Reading database ... 30%
(Reading database ... 35%
(Reading database ... 40%
(Reading database ... 45%
(Reading database ... 50%
(Reading database ... 55%
(Reading database ... 60%
(Reading database ... 65%
(Reading database ... 70%
(Reading database ... 75%
(Reading database ... 80%
(Reading database ... 85%
(Reading database ... 90%
(Reading database ... 95%
(Reading database ... 100%
(Reading database ... 64486 files and directories currently installed.)
Removing mosquitto (1.5.7-1+deb10u1) ...
Processing triggers for man-db (2.8.5-2) ...
(Reading database ... 
(Reading database ... 5%
(Reading database ... 10%
(Reading database ... 15%
(Reading database ... 20%
(Reading database ... 25%
(Reading database ... 30%
(Reading database ... 35%
(Reading database ... 40%
(Reading database ... 45%
(Reading database ... 50%
(Reading database ... 55%
(Reading database ... 60%
(Reading database ... 65%
(Reading database ... 70%
(Reading database ... 75%
(Reading database ... 80%
(Reading database ... 85%
(Reading database ... 90%
(Reading database ... 95%
(Reading database ... 100%
(Reading database ... 64467 files and directories currently installed.)
Purging configuration files for mosquitto (1.5.7-1+deb10u1) ...
dpkg: warning: while removing mosquitto, directory '/etc/mosquitto/conf.d' not empty so not removed
Processing triggers for systemd (241-7~deb10u8) ...

Édit :
Je viens de relancer la commande

systemctl status mosquitto.service

Et là j’ai ce résultat

Unit mosquitto.service could not be found.

C’est mieux :wink:

Maintenant que donne

systemctl status mosquitto.service

?

Ça donne ce résultat

Unit mosquitto.service could not be found.

Parfait.

Il reste une trace dans /etc/mosquitto/conf.d.
Tu peux supprimer /etc/mosquitto/ si tu veux faire propre. Sinon c’est pas grave.

Relance la commande find !
… Et tu devrais être pas mal

Avec la commande

sudo find / -iname mosquitto -print

J’ai ce résultat

/var/log.hdd/mosquitto
/etc/mosquitto

J’aimerais faire propre pour pouvoir installer autre chose sans problème, est que vous pouvez m’aider à supprimer le reste svp ?

1 « J'aime »
sudo rm -rf /var/log.hdd/mosquitto /etc/mosquitto

Merci y a plus rien :wink::+1::+1::+1:

Merci a tous les deux ça a fonctionné nickel :+1::+1::+1::+1:

Édit pour résumer la solution pour les futurs recherches :

J’ai lancé cette commande

sudo apt-get purge --remove -y mosquitto*

Résultats

Reading package lists...
Building dependency tree...
Reading state information...
Package 'mosquitto-clients' is not installed, so not removed
Package 'mosquitto-dev' is not installed, so not removed
The following packages were automatically installed and are no longer required:
  libev4 libhttp-parser2.8 libstd-rust-1.41 libstd-rust-dev libuv1
  libwebsockets8
Use 'sudo apt autoremove' to remove them.
The following packages will be REMOVED:
  mosquitto*
0 upgraded, 0 newly installed, 1 to remove and 135 not upgraded.
After this operation, 357 kB disk space will be freed.
(Reading database ... 
(Reading database ... 5%
(Reading database ... 10%
(Reading database ... 15%
(Reading database ... 20%
(Reading database ... 25%
(Reading database ... 30%
(Reading database ... 35%
(Reading database ... 40%
(Reading database ... 45%
(Reading database ... 50%
(Reading database ... 55%
(Reading database ... 60%
(Reading database ... 65%
(Reading database ... 70%
(Reading database ... 75%
(Reading database ... 80%
(Reading database ... 85%
(Reading database ... 90%
(Reading database ... 95%
(Reading database ... 100%
(Reading database ... 64486 files and directories currently installed.)
Removing mosquitto (1.5.7-1+deb10u1) ...
Processing triggers for man-db (2.8.5-2) ...
(Reading database ... 
(Reading database ... 5%
(Reading database ... 10%
(Reading database ... 15%
(Reading database ... 20%
(Reading database ... 25%
(Reading database ... 30%
(Reading database ... 35%
(Reading database ... 40%
(Reading database ... 45%
(Reading database ... 50%
(Reading database ... 55%
(Reading database ... 60%
(Reading database ... 65%
(Reading database ... 70%
(Reading database ... 75%
(Reading database ... 80%
(Reading database ... 85%
(Reading database ... 90%
(Reading database ... 95%
(Reading database ... 100%
(Reading database ... 64467 files and directories currently installed.)
Purging configuration files for mosquitto (1.5.7-1+deb10u1) ...
dpkg: warning: while removing mosquitto, directory '/etc/mosquitto/conf.d' not empty so not removed
Processing triggers for systemd (241-7~deb10u8) ...

Puis cette commande

sudo find / -iname mosquitto -print

Résultats

/var/log.hdd/mosquitto
/etc/mosquitto

Et enfin cette commande

sudo rm -rf /var/log.hdd/mosquitto /etc/mosquitto

Relance pour vérification

systemctl status mosquitto.service

Résultat final

Unit mosquitto.service could not be found.

C’est la commande find qui t’a donné ce résultat, pas systemctl :wink:

Lol oui c’est ce que j’étais en train de me disais en relisant le résumé de la procédure :wink:

Le smartphone n’aide pas :yum:

Solution avec procédure validée ok pour vous 2 ?