From nobody Mon Nov 18 07:17:52 2024 X-Original-To: freebsd-fs@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4XsJqw3jh4z5dxnB for ; Mon, 18 Nov 2024 07:18:04 +0000 (UTC) (envelope-from jszhao@yeah.net) Received: from mail-m16.yeah.net (mail-m16.yeah.net [1.95.21.16]) by mx1.freebsd.org (Postfix) with ESMTP id 4XsJqq6dnYz522h for ; Mon, 18 Nov 2024 07:17:58 +0000 (UTC) (envelope-from jszhao@yeah.net) Authentication-Results: mx1.freebsd.org; dkim=pass header.d=yeah.net header.s=s110527 header.b=bz9FkhVn; spf=pass (mx1.freebsd.org: domain of jszhao@yeah.net designates 1.95.21.16 as permitted sender) smtp.mailfrom=jszhao@yeah.net; dmarc=pass (policy=none) header.from=yeah.net DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yeah.net; s=s110527; h=Message-ID:Date:MIME-Version:Subject:From: Content-Type; bh=lcexB1SQrypTncU/59AN5FyVgdWMDkYExNHdCIlPVnY=; b=bz9FkhVnUc61pTagKvQL3sqYP3xoQ62EzIa8xihUBvcMuZhW5zHbvfwj3QNijN SVF70M4K4XYWie5/K7PJQuhG9+q7yceX3XhzKuvJ4YyYPwKuIzzR58HAdaOjwnYE C2ee+1vqLg4tepBodzzkBcd1/pQBMWcp9F/CZfbnsuvW0= Received: from [10.162.4.204] (unknown []) by gzsmtp1 (Coremail) with SMTP id Mc8vCgD3H1Ug6jpneZnIAg--.64S2; Mon, 18 Nov 2024 15:17:53 +0800 (CST) Message-ID: <90dada2f-5978-4aaa-bc9d-e949a77f2177@yeah.net> Date: Mon, 18 Nov 2024 15:17:52 +0800 List-Id: Filesystems List-Archive: https://lists.freebsd.org/archives/freebsd-fs List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-fs@FreeBSD.org MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: `zpool list` return No such file or directory To: freebsd-fs@freebsd.org References: <4a0983b2-04f2-4489-a37c-6d4c71603606@yeah.net> Content-Language: en-US From: Jinsong Zhao In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit X-CM-TRANSID:Mc8vCgD3H1Ug6jpneZnIAg--.64S2 X-Coremail-Antispam: 1Uf129KBjvJXoW7AF1DWryDZw4UGr4xZw48Crg_yoW8uFyDpr W09Fy7KF4kJFy7Aws7tF17WFyjkr40yFs8JryUWryqy345ZFZagF12krWFkayUArs3Kr1j vrW8t3ZxZFyUXrJanT9S1TB71UUUUU7qnTZGkaVYY2UrUUUUjbIjqfuFe4nvWSU5nxnvy2 9KBjDUYxBIdaVFxhVjvjDU0xZFpf9x07UuKZAUUUUU= X-Originating-IP: [220.249.99.167] X-CM-SenderInfo: xmv2xt3r61vtnkoqv3/1tbiAgubz2c65ZsPmAAAsp X-Spamd-Result: default: False [-2.92 / 15.00]; NEURAL_HAM_LONG(-1.00)[-1.000]; NEURAL_HAM_MEDIUM(-0.99)[-0.993]; DMARC_POLICY_ALLOW(-0.50)[yeah.net,none]; R_SPF_ALLOW(-0.20)[+ip4:1.95.21.0/27]; R_DKIM_ALLOW(-0.20)[yeah.net:s=s110527]; RCVD_NO_TLS_LAST(0.10)[]; MIME_GOOD(-0.10)[text/plain]; NEURAL_HAM_SHORT(-0.04)[-0.041]; XM_UA_NO_VERSION(0.01)[]; MIME_TRACE(0.00)[0:+]; TO_MATCH_ENVRCPT_ALL(0.00)[]; FREEMAIL_FROM(0.00)[yeah.net]; FREEMAIL_ENVFROM(0.00)[yeah.net]; RCVD_COUNT_ONE(0.00)[1]; RCVD_IN_DNSWL_NONE(0.00)[1.95.21.16:from]; ARC_NA(0.00)[]; FROM_HAS_DN(0.00)[]; TO_DN_NONE(0.00)[]; DWL_DNSWL_NONE(0.00)[yeah.net:dkim]; HAS_XOIP(0.00)[]; RCPT_COUNT_ONE(0.00)[1]; MLMMJ_DEST(0.00)[freebsd-fs@freebsd.org]; FROM_EQ_ENVFROM(0.00)[]; MID_RHS_MATCH_FROM(0.00)[]; DKIM_TRACE(0.00)[yeah.net:+] X-Rspamd-Queue-Id: 4XsJqq6dnYz522h X-Spamd-Bar: -- On 2024/11/18 0:47, Alan Somers wrote: > On Sun, Nov 17, 2024 at 6:33 AM Jinsong Zhao wrote: >> >> Hi there, >> >> I have successfully installed FreeBSD 14.1 root on ZFS using GPT with >> VirtualBox. Now I tried to migrate the whole system to a new disk: >> >> >> zfs snapshot E580/ROOT/fb14@today >> >> zpool create test /dev/ada1p2 >> >> zfs send -R E580/ROOT/fb14@today | zfs receive test/fb14 >> >> All done successfully. >> >> After that, I tried to list all pools using >> >> zpool list >> >> It came back: >> >> No such file or directory > > This should be impossible, unless there are some steps missing. Is > this on the system with E580 or ada1p2? Did you reboot after the "zfs > receive" but before the "zpool list"? If so, you need to do a "zpool > import". If you want that to happen automatically, you need to add > "zfs_enable=YES" to /etc/rc.conf . System with E580 is on ada0p2, and the new pool test is on ada1 (or ada1p2, the same phenomena). No reboot after "zfs receive". After several rounds of testing, I think the problem may be that I didn't specify the mount point in the new pool. Also, "zfs receive" will automatically mount the received boot environment after it finishes when "-u" is not specified. So, there are two ways to fix this, either by specifying "-o altroot=/mnt" when "zpool create" or "-u" when "zfs receive". > >> >> I tried other zfs related commands, all give the same return. >> >> Now, I reboot the whole system, I can not even enter the system. > > If you are trying to create a second zfs-root system, based on copying > the file system from an already-working system, you left out a few > steps: > > * You only send/received a single boot environment, but there's more > to the pool than that. You should do something more like "zfs send -R > E580@today | zfs receive -F test" > * You need to set the bootable fs with "zfs set bootfs=test/ROOT/fb14 test" > * You didn't install the bootloader onto ada1p1. The details of how > to do that vary based on whether you are booting with EFI or BIOS. > >> >> What's the problem? I cannot find any hints with zpool/zfs man page. >> >> >> Best, >> >> Jinsong >> >> >>