Bug 104676

Summary: YaST must write config status for *all* hardware devices
Product: [openSUSE] SUSE LINUX 10.0 Reporter: Steffen Winterfeldt <snwint>
Component: YaST2Assignee: Jiri Srain <jsrain>
Status: RESOLVED FIXED QA Contact: Klaus Kämpf <kkaempf>
Severity: Blocker    
Priority: P5 - None CC: aj, coolo, kkaempf, lslezak
Version: unspecified   
Target Milestone: ---   
Hardware: Other   
OS: All   
Whiteboard:
Found By: Other Services Priority:
Business Priority: Blocker: ---
Marketing QA Status: --- IT Deployment: ---

Description Steffen Winterfeldt 2005-08-15 13:10:18 UTC
yast should save the hardware config status of every hardware it 
configures. 
 
The reason is that the config files will be saved with the 
UDI as key (even when yast uses the old UniqueID) and so build 
a relation between old keys and new UDIs. 
 
This is necessary for desktop apps to know that a device has been configured 
(they use UDIs). 
 
For an update, it is possible to do this e.g., 
via 'hwinfo --pci --block --mouse --save-config=all'
Comment 1 Stephan Kulow 2005-08-15 13:17:28 UTC
the update is a blocker - otherwise the suseplugger will tell you _a lot_ 
about your computer you never wanted to know :) 
Comment 2 Ladislav Slezák 2005-08-15 15:49:37 UTC
Jiri, the command above should be probably called during update.

TV and sound cards write hardware config status of configured/unconfigured cards
using SCR::Write(.probe.status.configured, unique, `yes).

Klaus, I noticed that you made a change in probe agent to support UDI. Does the
above SCR call write also UDI? Or do I need to change the yast hardware modules?
Comment 3 Steffen Winterfeldt 2005-08-15 15:55:24 UTC
Currently no changes are necessary. libhd maps unique -> udi. 
Comment 4 Jiri Srain 2005-08-16 07:02:37 UTC
If I understand comment #3 correctly, the command in initial report is the 
only needed comment. Done in SVN, will submit to STABLE once Beta2 is out 
(will be fixed in Beta3). 
Comment 5 Steffen Winterfeldt 2005-08-31 11:57:07 UTC
(note: new installation) 
 
Saving the config status no longer works in beta-4. KDE will ask confirmation 
for all kinds of hardware. 
 
It is really *really* important that yast stores a config files for every 
hardware it configures. There's no other way the HAL-based tools know 
that it is not new hardware and the user will get popups all the time. 
Comment 6 Jiri Srain 2005-09-01 07:12:05 UTC
And what am I supposed to call durin fresh installation to store the settings? 
The command in intial comment is supposed to be only for update if I 
understand correctly. 
Comment 7 Jiri Srain 2005-09-01 07:51:04 UTC
This sounds to me like a problem of each indiviaual hardware module (during 
fresh installation). I suggest (unless there is "one command solving all") you 
should file bugreports to particular module maintainers for the problematic 
modules/hardware. 
Comment 8 Steffen Winterfeldt 2005-09-01 09:16:24 UTC
I'm talking my mouth off for years now and have given up all hope that 
the mouse module, for example, will ever save a config file. 
 
There seem to be two problems: 
 a) not all modules store a config (e.g. mouse) 
 b) for those that do, it doesn't work properly (for some unknown reason - 
   might be the hardware agent) 
 
A very evil band-aid would be to run the above command, added 
with '--keyboard --isdn' for good measure, and then do 
 
[ -d /var/lib/hardware/udi/org/freedesktop/Hal/devices ] && \ 
perl -pi -e "s/hwinfo.configured = 'new'/hwinfo.configured = 'no'/" \ 
/var/lib/hardware/udi/org/freedesktop/Hal/devices/* 
 
But b) must be researched nevertheless. 
Comment 9 Steffen Winterfeldt 2005-09-01 10:15:18 UTC
Ok, the reason for b) is that hald is not running. I've opened a separate 
bug for this: bug 114667. 
Comment 11 Andreas Jaeger 2005-09-01 11:38:23 UTC
So, why did this work in beta3 and not anymore in beta4?
Comment 12 Steffen Winterfeldt 2005-09-01 11:56:12 UTC
A good question. There seems to be even another problem (bug 114682). 
Comment 15 Andreas Jaeger 2005-09-01 13:25:56 UTC
Since this worked in beta3 and not in beta4, this is not a new feature.
Comment 16 Klaus Kämpf 2005-09-01 13:45:57 UTC
Then its not needed for each and every device ;-) 
Comment 17 Stephan Kulow 2005-09-01 15:13:20 UTC
it never actually worked. I just disabled the check because I was asked to do 
so to make the beta halfway usable.  
Comment 18 Steffen Winterfeldt 2005-09-02 09:43:48 UTC
ad 14: Jiri, run it at the end of the installation. It'll catch all the 
devices yast didn't care about. 
Comment 19 Andreas Jaeger 2005-09-03 15:24:36 UTC
Jiri, could you do this, please?
Comment 20 Jiri Srain 2005-09-05 10:54:30 UTC
Done, yast2-installation and skelcd-control-SUSELinux-Prof have just been 
submitted to STABLE/NOARCH.