From owner-freebsd-questions@freebsd.org Mon Feb 5 18:00:37 2018 Return-Path: Delivered-To: freebsd-questions@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id A432BEE2146 for ; Mon, 5 Feb 2018 18:00:37 +0000 (UTC) (envelope-from kreme@kreme.com) Received: from mail.covisp.net (www.covisp.net [65.121.55.45]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 52450801B8 for ; Mon, 5 Feb 2018 18:00:37 +0000 (UTC) (envelope-from kreme@kreme.com) From: Cerebus Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: quoted-printable Date: Mon, 5 Feb 2018 11:00:27 -0700 Subject: Automount USB drive when connected Message-Id: <3BAACBF6-C4E0-44AA-AD5F-277D3C8267C0@kreme.com> To: freebsd-questions@freebsd.org X-Mailer: iPad Mail (15E5167f) X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 05 Feb 2018 18:00:37 -0000 I have a USB enclosure that I'd like to be able to walk up to the machine a= nd plug in and have a series of things happen: 1) Disk mounts in /mnt/backup (or wherever, the key is it mounts without int= ervention) 2) a backup script I specify runs when the disk successfully mounts 3) when complete /mnt/backup unmounts=20 I've got step 2 (mostly), and step 3 is trivial, but I can't get step 1 work= ing (To be clear, this disk would never be present at startup. Basically, walk i= n, plug in drive, let the backup run, unplug the drive, and leave. I want th= is to work without requiring anyone to login) --=20 ADVANCE TO THE REAR!=