Hello Gregorio Montaño,
Greetings! Welcome to Microsoft Q&A Platform.
I understand that you are seeing a discrepancy between the “Total data stored” on the File shares (SMB) of your Storage account and the output of the df -h command. It is due to the calculations done by the Azure storage usage and the disk usage.
There are several factors like Azure's dashboard reflects the total data stored in your file shares like data from metadata, deleted files and any snapshots and if soft delete is enabled on that storage is also being reflected until it is deleted permanently.
The operating system Disk usage 'df -h' command shows the disk space usage of the mounted file, the df -h Reflects only the currently accessible files and their sizes, and it does not reflect the space of the metadata, deleted files and snapshots. Only shows the primary data and not reflects the replication of the other stored data.
Here is the doc for your reference: https://learn.microsoft.com/en-us/azure/virtual-machines/disks-shared-enable?tabs=azure-portal
Try setting up monitoring software on the servers that report to a central location, or you can create a PowerShell script that retrieves the data. More information about to create a PowerShell script can be seen in this blog as well, where you can further setup commands to monitor your free space in your network drive:
In addition, you can map the shared folder as a drive - this will show you how much free space is available on the shared folder. You can follow the steps to achieve this goal:
1)In windows explorer, browse to the network share, then to the folder that you want to check the disk usage, right client on the folder and select properties.
2)In the properties window, click on the "OES Info" tab, and check the "Space Available" field.
Similar thread for reference - https://stackoverflow.com/questions/55580258/how-to-get-the-remaining-amount-of-storage-space-in-a-shared-folder.
Hope this answer helps! please let us know if you have any further queries. I’m happy to assist you further.
Please "Accept the answer” and “up-vote” wherever the information provided helps you, this can be beneficial to other community members.