From owner-freebsd-questions@FreeBSD.ORG Tue Apr 27 01:17:25 2010 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 4CB99106566C for ; Tue, 27 Apr 2010 01:17:25 +0000 (UTC) (envelope-from mark-fbsd-quest-10+20100426@giovannetti.ca) Received: from www.giovannetti.ca (www.giovannetti.ca [206.248.136.48]) by mx1.freebsd.org (Postfix) with ESMTP id 94E8D8FC13 for ; Tue, 27 Apr 2010 01:17:24 +0000 (UTC) Received: from the.palaceofretention.ca (unknown [192.168.68.3]) by www.giovannetti.ca (Postfix) with ESMTPSA id 97870229C9 for ; Mon, 26 Apr 2010 21:12:57 -0400 (EDT) Message-ID: <4BD6375B.6030500@giovannetti.ca> Date: Mon, 26 Apr 2010 21:01:15 -0400 From: "Mark G." User-Agent: Mozilla/5.0 (X11; U; FreeBSD i386; en-US; rv:1.9.1.5) Gecko/20100103 Thunderbird/3.0 MIME-Version: 1.0 To: User Questions Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Mailman-Approved-At: Tue, 27 Apr 2010 02:31:43 +0000 Subject: How to determine /dev/ad* from mount label X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 27 Apr 2010 01:17:25 -0000 Hi, I've tried the mount, tunefs and df manuals, and don't know where to look next. I am trying to find out what device, in terms of /dev/ad0s1a and so on, is actually 'connected' to a label mounted file system. Here is my fstab (from PC-BSD, by the way): # more /etc/fstab # Device Mountpoint FStype Options Dump Pass /dev/label/rootfs0 / ufs rw,noatime 1 1 /dev/label/swap0 none swap sw 0 0 /dev/label/var0 /var ufs rw,noatime 1 1 /dev/label/usr0 /usr ufs rw,noatime 1 1 procfs /proc procfs rw 0 0 linprocfs /compat/linux/proc linprocfs rw 0 0 tmpfs /tmp tmpfs rw,mode=1777 0 0 I just wanted to know if there was a utility to tell me which actual device was mounted. I also tried camcontrol devlist and atacontrol list. The latter allowed me to determine that /dev/label/rootfs0 is ad2s1a based on the actual disk size and a process of elimination. Does anyone know a magic incantation to output this label->device mapping? Thanks Mark P.S. The latest FreeBSD 8 under PC-BSD is really quite good. My thanks to everyone involved. Picked up a copy at the freebsdmall with the guide. Excellent.