Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
mount --bind on startup [SOLVED]
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Installing Gentoo
View previous topic :: View next topic  
Author Message
Insulator
n00b
n00b


Joined: 21 Mar 2005
Posts: 28
Location: Australia

PostPosted: Wed Oct 04, 2006 3:40 am    Post subject: mount --bind on startup [SOLVED] Reply with quote

My system is a dualboot with Windows (need for uni and games), so I have a couple of FAT partitions shared between the 2 OS's.
One of them has a couple of folders which I want mounted into my user folder, but I don't want all the rest of the stuff.

So recently every time I've rebooted I've run
Code:
mount --bind /mnt/share1/foldertoshare /home/insulator/foldertoshare

for each folder.

I'm sure there has to be a way to automate this on startup, but can't figure it out, having played around with init scripts and the like.


Last edited by Insulator on Wed Oct 04, 2006 4:10 am; edited 1 time in total
Back to top
View user's profile Send private message
jmbsvicetto
Moderator
Moderator


Joined: 27 Apr 2005
Posts: 4734
Location: Angra do Heroísmo (PT)

PostPosted: Wed Oct 04, 2006 3:48 am    Post subject: Reply with quote

Hi.

If you just need this for your user, why don't you put it on .bashrc?
_________________
Jorge.

Your twisted, but hopefully friendly daemon.
AMD64 / x86 / Sparc Gentoo
Help answer || emwrap.sh
Back to top
View user's profile Send private message
beandog
Bodhisattva
Bodhisattva


Joined: 04 May 2003
Posts: 2072
Location: /usa/utah

PostPosted: Wed Oct 04, 2006 3:58 am    Post subject: Reply with quote

I can think of two things to do -- put it the commands /etc/conf.d/local start, or just mount them on boot like eveyrthing else:

http://gentoo-wiki.com/TIP_Bind_A_Directory_In_FSTAB
_________________
If it ain't broke, tweak it. dvds | blurays | blog | wiki
Back to top
View user's profile Send private message
Insulator
n00b
n00b


Joined: 21 Mar 2005
Posts: 28
Location: Australia

PostPosted: Wed Oct 04, 2006 4:10 am    Post subject: Reply with quote

Thanks for quick replies guys.

Got it sorted now, the .bashrc route wasn't working because of permissions, I was getting
Code:
mount: only root can do that

but the fstab way was just what I was looking for.

Marking it solved.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Installing Gentoo All times are GMT
Page 1 of 1

 
Jump to:  
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
You cannot vote in polls in this forum