From owner-freebsd-questions@freebsd.org Thu Oct 19 17:10:58 2017 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 6A408E40F93 for ; Thu, 19 Oct 2017 17:10:58 +0000 (UTC) (envelope-from chris@vindaloo.com) Received: from yavin.vindaloo.com (yavin.vindaloo.com [173.199.117.73]) (using TLSv1 with cipher DHE-RSA-CAMELLIA256-SHA (256/256 bits)) (Client CN "yavin.vindaloo.com", Issuer "Vindaloo Sign CA" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4785E71739; Thu, 19 Oct 2017 17:10:57 +0000 (UTC) (envelope-from chris@vindaloo.com) Received: from anza.vindaloo.com (ool-45714982.dyn.optonline.net [69.113.73.130]) (using TLSv1 with cipher DHE-RSA-CAMELLIA256-SHA (256/256 bits)) (Client CN "smtp.vindaloo.com", Issuer "Vindaloo Sign CA" (verified OK)) by yavin.vindaloo.com (Postfix) with ESMTPS id ED7C3D7AB5; Thu, 19 Oct 2017 13:10:50 -0400 (EDT) Received: from csh-desktop-vm00.loopone.com (h4.82.141.40.ip.windstream.net [40.141.82.4]) (using TLSv1 with cipher AES128-SHA (128/128 bits)) (Client did not present a certificate) by anza.vindaloo.com (Postfix) with ESMTPSA id 38758101D6; Thu, 19 Oct 2017 13:10:50 -0400 (EDT) Date: Thu, 19 Oct 2017 13:10:44 -0400 From: Christopher Sean Hilton To: Matthew Seaman Cc: freebsd-questions@freebsd.org Subject: Re: Rcorder/rc.conf question on FILESYSTEMS and tmp Message-ID: <20171019171044.7ccqyxfr72v52fsp@csh-desktop-vm00.loopone.com> References: <20171018170549.GA3502@anza.vindaloo.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: NeoMutt/20171013 X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 19 Oct 2017 17:10:58 -0000 On Thu, Oct 19, 2017 at 07:13:40AM +0100, Matthew Seaman wrote: > On 18/10/2017 18:05, Christopher Sean Hilton wrote: [ ...snip... ] > FILESYSTEMS requires mountcritlocal. mountcritlocal mounts all local > filesystems from /etc/fstab which generally includes mounting /tmp > > Hmmm.... there is a /etc/rc.d/tmp which is different from just using > tmpfs in /etc/fstab -- and it's the latter which I'd recommend you to > implement. > > Looks like /etc/rc.d/tmp mounts a tmpmfs, which is a slightly different > concept and the startup script only does anything if a /tmp does not > already exist. In practice that would generally be limited to diskless > setups and other speciality systems. > > Any other method for mounting /tmp than using /etc/rc.d/tmp will be > based on /etc/fstab and come under mountcritlocal. That will mean that > /tmp is mounted and available well before any daemons get started up. > That covers the vast majority of systems. tmp not being mentioned in > FILESYSTEMS is arguably a bug, but that's something people on > freebsd-fs@freebsd.org would be much better placed to answer. > To summarize, there are two ways to get /tmp mounted on a memory backed filesystem. One is specify the options in /etc/fstab, and the other is to specify something like this: tmpmfs="YES" # Set to YES to always create an mfs /tmp, NO to never tmpsize="1g" # Size of mfs /tmp if created tmpmfs_flags="-S -o async,noexec" # Extra mdmfs options for the mfs /tmp In /etc/rc.conf. You recommend specifying the options in /etc/fstab. That will make mountcritlocal force the /tmp filesystem to be mounted and ready before it exits and then things only need depend on FILESYSTEMS being done. Ok, problem solved. -- Chris > Cheers, > > Matthew > > -- Chris __o "All I was trying to do was get home from work." _`\<,_ -Rosa Parks ___(*)/_(*)____.___o____..___..o...________ooO..._____________________ Christopher Sean Hilton [chris/at/vindaloo/dot/com]