From owner-freebsd-stable@FreeBSD.ORG Fri Nov 17 20:18:57 2006 Return-Path: X-Original-To: freebsd-stable@freebsd.org Delivered-To: freebsd-stable@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id DDC1516A40F for ; Fri, 17 Nov 2006 20:18:57 +0000 (UTC) (envelope-from tom@tomjudge.com) Received: from smtp-out4.blueyonder.co.uk (smtp-out4.blueyonder.co.uk [195.188.213.7]) by mx1.FreeBSD.org (Postfix) with ESMTP id 761DC43D4C for ; Fri, 17 Nov 2006 20:18:57 +0000 (GMT) (envelope-from tom@tomjudge.com) Received: from [172.23.170.146] (helo=anti-virus03-09) by smtp-out4.blueyonder.co.uk with smtp (Exim 4.52) id 1GlAAn-0000gF-K1; Fri, 17 Nov 2006 20:18:53 +0000 Received: from [82.43.34.109] (helo=[192.168.0.2]) by asmtp-out1.blueyonder.co.uk with esmtp (Exim 4.52) id 1GlAAm-0002w9-TX; Fri, 17 Nov 2006 20:18:52 +0000 Message-ID: <455E1AA8.6030900@tomjudge.com> Date: Fri, 17 Nov 2006 20:25:12 +0000 From: Tom Judge User-Agent: Thunderbird 1.5.0.7 (X11/20060922) MIME-Version: 1.0 To: Scott Long References: <36FBC1D2-9F33-4EA1-B93D-EB4C2B1253E8@khera.org> <20061116003422.GC942@tigerfish2.my.domain> <35A2EF81-7D7B-4A8A-9101-5AEFEB3ED057@khera.org> <455E14AC.7070906@samsco.org> In-Reply-To: <455E14AC.7070906@samsco.org> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: Vivek Khera , FreeBSD Stable Subject: Re: adaptec utilities on amd64? X-BeenThere: freebsd-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Production branch of FreeBSD source code List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 17 Nov 2006 20:18:57 -0000 Scott Long wrote: > Vivek Khera wrote: >> Some time long ago, someone posted a very short C program that probes >> the LSI controller and spits out this kind of output: >> >> [root@d03]# amrstat >> Drive 0: 34.18 GB, RAID1 >> optimal >> Drive 1: 102.54 GB, RAID1 >> optimal >> >> This is the kind of output I'd love to get from my adaptec >> controllers, too. This can be trivially scripted and hooked into a >> monitoring system like nagios. >> >> The aaccli tool is a curses based app (despite the "cli" in the name) >> and scripting it is damn near impossible. It doesn't even read >> commands from stdin! >> > > Yes, scripting it is possible, and it does have a non-interactive mode. > Try the following: > > printf "open aac0\ncontroller details\nexit\n" | aaccli > I have been trying to find a similar solution for aac controllers that will display the status of the volumes that the controller has configured (E.g. Optimal, Degraded, Failed etc...). So far the only way I have found to do it is to store the output of: printf "open aac0\ncontainer list\nexit\n" | aaccli For a known good status and then periodiacly check the output of the above command with the same status. Is there a better way to do this? Tom