From owner-freebsd-questions Fri Dec 8 14:55:17 2000 From owner-freebsd-questions@FreeBSD.ORG Fri Dec 8 14:55:14 2000 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from guru.mired.org (okc-65-26-235-186.mmcable.com [65.26.235.186]) by hub.freebsd.org (Postfix) with SMTP id E8C5F37B404 for ; Fri, 8 Dec 2000 14:55:12 -0800 (PST) Received: (qmail 91956 invoked by uid 100); 8 Dec 2000 22:55:12 -0000 From: Mike Meyer MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Message-ID: <14897.26320.177634.47724@guru.mired.org> Date: Fri, 8 Dec 2000 16:55:12 -0600 (CST) To: Christopher Farley Cc: Mike Meyer , questions@freebsd.org Subject: Re: Weird /tmp issues In-Reply-To: <20001208164327.A541@northernbrewer.com> References: <95144528@toto.iv> <14897.23726.262612.101525@guru.mired.org> <20001208164327.A541@northernbrewer.com> X-Mailer: VM 6.75 under 21.1 (patch 10) "Capitol Reef" XEmacs Lucid X-face: "5Mnwy%?j>IIV\)A=):rjWL~NB2aH[}Yq8Z=u~vJ`"(,&SiLvbbz2W`;h9L,Yg`+vb1>RG% *h+%X^n0EZd>TM8_IB;a8F?(Fb"lw'IgCoyM.[Lg#r\ Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG Christopher Farley types: > Mike Meyer (mwm@mired.org) wrote: > > Christopher Farley types: > > I run tmp on swap (via mfs), and it works fine. However, it gets > > recreated *on reboots*. I didn't see you talk about a reboot - have > > you tried that? > Oh yes. And even after a reboot, /tmp is filled with all kinds of crap, > namely those unix domain sockets and lockfiles created by X. You should leave the thread on -questions so other can play. > > X creates lock files and unix domain sockets in /tmp. If you don't > > want to reboot with the new /tmp in place, you might try moving > > /tmp.old/.X* to /tmp. > The sockets have been causing trouble. When I tried to mv /tmp /usr/tmp, > I get an "Operation not permitted" on every socket. I have not tried to > move the sockets separately. > I can mv /tmp all over the root filesystem, of course; just not to any > other filesystems. (I assume mv renames if the target filesystem > is the same as the source, and copies the files otherwise.) You can't really "mv" files from one file system to another; in that case mv calls cp(1) for you (it's in the man page). That doesn't work very well on sockets. > Those sockets remain even after a reboot; even if I don'r run X. > Is this normal? I would think if you shutdown X, it would remove > all its lockfiles and sockets. It seems as if X requires those > sockets to run, because if I move /tmp, my display and keyboard > both fail until a reboot. I'd think that about X as well, but I'm not an X guru. If you're not cleaning out /tmp at reboot, then you should: "shutdown -r"; when it comes up, don't go multi-user, go single-user. Then mv /tmp to /tmp.old (I'd suggest *deleting* the old /tmp) and create the new /tmp appropriately. That got lost in here, but it's a symlink to another fs, right? > I searched deja.com regarding this issue, and found a message from > someone who said "I like to move /tmp to a diferent filesystem before X > has a chance to establish sockets there." Which is pretty much what I outlined above. Moving /tmp to /tmp.old *should* make X recreate them when you start it, providing that you've rebooted the system in between. If you've done that, then I'd seriously suggest removing the things. > Christopher Farley Ok, I can't resist - I get asked what I working with Dana Carvey is like regularly. Do you get asked what it's like being dead? http://www.mired.org/home/mwm/ Independent WWW/Unix/FreeBSD consultant, email for more information. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message