From owner-freebsd-fs@freebsd.org Sat May 25 00:38:11 2019 Return-Path: Delivered-To: freebsd-fs@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 8A63D15B8F0A for ; Sat, 25 May 2019 00:38:11 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from mailman.ysv.freebsd.org (mailman.ysv.freebsd.org [IPv6:2001:1900:2254:206a::50:5]) by mx1.freebsd.org (Postfix) with ESMTP id E65698668D for ; Sat, 25 May 2019 00:38:10 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: by mailman.ysv.freebsd.org (Postfix) id 9C18115B8F07; Sat, 25 May 2019 00:38:10 +0000 (UTC) Delivered-To: fs@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 77EDA15B8F06 for ; Sat, 25 May 2019 00:38:10 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from mxrelay.ysv.freebsd.org (mxrelay.ysv.freebsd.org [IPv6:2001:1900:2254:206a::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) server-signature RSA-PSS (4096 bits) client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.ysv.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 15ACA86683 for ; Sat, 25 May 2019 00:38:10 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org (kenobi.freebsd.org [IPv6:2001:1900:2254:206a::16:76]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.ysv.freebsd.org (Postfix) with ESMTPS id 53F571CF54 for ; Sat, 25 May 2019 00:38:09 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org ([127.0.1.118]) by kenobi.freebsd.org (8.15.2/8.15.2) with ESMTP id x4P0c9G8037342 for ; Sat, 25 May 2019 00:38:09 GMT (envelope-from bugzilla-noreply@freebsd.org) Received: (from www@localhost) by kenobi.freebsd.org (8.15.2/8.15.2/Submit) id x4P0c9io037341 for fs@FreeBSD.org; Sat, 25 May 2019 00:38:09 GMT (envelope-from bugzilla-noreply@freebsd.org) X-Authentication-Warning: kenobi.freebsd.org: www set sender to bugzilla-noreply@freebsd.org using -f From: bugzilla-noreply@freebsd.org To: fs@FreeBSD.org Subject: [Bug 238112] Unable to create ZVOL Date: Sat, 25 May 2019 00:38:09 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: Base System X-Bugzilla-Component: kern X-Bugzilla-Version: 11.2-STABLE X-Bugzilla-Keywords: X-Bugzilla-Severity: Affects Some People X-Bugzilla-Who: eugen@freebsd.org X-Bugzilla-Status: New X-Bugzilla-Resolution: X-Bugzilla-Priority: --- X-Bugzilla-Assigned-To: bugs@FreeBSD.org X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: bug_id short_desc product version rep_platform op_sys bug_status bug_severity priority component assigned_to reporter cc Message-ID: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: https://bugs.freebsd.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-BeenThere: freebsd-fs@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Filesystems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 25 May 2019 00:38:11 -0000 https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D238112 Bug ID: 238112 Summary: Unable to create ZVOL Product: Base System Version: 11.2-STABLE Hardware: Any OS: Any Status: New Severity: Affects Some People Priority: --- Component: kern Assignee: bugs@FreeBSD.org Reporter: eugen@freebsd.org CC: allanjude@FreeBSD.org, fs@FreeBSD.org, markj@FreeBSD.org, mav@FreeBSD.org A colleague of mine is testing his set of virtual machines under FreeBSD 11.2-STABLE using bhyve (sysutils/vm-bhyve specifically) over GELI-encrypted non-boot ZFS pool with multiple ZVOLs and faced a problem. After GELI attached the pool, kernel part of ZFS tastes its internals and writes to dmesg: ZFS WARNING: Unable to create ZVOL sata/vm/ws2019tmplENhalts/C@20190524-225700-before-1st-reboot (error=3D63). The dataset has recommended volmode=3Ddev. In sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zvol.c the function zvol_create_minor() prepends mentioned long name of dataset with prefix "zv= ol/" and calls make_dev_s() from sys/kern/kern_conf.c that is a wrapper for make_dev_sv() failing with ENAMETOOLONG (63). make_dev_sv() uses prep_devname() that returns this error if total length is more than sizeof(dev->si_name) - 1 that equals to SPECNAMELEN defined to 63= . So ZVOL name length is effectively limited to 58 octets due to "zvol/" prefix. Warning message quoted above is too cryptic for user and this limit is obsc= ure and seems to be FreeBSD-specific. Please change the code to test for ENAMETOOLONG and issue a warning describing the problem more clearly. Also, consider replacing kernel printf() with more useful logging like log(= ) so the warning would hit syslog and get to /var/log/console.log (if enabled) a= nd not dmesg buffer only. --=20 You are receiving this mail because: You are on the CC list for the bug.=