Date: Thu, 24 Mar 2016 10:10:41 +0000 (UTC) From: Alexander Motin <mav@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r297232 - head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs Message-ID: <201603241010.u2OAAfer046296@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: mav Date: Thu Mar 24 10:10:41 2016 New Revision: 297232 URL: https://svnweb.freebsd.org/changeset/base/297232 Log: Unify ignoring EEXIST from zvol_create_minor(). This fixes creation of zvol devices for snapshots during zfs receive, that previously failed with "ZFS WARNING: Unable to create ZVOL" message. This solution is not perfect, but IMHO better then it was before. MFC after: 2 weeks Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zvol.c Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zvol.c ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zvol.c Thu Mar 24 09:56:53 2016 (r297231) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zvol.c Thu Mar 24 10:10:41 2016 (r297232) @@ -2854,7 +2854,8 @@ zvol_create_snapshots(objset_t *os, cons break; } - if ((error = zvol_create_minor(sname)) != 0) { + error = zvol_create_minor(sname); + if (error != 0 && error != EEXIST) { printf("ZFS WARNING: Unable to create ZVOL %s (error=%d).\n", sname, error); break;
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201603241010.u2OAAfer046296>