It is a general issue with D365FO development on those development VMs (virtual machines) when it is not working as planned, in the end we throw it away and start over. In the next blog I will explain some tricks to solve issues on the disk space. Look at the next example, we use a disk of 32GB and need 20 of them so we have 640 GB of disk space.
Of course, check the prices: Pricing – Managed Disks | Microsoft Azure.
Besides the disk size I also use DS13 V2, so I can upgrade to Managed Disks: Performance tuning development VM (Virtual Machine) – Kaya Consulting (kaya-consulting.com)
Why not 10 * 64 GB or 5 * 128 GB? It is all about IOPS!
Later, in Azure it will look like below.
When we look at the VM with Disk Management we see a striped disk that has partitions for database and ‘AOT (Application Object Tree) drive.’
So far so good, but the developer needs a good database and when restoring, scenarios like the next picture may occur.
We are stuck, no space on the G drive. And plenty of space on those other drives. So, let us adept, we start with shrinking the other disks. NOTE: K drive needs 15 GB free space for installations started from LCS (Life Cycle Services).
After shrinking we add the created free space to the G Drive.
• In case you still run into disk space issues, use the next SQL script to compress the database:
|EXECUTE sp_msForEachTable ‘ Print ”?”;SET QUOTED_IDENTIFIER ON|
;IF EXISTS (Select * from sys.indexes
Where object_id = object_id(”?”) And type=6)
ALTER INDEX ALL ON ? REBUILD ELSE
ALTER INDEX ALL ON ? REBUILD WITH (data_compression=PAGE,FILLFACTOR=99)’
- Another trick is dropping the retail database, it is in any installation package, the script name is DropAllRetailChannelDbObjects.
- Set the database recovery model to simple will reduce the database log disk size.
- Check the SQL report “Disk Usage by Top Tables.”
- Add an additional disk:
Of Course, I would love to give you a golden rule for size of the bacpac file in relation to the needed disk space. I can give you a refence a 9 Gb Bacpac file results in a 90 Gb Database MDF file. So Bacpac file size multiply by 10. It is still a guesstimate 🙁