Heinz Nikolaus Gies writes:

> zpool upgrade -v shows the same version on both systems.
>
> I would suspect that Joyent has modified the zpool utility, but it seems like 
> a sensible change.
>

This is indeed a local modification in SmartOS's libzfs.

/// START DIFF ///
diff -ur omniti-labs/illumos-omnios/usr/src/lib/libzfs/common/libzfs_pool.c 
joyent/illumos-joyent/usr/src/lib/libzfs/common/libzfs_pool.c
--- omniti-labs/illumos-omnios/usr/src/lib/libzfs/common/libzfs_pool.c  
2015-07-03 10:33:48.000000000 -0400
+++ joyent/illumos-joyent/usr/src/lib/libzfs/common/libzfs_pool.c       
2015-03-03 12:27:24.000000000 -0500
@@ -270,6 +270,12 @@
        case PROP_TYPE_NUMBER:
                intval = zpool_get_prop_int(zhp, prop, &src);

+               if (literal && prop != ZPOOL_PROP_HEALTH) {
+                       (void) snprintf(buf, len, "%llu",
+                           (u_longlong_t)intval);
+                       break;
+               }
+
                switch (prop) {
                case ZPOOL_PROP_SIZE:
                case ZPOOL_PROP_ALLOCATED:
/// END DIFF ///

This short-circuits all properties except for ZPOOL_PROP_HEALTH when the
literal flag is true (e.g. when passing -p to zpool).

-Z

>
>
>> On May 30, 2015, at 19:20, Krzysztof Grzempa <[email protected]> wrote:
>> 
>> Did you compare ZFS versions on both OS'es ? This might changed over some 
>> new version..
>> 
>> 2015-05-30 17:58 GMT+02:00 Heinz Nikolaus Gies <[email protected] 
>> <mailto:[email protected]>>:
>> I was looking at the output of zpool list today, comparing it with what I’d 
>> get on SmartOS and noticed that when using the -p flag for parable output 
>> the deduplication factor is still presented as a string (or floatish type) 
>> instead of a integer vlaue. It seems to me a bit wrong for parable output.
>> 
>> If there is a reason behind that decision it’s fine and I’ll gladly work 
>> around it, but it feels like an oversight.
>> 
>> 
>> Cheers,
>> Heinz
>> 
>> Here a quick glance:
>> 
>> OmniOS:
>> /usr/sbin/zpool list -pH -oname,size,alloc,free,dedup,health
>> data    7971459301376   6405101887488   1566357413888   1.00x   ONLINE
>> rpool   249108103168    121560741376    127547361792    1.00x   ONLINE
>> 
>> SmartOS:
>> list -pH -oname,size,alloc,free,dedup,health
>> zones   319975063552    51935040512     268040023040    100     ONLINE
>> ---
>> Cheers,
>> Heinz Nikolaus Gies
>> [email protected] <mailto:[email protected]>
>> 
>> 
>> 
>> 
>> _______________________________________________
>> OmniOS-discuss mailing list
>> [email protected] <mailto:[email protected]>
>> http://lists.omniti.com/mailman/listinfo/omnios-discuss 
>> <http://lists.omniti.com/mailman/listinfo/omnios-discuss>
>> 
>> 
>
> _______________________________________________
> OmniOS-discuss mailing list
> [email protected]
> http://lists.omniti.com/mailman/listinfo/omnios-discuss

_______________________________________________
OmniOS-discuss mailing list
[email protected]
http://lists.omniti.com/mailman/listinfo/omnios-discuss

Reply via email to