Skip to main content
Question

Monitor some files with CIFS Plugin

  • December 24, 2025
  • 0 replies
  • 2 views

🇬🇧

Hello,

I’d like to monitor a few database files to track their growth and guide the developers. I started testing the CIFS plugin, but I can’t get accurate graphs for all the files in a folder. I finally found a syntax that works.

​/usr/lib/centreon/plugins//centreon_protocol_cifs.pl --plugin=apps::protocols::cifs::plugin --mode=files-size --hostname='192.168.0.1' --cifs-username='DOMAIN/USER' --cifs-password='xxxxxxxxxxx' --timeout=''   --file='/Depot/truc.1' --directory='/Depot' --max-depth='5' --warning-size='' --critical-size='' --verbose --file='/Depot/bidule.exe' --file='/Depot/machin.exe' --file='/Depot/Test.htm' --file='/Depot/chose.ps1'

Listing all the files works, but obviously it doesn’t work if new files are added…

So I have two questions:

  1. How can I monitor an entire folder without having to list every single file? Is that possible?
  2. How many files can I monitor without overloading the system? If I have 2,000 files, will Centreon go crazy trying to display all of them?

When I targeted a folder with 4 files at first, I got 4 graphs, but the file names weren’t shown. I tried another folder with 23 files and only got one graph for all of them. I imagine a technical limit was set to prevent RRD from being overwhelmed. On the other hand, I don’t need to take measurements more than once a day, so I think it’s manageable…

Thanks

Have a nice day.

 

🇨🇵

Bonjour,

Je voudrais monitorer quelques fichiers de base de données pour connaitre leurs croissance et aiguiller des devs. J’ai commencé à tester le plugin CIFS sauf que je n’arrive pas à avoir des graph’ précis pour l’ensemble des fichiers d’un dossier. J’ai fini par trouver une syntaxe qui fonctionne.

/usr/lib/centreon/plugins//centreon_protocol_cifs.pl --plugin=apps::protocols::cifs::plugin --mode=files-size --hostname='192.168.0.1' --cifs-username='DOMAIN/USER' --cifs-password='xxxxxxxxxxx' --timeout=''   --file='/Depot/truc.1' --directory='/Depot' --max-depth='5' --warning-size='' --critical-size='' --verbose --file='/Depot/bidule.exe' --file='/Depot/machin.exe' --file='/Depot/Test.htm' --file='/Depot/chose.ps1'

En listant tous les fichiers ça fonctionne mais ça marche évidemment pas s’il y en a des nouveaux…

J’ai donc 2 questions :

  1. Comment puis-je avoir l’intégralité d’un dossier sans avoir besoin de toute lister ? Est-ce possible ?
  1. Combien de fichier je peux cumuler sans que ça écroule tout ? Si j’ai 2000 fichiers, est-ce que Centreon va pas devenir fou pour afficher tout ça ? 

 

Quand j’ai ciblé un dossier avec 4 fichiers au début j’avais bien 4 graph’ mais sans les nom des fichiers d’indiqué. J’ai essayé un autre dossier avec 23 fichiers et j’ai qu’un seul graph’ pour l’ensemble. J’imagine qu’une limite technique a été imposée pour éviter de faire exploser RRD. D’un autre coté je n’ai pas besoin de prendre les mesures plus d’une fois par jour donc je me dis que c’est jouable…

 

Merci

 

Bonne journée