Linode Forum
Linode Community Forums
 FAQFAQ    SearchSearch    MembersMembers      Register Register 
 LoginLogin [ Anonymous ] 
Post new topic  Reply to topic
Author Message
PostPosted: Sat Oct 10, 2009 11:59 pm 
Offline
Newbie

Joined: Wed Oct 07, 2009 2:27 pm
Posts: 3
Location: San Francisco, CA
This weird, I have two tmpfs partition on a new Linode(Debian 5):

df -h
Filesystem Size Used Avail Use% Mounted on
/dev/xvda 12G 979M 11G 9% /
tmpfs 271M 0 271M 0% /lib/init/rw
tmpfs 271M 4.0K 271M 1% /dev/shm

Which one is correct and how do I get rid of the other one.
I only have one swap space setup in my Linode Manager


Top
   
 Post subject:
PostPosted: Sun Oct 11, 2009 12:34 am 
Offline
Senior Member
User avatar

Joined: Sun Feb 08, 2004 7:18 pm
Posts: 562
Location: Austin
It's not a problem. I wish I could tell you exactly what those directories are for, but my guess is the kernel or some core library uses them for state.

tmpfs doesn't allocate any RAM it's not actually using, so the 271M you see there is some kind of maximum that'll never be approached. Do a du on those directories and you'll find they're so close to empty it's not even worth looking at.


Top
   
 Post subject:
PostPosted: Sun Oct 11, 2009 5:09 am 
Offline
Newbie

Joined: Wed Oct 07, 2009 2:27 pm
Posts: 3
Location: San Francisco, CA
the reason i was asking is that I want to mount my tmp space with noexec, so I want to know which one I need to deal with.


Top
   
 Post subject:
PostPosted: Sun Oct 11, 2009 12:47 pm 
Offline
Senior Member
User avatar

Joined: Fri Oct 24, 2003 3:51 pm
Posts: 965
Location: Netherlands
The tmpfs in /lib/init/rw seems to be a debian thing - see bugs 403863 and 405189.

NeoGuru wrote:
Which one is correct and how do I get rid of the other one.
I only have one swap space setup in my Linode Manager.

The tmpfs in /dev/shm is the "real" one. Don't get rid of the other one, as init scripts that write there may be run at other times (if you manually restart a service, or switch runlevels).

_________________
/ Peter


Top
   
 Post subject:
PostPosted: Sun Oct 11, 2009 1:07 pm 
Offline
Senior Member
User avatar

Joined: Sun Feb 08, 2004 7:18 pm
Posts: 562
Location: Austin
Neither one of those is your "tmp space".


Top
   
 Post subject:
PostPosted: Tue Oct 13, 2009 1:25 am 
Offline
Newbie

Joined: Wed Oct 07, 2009 2:27 pm
Posts: 3
Location: San Francisco, CA
Xan wrote:
Neither one of those is your "tmp space".

What are these then?


Top
   
 Post subject:
PostPosted: Tue Oct 13, 2009 6:47 am 
Offline
Senior Member
User avatar

Joined: Sat Aug 30, 2008 1:55 pm
Posts: 1739
Location: Rochester, New York
For the first, it appears to be something like /var/run, but Debian-specific and available prior to /var being mounted:

http://bugs.debian.org/cgi-bin/bugrepor ... =%23403863

/dev/shm is for a particular inter-process shared memory mechanism.

Whether or not those are safe to noexec is something you'd have to ask the Debian folks about...


Top
   
 Post subject:
PostPosted: Tue Oct 13, 2009 12:46 pm 
Offline
Senior Member
User avatar

Joined: Sun Feb 08, 2004 7:18 pm
Posts: 562
Location: Austin
The reason you really want to noexec /tmp is because any user can write to it. That's not the case for these two housekeeping things.


Top
   
Display posts from previous:  Sort by  
Post new topic  Reply to topic


Who is online

Users browsing this forum: No registered users and 3 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Jump to:  
RSS

Powered by phpBB® Forum Software © phpBB Group