Report multiple partitions/hard disk
Closed this issue · 1 comments
Munki only reports the main partition free space in its reports.
Sal-postflight takes that information, add the total size and sends that to the sal server.
In our environnement we have one partition for OS and one for home directories for various reasons. It might also be interesting for some Macs which do have multiple hard disk such as Mac Minis.
Currently, in sal, the Machine model only takes into account a single hard disk.
Perhaps we could extend sal-postflight into sending back every partition information, which would allow us to display on the dashboard machines with any partition/hard drive falling below threshold.
sal-postflight
- Get listing of partition (diskutil list and discard EFI/Apple_Boot partitions)
- Get partition free space/total size (diskutil info diskId) also make sure partition is marked internal so we do not report USB disks for example
- Send a list to our sal master
sal
- Decouple the hard drive from the Machine model, create a model with PK to Machine, space left/total and name fields and property to get percentage
- Create south migration to handle previous data
- Modify Disk Space plugin to look for one or more HD per machine
- Modify single machine view to display one or more HD informations.
I haven't started writing anything yet, but I wanted input on this.
Thanks a lot !
This would be more suited to a plugin - you can run whatever you need to via Facter or a Munki Condition and then your plugin and look for a certain prefix to get all of the information (my_hd_plugin_*
for example). This isn't something I'm likely to put into the core, but it's totally possible with a plugin.