OpenSolaris

Discussions Communities Projects Download Source Browser

Home » OpenSolaris Forums » zfs » discuss

Thread: Assertion raised during zfs share?

Welcome, Guest Help
Login Login
Guest Settings Guest Settings
Reply to this Thread Reply to this Thread Search Forum Search Forum Back to Thread List Back to Thread List

Permlink Replies: 11 - Last Post: Mar 29, 2007 3:37 AM by: nickelj
Jim Connors
James.Connors@Sun.COM
Assertion raised during zfs share?
Posted: Aug 4, 2006 9:41 AM

  Click to reply to this thread Reply


Working to get ZFS to run on a minimal Solaris 10 U2 configuration. In
this scenario, ZFS is included the miniroot which is booted into RAM.
When trying to share one of the filesystems, an assertion is raised -
see below. If the version of source on OpenSolaris.org matches
Solaris 10 U2, then it looks like it's associated with a popen of
/usr/sbin/share. Can anyone shed any light on this?

Thanks,
-- Jim C


# zfs list
NAME USED AVAIL REFER MOUNTPOINT
SYS 83K 163M 30.5K /SYS
export 110K 72.8G 25.5K /export
export/home 24.5K 72.8G 24.5K /export/home
# zpool list
NAME SIZE USED AVAIL CAP HEALTH ALTROOT
SYS 195M 90K 195M 0% ONLINE -
export 74G 114K 74.0G 0% ONLINE -
# zfs set sharenfs=on export
# zfs share export
Assertion failed: pclose(fp) == 0, file ../common/libzfs_mount.c, line
399, function zfs_share
Abort - core dumped

_______________________________________________
zfs-discuss mailing list
zfs-discuss at opensolaris dot org
http://mail.opensolaris.org/mailman/listinfo/zfs-discuss



eschrock

Posts: 799
From: Menlo Park, CA

Registered: 3/9/05
Re: Assertion raised during zfs share?
Posted: Aug 4, 2006 9:48 AM   in response to: Jim Connors

  Click to reply to this thread Reply

This indicates that share(1M) didn't produce any output, but returned
a non-zero exit status. I'm not sure why this would happen - can you
run the following by hand?

# share /export
# echo $?

Incidentally, the explicit 'zfs share' isn't needed, as we automatically
share the filesystem when the options are set (which did succeed).

- Eric

On Fri, Aug 04, 2006 at 12:42:02PM -0400, Jim Connors wrote:
>
> Working to get ZFS to run on a minimal Solaris 10 U2 configuration. In
> this scenario, ZFS is included the miniroot which is booted into RAM.
> When trying to share one of the filesystems, an assertion is raised -
> see below. If the version of source on OpenSolaris.org matches
> Solaris 10 U2, then it looks like it's associated with a popen of
> /usr/sbin/share. Can anyone shed any light on this?
>
> Thanks,
> -- Jim C
>
>
> # zfs list
> NAME USED AVAIL REFER MOUNTPOINT
> SYS 83K 163M 30.5K /SYS
> export 110K 72.8G 25.5K /export
> export/home 24.5K 72.8G 24.5K /export/home
> # zpool list
> NAME SIZE USED AVAIL CAP HEALTH ALTROOT
> SYS 195M 90K 195M 0% ONLINE -
> export 74G 114K 74.0G 0% ONLINE -
> # zfs set sharenfs=on export
> # zfs share export
> Assertion failed: pclose(fp) == 0, file ../common/libzfs_mount.c, line
> 399, function zfs_share
> Abort - core dumped
>
> _______________________________________________
> zfs-discuss mailing list
> zfs-discuss at opensolaris dot org
> http://mail.opensolaris.org/mailman/listinfo/zfs-discuss

--
Eric Schrock, Solaris Kernel Development http://blogs.sun.com/eschrock
_______________________________________________
zfs-discuss mailing list
zfs-discuss at opensolaris dot org
http://mail.opensolaris.org/mailman/listinfo/zfs-discuss



eschrock

Posts: 799
From: Menlo Park, CA

Registered: 3/9/05
Re: Assertion raised during zfs share?
Posted: Aug 4, 2006 9:57 AM   in response to: eschrock

  Click to reply to this thread Reply

On Fri, Aug 04, 2006 at 09:48:37AM -0700, Eric Schrock wrote:
> This indicates that share(1M) didn't produce any output, but returned
> a non-zero exit status. I'm not sure why this would happen - can you
> run the following by hand?
>
> # share /export
> # echo $?
>
> Incidentally, the explicit 'zfs share' isn't needed, as we automatically
> share the filesystem when the options are set (which did succeed).

BTW, on my system running the latest bits this correctly shows:

# zfs share test
cannot share 'test': filesystem already shared

Which is what I would expect in your case as well.

- Eric

--
Eric Schrock, Solaris Kernel Development http://blogs.sun.com/eschrock
_______________________________________________
zfs-discuss mailing list
zfs-discuss at opensolaris dot org
http://mail.opensolaris.org/mailman/listinfo/zfs-discuss



Jim Connors
James.Connors@Sun.COM
Re: Assertion raised during zfs share?
Posted: Aug 4, 2006 10:31 AM   in response to: eschrock

  Click to reply to this thread Reply

Eric Schrock wrote:
> This indicates that share(1M) didn't produce any output, but returned
> a non-zero exit status. I'm not sure why this would happen - can you
> run the following by hand?
>
> # share /export
> # echo $?
>

bash-3.00# share
bash-3.00# share /export
bash-3.00# echo $?
0

Looks like the NFS server is not completely configured yet, and that it
requires this zfs share stuff to work first.

bash-3.00# svcs -a | grep nfs/server
disabled 6:24:31 svc:/network/nfs/server:default
bash-3.00# more /var/svc/log/network-nfs-server\:default.log
[ Aug 4 06:15:31 Executing start method ("/lib/svc/method/nfs-server
start") ]
Assertion failed: pclose(fp) == 0, file ../common/libzfs_mount.c, line
399, function zfs_share
Abort - core dumped
[ Aug 4 06:15:32 Method "start" exited with status 0 ]
[ Aug 4 06:15:32 Stopping because process dumped core. ]
[ Aug 4 06:15:32 Executing stop method ("/lib/svc/method/nfs-server
stop 30") ][ Aug 4 06:15:32 Method "stop" exited with status 0 ]
[ Aug 4 06:15:32 Executing start method ("/lib/svc/method/nfs-server
start") ]
Assertion failed: pclose(fp) == 0, file ../common/libzfs_mount.c, line
399, function zfs_share
Abort - core dumped

-- Jim C

> Incidentally, the explicit 'zfs share' isn't needed, as we automatically
> share the filesystem when the options are set (which did succeed).
>
> - Eric
>
> On Fri, Aug 04, 2006 at 12:42:02PM -0400, Jim Connors wrote:
>
>> Working to get ZFS to run on a minimal Solaris 10 U2 configuration. In
>> this scenario, ZFS is included the miniroot which is booted into RAM.
>> When trying to share one of the filesystems, an assertion is raised -
>> see below. If the version of source on OpenSolaris.org matches
>> Solaris 10 U2, then it looks like it's associated with a popen of
>> /usr/sbin/share. Can anyone shed any light on this?
>>
>> Thanks,
>> -- Jim C
>>
>>
>> # zfs list
>> NAME USED AVAIL REFER MOUNTPOINT
>> SYS 83K 163M 30.5K /SYS
>> export 110K 72.8G 25.5K /export
>> export/home 24.5K 72.8G 24.5K /export/home
>> # zpool list
>> NAME SIZE USED AVAIL CAP HEALTH ALTROOT
>> SYS 195M 90K 195M 0% ONLINE -
>> export 74G 114K 74.0G 0% ONLINE -
>> # zfs set sharenfs=on export
>> # zfs share export
>> Assertion failed: pclose(fp) == 0, file ../common/libzfs_mount.c, line
>> 399, function zfs_share
>> Abort - core dumped
>>
>> _______________________________________________
>> zfs-discuss mailing list
>> zfs-discuss at opensolaris dot org
>> http://mail.opensolaris.org/mailman/listinfo/zfs-discuss
>>
>
> --
> Eric Schrock, Solaris Kernel Development http://blogs.sun.com/eschrock
>

_______________________________________________
zfs-discuss mailing list
zfs-discuss at opensolaris dot org
http://mail.opensolaris.org/mailman/listinfo/zfs-discuss



relling

Posts: 1,858
From: US

Registered: 6/17/05
Re: Assertion raised during zfs share?
Posted: Aug 4, 2006 1:35 PM   in response to: Jim Connors

  Click to reply to this thread Reply

Jim Connors wrote:
>
> Working to get ZFS to run on a minimal Solaris 10 U2 configuration.

What does "minimal" mean? Most likely, you are missing something.
-- richard
_______________________________________________
zfs-discuss mailing list
zfs-discuss at opensolaris dot org
http://mail.opensolaris.org/mailman/listinfo/zfs-discuss



Jim Connors
James.Connors@Sun.COM
Re: Assertion raised during zfs share?
Posted: Aug 4, 2006 2:48 PM   in response to: relling

  Click to reply to this thread Reply

Richard Elling wrote:
> Jim Connors wrote:
>>
>> Working to get ZFS to run on a minimal Solaris 10 U2 configuration.
>
> What does "minimal" mean? Most likely, you are missing something.
> -- richard
Yeah. Looking at package and SMF dependencies plus a whole lot of and
trial and error, I've currently got Solaris down to 47 packages. The
nfs/server service for Solaris 10 U2 will first try to do a zfs share.
For the next step, I'll probably comment out that stuff and see I can
bring up the nfs server code and share a UFS filesystem using the
traditional methods. Once that's OK I'll move on to the ZFS portion and
investigate.

Thanks,
-- Jim C
_______________________________________________
zfs-discuss mailing list
zfs-discuss at opensolaris dot org
http://mail.opensolaris.org/mailman/listinfo/zfs-discuss



jwadams

Posts: 370
From: San Francisco, CA

Registered: 3/9/05
Re: Assertion raised during zfs share?
Posted: Aug 4, 2006 2:53 PM   in response to: Jim Connors

  Click to reply to this thread Reply

On Fri, Aug 04, 2006 at 05:48:59PM -0400, Jim Connors wrote:
> Richard Elling wrote:
> >Jim Connors wrote:
> >>
> >>Working to get ZFS to run on a minimal Solaris 10 U2 configuration.
> >
> >What does "minimal" mean? Most likely, you are missing something.
> > -- richard
> Yeah. Looking at package and SMF dependencies plus a whole lot of and
> trial and error, I've currently got Solaris down to 47 packages. The
> nfs/server service for Solaris 10 U2 will first try to do a zfs share.
> For the next step, I'll probably comment out that stuff and see I can
> bring up the nfs server code and share a UFS filesystem using the
> traditional methods. Once that's OK I'll move on to the ZFS portion and
> investigate.

Out of curiosity, why are you trying to do this?

Cheers,
- jonathan

--
Jonathan Adams, Solaris Kernel Development
_______________________________________________
zfs-discuss mailing list
zfs-discuss at opensolaris dot org
http://mail.opensolaris.org/mailman/listinfo/zfs-discuss



Jim Connors
James.Connors@Sun.COM
Re: Assertion raised during zfs share?
Posted: Aug 4, 2006 8:31 PM   in response to: jwadams

  Click to reply to this thread Reply


> Out of curiosity, why are you trying to do this?
>

A very valid question, I work in Sun's OEM Software organization, and
for the first time we are seeing real opportunities for Solaris as an
embedded OS for appliances. Countless Linux devices boot from flash in
a matter of seconds and just work. Why can't Solaris do the same
thing? We are being asked by our PC OEMs for ideas as to how Solaris
might fit in this market. This is admittedly an exercise; we need to
become more knowledgeable about embedding Solaris and I was looking for
an application that is currently unique to Solaris, and thought I'd
take a crack at creating a "poor man's thumper". So currently:

o I've got a modified Solaris miniroot with ZFS functionality which
takes up about 60 MB (The compressed image, which GRUB uses, is less
than 30MB). Solaris boots entirely into RAM. From poweron to full
functionality, it takes about 45 seconds to boot on a very modest 1GHz
Cyrix Mini ITX motherboard.

o As Solaris runs entirely in RAM, there is no Solaris footprint on the
attached storage. It is entirely dedicated to ZFS. With a little
kludgery, all state can be managed from ZFS in effect making Solaris
stateless. There should be no serious ramifications to pulling the plug
on this device. In fact that's pretty much how this thing is rebooted
right now.

o As a potential example, one might consider managing this device via a
web-based interface, perhaps not all that different than the way you
might manage say, a Linksys router.

Yeah I know this is silly, but it's fun. Time to get back to my real job
-- Jim C

> Cheers,
> - jonathan
>
>

_______________________________________________
zfs-discuss mailing list
zfs-discuss at opensolaris dot org
http://mail.opensolaris.org/mailman/listinfo/zfs-discuss



wonko

Posts: 221
From: Philadelphia, PA

Registered: 1/12/06
Re: Assertion raised during zfs share?
Posted: Aug 5, 2006 3:35 PM   in response to: Jim Connors

  Click to reply to this thread Reply

On Fri, Aug 04, 2006 at 11:31:38PM -0400, Jim Connors wrote:
>
> o I've got a modified Solaris miniroot with ZFS functionality which
> takes up about 60 MB (The compressed image, which GRUB uses, is less
> than 30MB). Solaris boots entirely into RAM. From poweron to full
> functionality, it takes about 45 seconds to boot on a very modest 1GHz
> Cyrix Mini ITX motherboard.

That's great, keep up the good work!!

> o As Solaris runs entirely in RAM, there is no Solaris footprint on the
> attached storage. It is entirely dedicated to ZFS. With a little
> kludgery, all state can be managed from ZFS in effect making Solaris
> stateless. There should be no serious ramifications to pulling the plug
> on this device. In fact that's pretty much how this thing is rebooted
> right now.

This is already one of the reasons I love Solaris so much, with UFS
logging I can pull the plug on my U1 firewall and never have to worry
about it getting screwed up, this just takes that a step further.

> Yeah I know this is silly, but it's fun. Time to get back to my real job

Not at all silly. Solaris is a fantastic OS, and this would just be yet
another great application for it's greatness to shine. ;)

*I* would definitely use it this way, no doubt about it.

-brian
_______________________________________________
zfs-discuss mailing list
zfs-discuss at opensolaris dot org
http://mail.opensolaris.org/mailman/listinfo/zfs-discuss



loomy

Posts: 567
From:

Registered: 3/17/07
Re: Assertion raised during zfs share?, Re: a 30mb ZFS OS install
Posted: Mar 27, 2007 9:01 AM   in response to: Jim Connors
To: Communities » zfs » discuss
Cc: Communities » appliances » discuss
  Click to reply to this thread Reply

> o I've got a modified Solaris miniroot with ZFS
> functionality which
> takes up about 60 MB (The compressed image, which
> GRUB uses, is less
> than 30MB). Solaris boots entirely into RAM. From
> poweron to full
> functionality, it takes about 45 seconds to boot on a
> very modest 1GHz
> Cyrix Mini ITX motherboard.
>
> o As Solaris runs entirely in RAM, there is no
> Solaris footprint on the
> attached storage. It is entirely dedicated to ZFS.
> With a little
> ludgery, all state can be managed from ZFS in effect
> making Solaris
> stateless. There should be no serious ramifications
> to pulling the plug
> on this device. In fact that's pretty much how this
> thing is rebooted
> right now.
>
> o As a potential example, one might consider managing
> this device via a
> web-based interface, perhaps not all that different
> than the way you
> might manage say, a Linksys router.
>
> Yeah I know this is silly, but it's fun. Time to get
> back to my real job
> -- Jim C

Silly is the opposite of such a project! I'm just wondering how so much time has passed without it becoming an explicit OpenSolaris project!

A RAM-driven headless ZFS file server to compete with FreeNAS, OpenFiler, Windows Storage Server 2003 and Windows Home Server? Where do we sign up for this?!?! :)

malachid

Posts: 71
From: Beaverton, OR (USA)

Registered: 1/31/07
Re: Re: Assertion raised during zfs share?, Re: a 30mb ZFS OS install
Posted: Mar 27, 2007 9:57 AM   in response to: loomy

  Click to reply to this thread Reply

If I had had that a few months ago, I might have designed a completely different system.

Great job!

Malachi

On 3/27/07, MC < rac at eastlink dot ca> wrote:
> o I've got a modified Solaris miniroot with ZFS
> functionality which
> takes up about 60 MB  (The compressed image, which
> GRUB uses, is less
> than 30MB). Solaris boots entirely into RAM.  From
> poweron to full
> functionality, it takes about 45 seconds to boot on a
> very modest 1GHz
> Cyrix Mini ITX motherboard.
>
> o As Solaris runs entirely in RAM, there is no
> Solaris footprint on the
> attached storage. It is entirely dedicated to ZFS.
>  With a little
> ludgery, all state can be managed from ZFS in effect
> making Solaris
> stateless.  There should be no serious ramifications
> to pulling the plug
> on this device.  In fact that's pretty much how this
> thing is rebooted
> right now.
>
> o As a potential example, one might consider managing
> this device via a
> web-based interface, perhaps not all that different
> than the way you
> might manage say, a Linksys router.
>
> Yeah I know this is silly, but it's fun.  Time to get
> back to my real job
> -- Jim C

Silly is the opposite of such a project!  I'm just wondering how so much time has passed without it becoming an explicit OpenSolaris project!

A RAM-driven headless ZFS file server to compete with FreeNAS, OpenFiler, Windows Storage Server 2003 and Windows Home Server?  Where do we sign up for this?!?! :)


This message posted from opensolaris.org
_______________________________________________
zfs-d iscuss mailing list
zfs-discuss at opensolaris dot org
http://mail.opensolaris.org/mailman/listinfo/zfs-discuss

_______________________________________________ zfs-discuss mailing list zfs-discuss at opensolaris dot org http://mail.opensolaris.org/mailman/listinfo/zfs-discuss


nickelj

Posts: 15
From: Gunzwil

Registered: 4/6/06
Re: Assertion raised during zfs share?
Posted: Mar 29, 2007 3:37 AM   in response to: Jim Connors
To: Communities » zfs » discuss
  Click to reply to this thread Reply

Hi Jim,

that's absolutely great, respect.
Where is it possible to get more infos about what you have done so far?
to rebuild that for a own try?

cheers
Jens




Terms of Use | Privacy | Trademarks | Copyright Policy | Site Guidelines
Your use of this web site or any of its content or software indicates your agreement to be bound by these Terms of Use.
Copyright © 1995-2005 Sun Microsystems, Inc.