On 11/06/2012 03:21 PM, Feuerbacher, Alan wrote:
> Bruce wrote:
>
>>> Why does one have to create a directory with that name before
>>> executing the "mount" command?
>>
>> The system has to know where to attach the data structures in the file
>> tree.  You could create a script to do a 'mkdir -p <mountpoint>;
>> mount...', but that's overkill.
>
> Now I'm confused again. I thought that creating a directory actually writes 
> data into a place on a hard disk that the kernel allocates for the directory. 
> Something about inodes, if I remember right. But if that's so, and a 
> filesystem is not yet mounted, where does that data get written? It looks 
> like the cart is before the horse.
>
> Specifically, if you want to do "mount /dev/sda5 /mnt/lfs", but you have to 
> create the directory "/mnt/lfs" BEFORE you do the mount, then where does the 
> inode information about "/mnt/lfs" get written? I'm sure I'm missing some 
> details.

I don't see why there is any confusion here. Before you mount to a 
directory, the mount point is...just a directory. I don't understand the 
question about directory inodes with mounting - a created directory does 
of course take up some space on the disk, same as any other file. I 
think you are just seeing additional complications where there is none.
-- 
http://linuxfromscratch.org/mailman/listinfo/lfs-support
FAQ: http://www.linuxfromscratch.org/lfs/faq.html
Unsubscribe: See the above information page

Reply via email to