### Intuitive to Use.Easy to manage.

300.000 administrators have chosen PRTG to monitor their network. Find out how you can reduce cost, increase QoS and ease planning, as well.

### What is this?

This knowledgebase contains questions and answers about PRTG Network Monitor and network monitoring in general. You are invited to get involved by asking and answering questions!

View all Tags

# Folder monitor on domain-based DFS namespace

#### 0

How are we supposed to configure the Folder monitor to check the ages of files in a domain-based DFS namespace?

Let's say (for example) I have a path of:

\\corp.local\company\public\temp

and want to check that no files in there are older than 30 days. The sensor help specifies that:

If the folder is located on a network device, use the UNC path without the computer name (for example, only ''path\to\folder'' instead of ''\\computerName\path\to\folder''). The computer name will be inherited from the parent device of this sensor.

I've created a device with a IPv4/DNS entry of corp.local and in the Folder sensor under this device specified the folder as company\public\temp however the sensor returns an error code of "Cannot access folder: The folder doesn't exist (code: PE032)".

Am I doing something wrong, or are domain-based namespaces not supported by this type of sensor?

Created on Mar 16, 2018 5:29:00 PM by

#### 1

Hi Andreas,

I thought that might be the case. In case anyone else is after this functionality, I've written a very basic EXE/XML custom PowerShell script which will do the job, which takes two parameters. $searchPath is the full domain-based DFS path,$daysToScan is the maximum age of files, any of which are older than this value will be added to the returned count value.

Using the example path in the question and counting all files older than 30 days, the parms passed to PRTG's "Parameters" field in the sensor config would be:

\\corp.local\company\public\temp 30

Full script code available at: https://pastebin.com/c3s7r7aj

Thanks!

Created on Mar 28, 2018 1:11:29 PM by

# 3 Replies

#### 0

Hi Dominic,

Thank you very much for your KB-Post. I'm very much afraid we do not have native sensors for this in PRTG.

One option would be to write a custom script for this, and then running it as a Custom Sensor.

Kind regards,
Andreas Günther, Technical Support

Created on Mar 19, 2018 12:38:28 PM by

#### 1

Hi Andreas,

I thought that might be the case. In case anyone else is after this functionality, I've written a very basic EXE/XML custom PowerShell script which will do the job, which takes two parameters. $searchPath is the full domain-based DFS path,$daysToScan is the maximum age of files, any of which are older than this value will be added to the returned count value.

Using the example path in the question and counting all files older than 30 days, the parms passed to PRTG's "Parameters" field in the sensor config would be:

\\corp.local\company\public\temp 30

Full script code available at: https://pastebin.com/c3s7r7aj

Thanks!

Created on Mar 28, 2018 1:11:29 PM by

#### 0

Hi Dominic,

Thank you very much for sharing!

Kind regards,
Andreas Günther, Technical Support

Created on Mar 29, 2018 9:31:40 AM by