No video card reported from cronjob
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
OCS Inventory: Unified Unix Agent |
Fix Released
|
Low
|
Frank |
Bug Description
Running ocsinventory-agent 2.3.0-1 on CentOS 7.
When running ocsinventory-agent from cron, the video card is not reported.
Relevant info from lspci:-
0f:00.0 VGA compatible controller: NVIDIA Corporation GF100 [GeForce GTX 470] (rev a3)
The nouveau driver is being used.
Eventually three problems were found with the code in Ocsinventory:
1) The regular expression at line 80 does not allow for hex characters in the PCI slot number
2) If the PCI card reports more than one memory area, these are not summed - just the last is taken
3) if xrandr generates no output (which it won't on a cronjob), $common->addVideo() is never called.
I've attached a patch to address all three of these.
On a further note, I don't think the xrandr code to determine the resolution is really a good idea. While I was testing this, I was ssh'd in with a tunnelled X display. The Perl code picked up the resolution of my remote display and reported it against the video card!
Changed in ocsinventory-unix-agent: | |
importance: | Undecided → Low |
assignee: | nobody → Frank (frank-bourdeau) |
status: | New → Fix Committed |
Changed in ocsinventory-unix-agent: | |
status: | Fix Committed → Fix Released |