From owner-freebsd-questions@freebsd.org Tue May 30 16:49:51 2017 Return-Path: Delivered-To: freebsd-questions@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 289A6B87E06 for ; Tue, 30 May 2017 16:49:51 +0000 (UTC) (envelope-from eduardo.lemosdesa@gmail.com) Received: from mail-wm0-x22e.google.com (mail-wm0-x22e.google.com [IPv6:2a00:1450:400c:c09::22e]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id AA89A6F145 for ; Tue, 30 May 2017 16:49:50 +0000 (UTC) (envelope-from eduardo.lemosdesa@gmail.com) Received: by mail-wm0-x22e.google.com with SMTP id 7so96891959wmo.1 for ; Tue, 30 May 2017 09:49:50 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to; bh=W65uoKHM6Dn0m/zjauD7WClE8CyqsZ/hXN4IZqNovYo=; b=g9Z3e3HnwmudKIq0TMNzV2LBTV118NXV/svRoqer4qNMhDpdC/iB3++Iu9dVJS41B0 tGmyPTke6X4Qb2hXkaatcY7ncDZZjdEXrxqOvqkKcvRDW0OpniiO7gwK+/76dB1wBPwl AAlLWzbtkK3z9To/8lkT62ucIS+oLyVwK+LWat+dt8/NRGotIRGBhDsBI6TFZzfV1oHA lwL18S6RRRXenVQODjpKMBiniPkZM3f8/je2swpljrswpNDi8QHrWfOr5pPWW7WKvaAq 1H6wj7qj8CVTOMPsmnjTUoGDmGCgMvT1OFUfCSJgf6FhFqYXZnaw1Y+3FWPvwyP7yFd9 8LGg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to; bh=W65uoKHM6Dn0m/zjauD7WClE8CyqsZ/hXN4IZqNovYo=; b=dHku+R8uSQMOtd8KVgwcy2Fm1Q4Cd5SZwprQZ6Fg9XwUg5lILP79Zu5VLVYtSqxFkP +dRChJTbIwJntz9Rr/7DHSAD20u/yJ/FY5bDIC8oORSqli38++l5XYL7Mk/RRG+qkCOZ ThYdFCbzsHGPQ+9zmipYirTIFjT7Ot6mVW754iDaeK2lo9U+mgUdUa5rbfkJ7BkRX5KQ YOvw/EhCW74niwu1jnlBBFnUMJidZz+Z3OeOTVp9ihj3gEL1G3Hk3mNbq0pFg4wjjkdq 5JZEa1WOj2HwWE3KZ13GJg38Bj8bGkeQ151vX4R+H2tdJsTMPjdRLwC70w+vZupgrO8C 2lyw== X-Gm-Message-State: AODbwcD9Mb8FAET+MP0tkWN2KHfs+0fHByDThszMaz44mBE4fiYJpPWu wE/ZR91DK7CvXMGpywOK2t2TkeaVuNiIq+Y= X-Received: by 10.80.222.133 with SMTP id c5mr17805350edl.130.1496162988925; Tue, 30 May 2017 09:49:48 -0700 (PDT) MIME-Version: 1.0 Received: by 10.80.163.149 with HTTP; Tue, 30 May 2017 09:49:48 -0700 (PDT) In-Reply-To: <20170530161945.6ef8f3de@fabiankeil.de> References: <20170530161945.6ef8f3de@fabiankeil.de> From: Eduardo Lemos de Sa Date: Tue, 30 May 2017 13:49:48 -0300 Message-ID: Subject: Re: Trying to boot from a zfs external disk To: freebsd-questions@freebsd.org Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Content-Filtered-By: Mailman/MimeDel 2.1.23 X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 30 May 2017 16:49:51 -0000 Dear Fabien On Tue, May 30, 2017 at 11:19 AM, Fabian Keil wrote: > Eduardo Lemos de Sa wrote: > > > I installed FreeBSD-10.3-RELEASE in a internal hard disk (named, that > > time, as ada0) in a zpool called zeeroot. Now, I move this hard disk to > > a case (so, it is a external drive now) and it is recognized as da0. > > When I tried to boot it, the process start normally but stopped at the > > moment to mount partitions. Later, I used to solve problems like this > > (in UFS/UFS2 file systems) booting in a live system (memory stick or CD= ) > > and editing /etc/fstab, renaming devices. But now, there is only in > > my /etc/fstab: > > > > # Device Mountpoint FStype Options Dump Pass# > > #/dev/ada0p2 none swap sw 0 0 > > md99 none swap sw,file=3D/usr/swap0,late 0 = 0 > > > > I read https://wiki.freebsd.org/ZFSQuickStartGuide and > > https://wiki.illumos.org/display/illumos/ZFS, further FreeBSD Handbook. > > > > In the two first, there is no mention about problems in boot stage usin= g > > zfs. > > > > Further, I tried to find files under /etc/ called zfs.conf or zpool.con= f > > or other mentions to ada0 (grep -r -i ada0 *): nothing. > > In case of ZFS the root pool is specified in /boot/loader.conf > with a line like: > vfs.root.mountfrom=3D"zfs:tank" > > ZFS is supposed to figure out the location of the disk(s) itself. > > > Thus, I do not how can solve this mount booting problem. Please, could > > you give some hint about? > > This bug could explain why booting fails when you use an external disk: > https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D208882 > > Fabian > Thank you very much for share your expertise. Please, forgive me to ask one more thing: I searched (using grep) where a "mountfrom" is located or nomitade in a another 10.3-RELEASE. The result was: defaults/loader.conf:#vfs.root.mountfrom=3D"" # Specify root partiti= on in a way the Binary file kernel/kernel matches Binary file kernel.old/kernel matches Binary file loader matches Binary file loader.efi matches Binary file loader.old matches menu-commands.4th: s" set menu_caption[1]=3D${bemenu_current}${vfs.root.mountfrom}" evaluate menu-commands.4th: s" set ansi_caption[1]=3D${beansi_current}${vfs.root.mountfrom}" evaluate menu-commands.4th: dup s" set vfs.root.mountfrom=3D${bootenv_root[E]}" 3= 8 +c! evaluate menu-commands.4th: s" set currdev=3D${vfs.root.mountfrom}:" evaluate Binary file pxeboot matches Binary file userboot.so matches Binary file zfsloader matches Binary file zfsloader.old matches In this machine, zroot (the name of zpool) is mounted in /dev/ada0 (p3, mainly), but this information is not avaliable in ASCII files (apparently, it is in one or more binary files (zfsloader, as example). Thus, how to booting system "knows" where root shoud be mount? I will try to mount this hard disk, edit loader.conf and explicitly specify vfs.root.mountfrom=3D"zfs:zeeroot" Thank you again. My best regards Eduardo --=20 Eduardo Lemos de Sa Professor Titular Dep. Quimica da Universidade Federal do Paran=C3=A1 fone: +55(41)3361-3300 fax: +55(41)3361-3186