linux-btrfs.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* btrfsctl returns bad exit status
       [not found] <4C47513D.1070902@noir.com>
@ 2010-07-23 20:04 ` K. Richard Pixley
  2010-07-23 20:06   ` C Anthony Risinger
  0 siblings, 1 reply; 3+ messages in thread
From: K. Richard Pixley @ 2010-07-23 20:04 UTC (permalink / raw)
  To: linux-btrfs@vger.kernel.org

Using btrfsctl from ubuntu maverick, (built and running on 
ubuntu-10.04), I get:

rich@eisenhower> btrfsctl -s snap1 /home || echo failed
operation complete
Btrfs Btrfs v0.19
failed
rich@eisenhower> ls -las snap1
total 4
4 drwxr-xr-x 1 root    root    32 2010-07-20 18:25 .
0 drwxr-xr-x 1 rich    rich  1324 2010-07-21 12:47 ..
0 drwxr-xr-x 1 checker build   22 2010-07-20 18:21 checker
0 drwxr-xr-x 1 rich    rich  1322 2010-07-21 12:44 rich
0 drwxr-xr-x 1 root    root    36 2010-07-21 10:47 za-cb

This would seem to indicate a non-zero exit status despite the fact that 
the snapshotting operation appears to have succeeded.  This makes it 
impossible to programmatically check whether a snapshot was created 
successfully or not as I will need to explicitly discard the exit status 
from btrfsctl.

I get the same results when built from git, except that it identifies 
itself as "v0.19-16-g075587c".

I would expect that btrfsctl would return zero exit status when it was 
capable of doing what it was asked and non-zero exit status only when it 
could not.

--rich

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: btrfsctl returns bad exit status
  2010-07-23 20:04 ` btrfsctl returns bad exit status K. Richard Pixley
@ 2010-07-23 20:06   ` C Anthony Risinger
  2010-07-23 20:52     ` K. Richard Pixley
  0 siblings, 1 reply; 3+ messages in thread
From: C Anthony Risinger @ 2010-07-23 20:06 UTC (permalink / raw)
  To: K. Richard Pixley; +Cc: linux-btrfs@vger.kernel.org

Try using "btrfs" tool; btrfsctl is/will be deprecated I think...  and
it's better anyway.

C Anthony [mobile]

On Jul 23, 2010, at 3:04 PM, "K. Richard Pixley" <rich@noir.com> wrote:

> Using btrfsctl from ubuntu maverick, (built and running on
> ubuntu-10.04), I get:
>
> rich@eisenhower> btrfsctl -s snap1 /home || echo failed
> operation complete
> Btrfs Btrfs v0.19
> failed
> rich@eisenhower> ls -las snap1
> total 4
> 4 drwxr-xr-x 1 root    root    32 2010-07-20 18:25 .
> 0 drwxr-xr-x 1 rich    rich  1324 2010-07-21 12:47 ..
> 0 drwxr-xr-x 1 checker build   22 2010-07-20 18:21 checker
> 0 drwxr-xr-x 1 rich    rich  1322 2010-07-21 12:44 rich
> 0 drwxr-xr-x 1 root    root    36 2010-07-21 10:47 za-cb
>
> This would seem to indicate a non-zero exit status despite the fact
> that the snapshotting operation appears to have succeeded.  This
> makes it impossible to programmatically check whether a snapshot was
> created successfully or not as I will need to explicitly discard the
> exit status from btrfsctl.
>
> I get the same results when built from git, except that it
> identifies itself as "v0.19-16-g075587c".
>
> I would expect that btrfsctl would return zero exit status when it
> was capable of doing what it was asked and non-zero exit status only
> when it could not.
>
> --rich
> --
> To unsubscribe from this list: send the line "unsubscribe linux-
> btrfs" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: btrfsctl returns bad exit status
  2010-07-23 20:06   ` C Anthony Risinger
@ 2010-07-23 20:52     ` K. Richard Pixley
  0 siblings, 0 replies; 3+ messages in thread
From: K. Richard Pixley @ 2010-07-23 20:52 UTC (permalink / raw)
  To: C Anthony Risinger; +Cc: linux-btrfs@vger.kernel.org

  Ah!  Thanks.

Wiki page needs to be updated then.  It shows btrfsctl and doesn't 
mention btrfs.

This one: https://btrfs.wiki.kernel.org/index.php/Getting_started

--rich

On 20100723 13:06, C Anthony Risinger wrote:
> Try using "btrfs" tool; btrfsctl is/will be deprecated I think...  and
> it's better anyway.
>
> C Anthony [mobile]
>
> On Jul 23, 2010, at 3:04 PM, "K. Richard Pixley"<rich@noir.com>  wrote:
>
>> Using btrfsctl from ubuntu maverick, (built and running on
>> ubuntu-10.04), I get:
>>
>> rich@eisenhower>  btrfsctl -s snap1 /home || echo failed
>> operation complete
>> Btrfs Btrfs v0.19
>> failed
>> rich@eisenhower>  ls -las snap1
>> total 4
>> 4 drwxr-xr-x 1 root    root    32 2010-07-20 18:25 .
>> 0 drwxr-xr-x 1 rich    rich  1324 2010-07-21 12:47 ..
>> 0 drwxr-xr-x 1 checker build   22 2010-07-20 18:21 checker
>> 0 drwxr-xr-x 1 rich    rich  1322 2010-07-21 12:44 rich
>> 0 drwxr-xr-x 1 root    root    36 2010-07-21 10:47 za-cb
>>
>> This would seem to indicate a non-zero exit status despite the fact
>> that the snapshotting operation appears to have succeeded.  This
>> makes it impossible to programmatically check whether a snapshot was
>> created successfully or not as I will need to explicitly discard the
>> exit status from btrfsctl.
>>
>> I get the same results when built from git, except that it
>> identifies itself as "v0.19-16-g075587c".
>>
>> I would expect that btrfsctl would return zero exit status when it
>> was capable of doing what it was asked and non-zero exit status only
>> when it could not.
>>
>> --rich
>> --
>> To unsubscribe from this list: send the line "unsubscribe linux-
>> btrfs" in
>> the body of a message to majordomo@vger.kernel.org
>> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> --
> To unsubscribe from this list: send the line "unsubscribe linux-btrfs" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2010-07-23 20:52 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <4C47513D.1070902@noir.com>
2010-07-23 20:04 ` btrfsctl returns bad exit status K. Richard Pixley
2010-07-23 20:06   ` C Anthony Risinger
2010-07-23 20:52     ` K. Richard Pixley

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).