Bug 8647 - devices not usable immediately after install
: devices not usable immediately after install
Status: FIXINPROGRESS
Product: pkg
actions
: unspecified
: ANY/Generic OpenSolaris
: P2 enhancement (vote)
: 2010.02
Assigned To: Danek Duvall
: pkg/actions watcher
: http://opensolaris.org/jive/message.j...
:
:
:
: 9456
  Show dependency treegraph
 
Reported: 2009-05-05 07:22 UTC by Brian Leonard
Modified: 2009-11-16 18:20 UTC (History)
6 users (show)

See Also:


Attachments


Note

You need to log in before you can comment on or make changes to this bug.


Description Brian Leonard 2009-05-05 07:22:48 UTC
After installing the CIFS server, the smbsrv driver needs to be removed and
re-added before the service will start. Alternatively, the machine needs to be
rebooted. Ideally, the smb/server service would start successfully after
installation. See the URL for more details.
Comment 1 Danek Duvall 2009-05-05 08:09:14 UTC
We update all the files associated with a driver, but we don't complete the
task and load the driver, which is necessary for the driver to start working. 
The reason we don't is that loading the driver means running code that you just
installed, and we're a bit paranoid about that, but there's pretty much nothing
else we can do.

You should be able to work around this by running "devfsadm -i smbsrv" (or
whatever the name of the driver is), though for some drivers, this might not be
enough.
Comment 2 Jim Dunham 2009-06-03 18:28:21 UTC
The need to reboot OpenSolaris is also an issue with the IPS package 'avs',
although not an issue for AVS in SXCE.

Manually performing the following before invoking 'dscfgadm' for this 1st time
is is a work-around.

rem_drv ncall
rem_drv nsctl
rem_drv nskern
add_drv ncall
add_drv nsctl
add_drv nskern
Comment 3 Danek Duvall 2009-06-03 19:17:01 UTC
As I said earlier, you should be able to do this without rem_drv and add_drv,
especially since you don't want to muck with the driver databases -- the
rem_drv calls will remove the entries from minor_perm, extra_privs, and
possibly devlink.tab, while your add_drv invocations won't add them back.

Please try using

    devfsadm -i nskern
    devfsadm -i ncall
    devfsadm -i nsctl
    devfsadm -i sdbc

(the last is delivered by the same package as the other three) instead; if it
doesn't do the job properly, I'd like to know before I make that automatic.
Comment 4 Jim Dunham 2009-06-04 19:22:16 UTC
For each of the following commands:

    devfsadm -i nskern
    devfsadm -i ncall
    devfsadm -i nsctl
    devfsadm -i sdbc

each fails with the following error message:

       devfsadm: driver failed to attach: ....

A couple of observations:

- If OpenSolaris is rebooted after installing the "avs" packages, everything
OK.

- If the rem_drv / add_drv commands are invoked, AVS works without a reboot. 

- Even if the rem_drv commands "... muck with the driver databases ..." after
the next, or any future reboots AVS works.

- If instead of using the IPS based "avs" packages, I use the SRV4 packages
from the corresponding Nevada build, this same type of driver loading defect
exists.

These leads me to the conclusion that the repackaging of AVS's SRV4 packages as
new IPS packages is not defective, but something in how (pseudo) device drivers
exists in devfs.

So far my preliminary investigation into this shows the "ls -lt" and "find /dev
-ls" can see the newly installed (pseudo) device drivers, but that open() of
one of the seen devices, fails.
Comment 5 Steve McKinty 2009-07-27 04:08:53 UTC
The AVS aspects of this are important for Solaris Cluster Geographic Edition,
since one of the key features of SCGE is that it can be added/removed/upgraded
without requiring a reboot with the attendant dent in availability figures.
Comment 6 jack.a.schwartz 2009-09-23 22:04:35 UTC
The (Install) Driver Update project needs this to be fixed.  Installers run
from a live CD or off the net, and so a reboot is not possible.  Driver actions
must be enhanced to complete the driver configuration job by loading the driver
binary and activating the device(s) the driver operates.

After having talked with people on both the driver and pkg teams, I filed
bugster bug:

6885060 Provide a way other than reboot to activate drivers installed with
add_drv -n

to provide the needful for the driver actions to be able to load driver
binaries safely as part of an install.
Comment 7 David Comay 2009-10-20 01:48:32 UTC
P1s are for bugs which need to be fixed in the current build so I'm lowering
this to a P2 which is still correct for bugs that need to be fixed in the next
release.
Comment 8 Danek Duvall 2009-11-09 05:55:49 UTC
Bug 6885060 was fixed in build 127, so we can start using the interfaces
delivered by that fix.
Comment 9 Danek Duvall 2009-11-16 18:20:01 UTC
*** Bug 12694 has been marked as a duplicate of this bug. ***