Bug 226170

Summary: gstat does not detect new devices (/dev/gpt/* & /dev/label/*)
Product: Base System Reporter: Ben RUBSON <ben.rubson>
Component: binAssignee: freebsd-geom (Nobody) <geom>
Status: New ---    
Severity: Affects Some People    
Priority: ---    
Version: 11.0-RELEASE   
Hardware: Any   
OS: Any   

Description Ben RUBSON 2018-02-24 14:34:20 UTC
Hi,

I automatically run gstat upon system startup to feed a performance reporting tool.
Here is the command launched :
# gstat -B -d -o -s -I30s -f"label/|gpt/"

Some seconds/minutes after system startup, I add some iSCSI disks needed for production :
# iscsictl -Aa

Unfortunately, gstat does not detect these new disks. Reproductible for each newly added disk.
I need to restart it so that it will correctly show them.

Actually, as you can see, I filter on "label/|gpt/", to only work on /dev/label and /dev/gpt devices, to have nicely named devices in my reports.

After some tests, I found that gstat automatically correctly detects the new /dev/da* devices, but does not detect /dev/gpt/* and /dev/label/* devices.

Another test, let's remove all iSCSI disks :
# iscsictl -Ra
As expected, gstat automatically removes them from its output.
Let's add them again :
# iscsictl -Aa
gstat now automatically correctly shows /dev/gpt/* and /dev/label/* in its output. Strange behavior !

Thank you very much for your support !

Ben