On Wed, Sep 06, 2006 at 08:18:05AM -0400, Scott Dickson - Systems Engineer 
wrote:
> I am not certain excatly how the driver installation scripts for the
> add-on card make their devices and links.  But, the actual devices
> appear in /devices and symlinks (presumably created by the installer)
> are placed in /dev in the global zone.  I don't think that devfsadm does
> it; I believe the installer for the driver may put them there itself.
>

well, that's the problem then.
scanning through /dev looking for ramdom links that users have created
is not very practical.

> If I actually create the device node in $zoneroot/dev then I can grant
> the device to the zone.  But this seems a really convoluted way around this.
>

that is one way to work around the problem.

> Is this the only way to make this work?  Seems like there are probably
> other peripheral devices that don't build their device links via
> devfsadm that would be safe and/or useful in a non-global zone.
>

well, afaik there are only two proper ways to generate /dev links

1 deliver a devfsadmd plugin into /usr/lib/devfsadm/linkmod that will
  generate the symlinks for a driver.

2 update /etc/devlink.tab to generate the links for the device.

as a disclaimer, i've never tried the second approach so i'm not sure
that if you do this the devices will be added to zones.  perhaps someone
else on the zones team can elaborate on this.

ed

> Thanks!
> --SCott
>
> Edward Pilatowicz wrote:
> >On Mon, Aug 28, 2006 at 10:01:49AM -0400, Scott Dickson - Systems Engineer
> >wrote:
> >
> >>I am working with a customer to try to access tty devices from within a
> >>zone.  They are using a custom interface card for their tty devices, but
> >>it appears to create pretty standard device nodes and links from
> >>/dev/tty and /dev/cua to the devices.
> >>
> >>As a first test, just to verify the ability to add a tty to a zone, I
> >>created a second symlink, /dev/cua/b, that pointed to the same location
> >>as /dev/cua/a.  I then added this device to the zone using add device,
> >>set match=/dev/cua/b and restarted the zone.  I did not see the new tty
> >>in the zone.
> >>
> >
> >that is correct.  hand created symlinks can not be added to a zone via
> >zonecfg(1M).  zonecfg(1M) will only add /dev devices to a zone that have
> >been generated by the system.
> >
> >assuming that /dev/cua/a existed on the system before you started
> >creating links in /dev then adding that to the zone should work.
> >
> >
> >>The customer wants to take this a step further, since they use a large
> >>number of these tty ports in their applications.  They want to allocate
> >>/dev/cua/ devices to different zones.
> >>
> >>Why is this failing?  I am able to access /dev/ttya just fine in a zone.
> >>
> >>
> >
> >how are the /dev entries for their devices being created?
> >
> >ed
> >
_______________________________________________
zones-discuss mailing list
zones-discuss@opensolaris.org

Reply via email to