DaemonForums  

Go Back   DaemonForums > NetBSD > NetBSD General

NetBSD General Other questions regarding NetBSD which do not fit in any of the categories below.

Reply
 
Thread Tools Display Modes
  #1   (View Single Post)  
Old 5th November 2019
notooth notooth is offline
Shell Scout
 
Join Date: Jul 2015
Posts: 97
Default NetBSD does not recognize FreeBSD's zfs

Hello,

I have a zpool created on FreeBSD 12.0, but it is not recognized on NetBSD 8.1. Can anyone help?

Code:
# zpool status
no pools available
Reply With Quote
  #2   (View Single Post)  
Old 13th January 2020
akua akua is offline
New User
 
Join Date: Jan 2020
Posts: 1
Default

Pool compatibility depends on feature flags. If you create a pool on a system with newer features than the one you wish to share it with, you will see what you note.

Linux > FreeBSD > NetBSD in terms of feature flags 1/1/2020

Code:
$ cat /all/script/zpool-compatible 
#!/bin/sh
newargs=''
cmd=''

if [ "$1" = 'create' ]; then
        cmd='create'
        newargs=''
        ALLOFF=''
        shift   

        BOOT=0
        [ "$1" = '-b' ] && BOOT=1 && shift

        LINUXONLY='userobj_accounting'
        FREEBONLY='spacemap_v2'
        BOOTKILL='edonr skein large_dnode sha512'

        case $(uname -s) in
          Linux)
                for i in $LINUXONLY; do
                        newargs="${newargs} -o feature@${i}=disabled"
                done
          ;;

          FreeBSD)
                ALLOFF='-d'
                for i in $FREEBONLY; do
                        newargs="${newargs}"
                        # "-o feature@${i}=disabled"    # This is not supported on FreeBSD 12 - turn them all off and enable them independently
                done
          ;;
        esac

        if [ $BOOT -eq 1 ]; then
                for i in $BOOTKILL; do
                        newargs="${newargs} -o feature@${i}=disabled"
                done
        fi
fi

[ -n "$newargs" ] && echo "Akua override with: $newargs"

[ -z "$1" ] && echo 'Akua zpool - use -b to disable possibly unbootable features as well'

exec zpool $cmd $ALLOFF $newargs "$@"
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
"the OpenBSD kernel will only recognize 3.1 gig of RAM"? hanzer OpenBSD General 8 20th January 2015 06:48 PM
SuperTuxKart for NetBSD and FreeBSD xeno74 General software and network 33 5th December 2013 07:05 PM
Getting Xfce4 to recognize sound card harishankar NetBSD General 5 13th November 2011 10:30 AM
FreeBSD/NetBSD compatibility? nilsgecko Off-Topic 5 22nd April 2011 07:30 PM
k3b and k9copy do not recognize my DVD-RW device corneliu FreeBSD General 8 25th May 2008 08:06 AM


All times are GMT. The time now is 09:55 AM.


Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Content copyright © 2007-2010, the authors
Daemon image copyright ©1988, Marshall Kirk McKusick