From owner-freebsd-questions@freebsd.org Wed Jul 13 07:42:20 2016 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 220EFB97659 for ; Wed, 13 Jul 2016 07:42:20 +0000 (UTC) (envelope-from guru@unixarea.de) Received: from ms-10.1blu.de (ms-10.1blu.de [178.254.4.101]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id DB2621E5A for ; Wed, 13 Jul 2016 07:42:19 +0000 (UTC) (envelope-from guru@unixarea.de) Received: from [89.15.239.103] (helo=localhost.unixarea.de) by ms-10.1blu.de with esmtpsa (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.76) (envelope-from ) id 1bNEo6-0000S8-00 for freebsd-questions@freebsd.org; Wed, 13 Jul 2016 09:42:10 +0200 Received: from localhost.my.domain (c720-r292778-amd64 [127.0.0.1]) by localhost.unixarea.de (8.15.2/8.14.9) with ESMTPS id u6D7g622002954 (version=TLSv1.2 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO) for ; Wed, 13 Jul 2016 09:42:06 +0200 (CEST) (envelope-from guru@unixarea.de) Received: (from guru@localhost) by localhost.my.domain (8.15.2/8.14.9/Submit) id u6D7g59I002953 for freebsd-questions@freebsd.org; Wed, 13 Jul 2016 09:42:05 +0200 (CEST) (envelope-from guru@unixarea.de) X-Authentication-Warning: localhost.my.domain: guru set sender to guru@unixarea.de using -f Date: Wed, 13 Jul 2016 09:42:05 +0200 From: Matthias Apitz To: freebsd-questions@freebsd.org Subject: mounting OpenBSD partition Message-ID: <20160713074205.GA2894@c720-r292778-amd64> Reply-To: Matthias Apitz Mail-Followup-To: Matthias Apitz , freebsd-questions@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit X-Operating-System: FreeBSD 11.0-CURRENT r292778 (amd64) User-Agent: Mutt/1.5.24 (2015-08-30) X-Con-Id: 51246 X-Con-U: 0-guru X-Originating-IP: 89.15.239.103 X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.22 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 13 Jul 2016 07:42:20 -0000 Hello, I was in need to investigate some hardware / driver issue and made an OpenBSD bootable USB key. The creation and installation of this is pretty much simple and fast. Based on an image install59.ff (some 290 MByte) after a few minutes you have a running system on the disk or in my case on some other USB key of 15 GByte which even contains already X11 (just login and says 'startx'). Just do installation to sd1 (sd0 is the harddisk in your laptop). Nice. What is interesting for me as FreeBSD user is, that you can mount parts of the OpenBSD file system to our FreeBSD; the layout is: # fdisk da0 ******* Working on device /dev/da0 ******* parameters extracted from in-core disklabel are: cylinders=1915 heads=255 sectors/track=63 (16065 blks/cyl) Figures below won't work with BIOS for partitions not in cyl 1 parameters to be used for BIOS calculations are: cylinders=1915 heads=255 sectors/track=63 (16065 blks/cyl) Media sector size is 512 Warning: BIOS sector numbering starts with sector 1 Information from DOS bootblock is: The data for partition 1 is: The data for partition 2 is: The data for partition 3 is: The data for partition 4 is: sysid 166 (0xa6),(OpenBSD) start 64, size 30764411 (15021 Meg), flag 80 (active) beg: cyl 0/ head 1/ sector 2; end: cyl 1023/ head 254/ sector 63 and we have the following devices in FreeBSD after plug-in: # ls -l /dev/da* crw-r----- 1 root operator 0x74 jul. 13 07:44 /dev/da0 crw-r----- 1 root operator 0x75 jul. 13 07:44 /dev/da0s4 crw-r----- 1 root operator 0x77 jul. 13 09:38 /dev/da0s4a crw-r----- 1 root operator 0x78 jul. 13 09:38 /dev/da0s4b crw-r----- 1 root operator 0x79 jul. 13 09:38 /dev/da0s4d crw-r----- 1 root operator 0x7a jul. 13 09:38 /dev/da0s4e crw-r----- 1 root operator 0x7b jul. 13 09:38 /dev/da0s4f crw-r----- 1 root operator 0x7c jul. 13 09:38 /dev/da0s4g crw-r----- 1 root operator 0x7d jul. 13 09:38 /dev/da0s4h crw-r----- 1 root operator 0x7e jul. 13 09:38 /dev/da0s4i crw-r----- 1 root operator 0x7f jul. 13 09:38 /dev/da0s4j crw-r----- 1 root operator 0x80 jul. 13 09:38 /dev/da0s4k The device /dev/da0s4 is normal UFS mountable and seems to contain the root file system. I found no way to get further access, for example to /home, ... HIH matthias -- Matthias Apitz, ✉ guru@unixarea.de, ⌂ http://www.unixarea.de/ ☎ +49-176-38902045 "Wer übersieht, dass wir uns den anderen weggenommen haben und sie uns wiederhaben wollen, kann von den Kämpfen der letzten Tage keinen verstehen. Und kann natürlich auch keinen dieser Kämpfe bestehen." Hermann Kant in jW 1.10.1989