Hi
I want to create some functionality that requires my program to list physical disk drives and their attributes to the user when my program is run in Linux Mint, Ubuntu environments etc in a similar way to how Gnome Disk Manager does it in Linux Mint (
https://git.gnome.org/browse/gnome-disk-utility/) - see attached screenshot. i.e. Model number of the disk, manufacturer, serial number, as well as size, partitions, and so on.
So although I realise I could parse /etc/mtab and\or /etc/fstab as mentioned in
http://forum.lazarus.freepascal.org/index.php/topic,15943.0.html for some info, most likely much of that would be "/dev/sda1..." etc; my needs are bit more specific about the attached disks.
I've looked through the C code of the GDM project, but regret that I can't actually work out what parts of Linux or what calls it is making to obtain this information. Is it querying SMART or something? If so, how?
Any ideas? Anyone had to do this before? Linux specifically.