From owner-freebsd-questions@FreeBSD.ORG Mon Sep 17 20:22:12 2007 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 3E10916A419 for ; Mon, 17 Sep 2007 20:22:12 +0000 (UTC) (envelope-from r17fbsd@xxiii.com) Received: from cartman.xxiii.com (cartman.xxiii.com [208.62.177.45]) by mx1.freebsd.org (Postfix) with ESMTP id 171CD13C458 for ; Mon, 17 Sep 2007 20:22:11 +0000 (UTC) (envelope-from r17fbsd@xxiii.com) Received: from [172.23.23.190] (lan23.xxiii.com [208.62.177.50]) by cartman.xxiii.com (8.13.8/8.13.8) with ESMTP id l8HKLsju065549; Mon, 17 Sep 2007 16:21:54 -0400 (EDT) (envelope-from r17fbsd@xxiii.com) Message-ID: <46EEE1E2.7080106@xxiii.com> Date: Mon, 17 Sep 2007 16:21:54 -0400 From: Rob User-Agent: Thunderbird 1.5.0.13 (Windows/20070809) MIME-Version: 1.0 To: Harry Doyle References: <950c85d80709171222o596ef293p75a793d87b45f38b@mail.gmail.com> In-Reply-To: <950c85d80709171222o596ef293p75a793d87b45f38b@mail.gmail.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: freebsd-questions@freebsd.org Subject: Re: mixer levels on boot 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: Mon, 17 Sep 2007 20:22:12 -0000 Harry Doyle wrote: > however whenever i reboot the machine the mixer command always shows the > default level of 90 which clips pretty hard. My 6.2 system saves and restores the mixer settings across boots. Apparently in the file /var/db/mixer0-state However, the file is root owned and 644; perhaps if you create the file and chmod it writable, your settings will stick? Or you could put the command in your script. "mixer -S" dumps the current settings in a format mixer can read back. I do this in a script that dribbles music on hold to our phone system: mixer_default="vol 45:45 pcm 40:40" # Call mixer command to set params specified in conf file, or defaults. set_mixer() { if [ -f $home_dir/mixer.conf ]; then mixer `cat $home_dir/mixer.conf` echo "set mixer.conf params" else mixer $mixer_default echo "set mixer default values" fi } -RW