hey check out my crappy iso :)

Bryan Dumm bryan at bcpub.com
Mon May 7 14:39:04 PDT 2001


> This could be easier if there is a symlink from /etc/mtab -> /proc/mounts
> but not tested yet.

This is what I had the first time for my mount problem. I dunno what
it was :) cause it went away.....

> > many dirs are /ramfiles.
>
> In my setup I had only /var, /tmp, /dev and /etc for f*$%§ mtab
> (/proc/mounts should help).
>
> what do you think of that:
>
>
> /etc/sysconfig/ramdisks
> #begin
> RAMDISKS="_0 _1 _2 _3"
>
> RAMDISK_0=/etc
> RDSIZE_0=512
>
> RAMDISK_1=/var
> RDSIZE_1=4096
>
> RAMDISK_2=/tmp
> RDSIZE_2=512
>
> RAMDISK_3=/dev
> RDSIZE_3=3072
> #end
>
> and
>
>
> /etc/init.d/mountfs
> #start
> .
> .
> .
> #
> # initializes a new ramdisk and cp the files from the directory to the
> ramdisk # and finally mounts the ramdisk over the directory
> #
> # $1 .. ramdevice
> # $2 .. size
> # $3 .. directory
> #
> setup_ramdisk () {
>         dd if=/dev/zero of=$1 bs=1k count=$2 > /dev/null 2> /dev/null
>         mke2fs -vm0 -i 1024 $1 $2 > /dev/null 2> /dev/null
>         mount -n -t ext2 $1 $TMPMNT
>         cp -a $3/* $TMPMNT > /dev/null 2> /dev/null
>         umount $TMPMNT
>         mount -n -t ext2 $1 $3
>         # for remounting
>         echo "$1 $3 ext2 defaults 0 0" >> /etc/fstab
>         return 0
> }
> .
> .
> .
>   start)
>     echo -n "Mounting procfs ..."
>     mount -n -t proc proc /proc
>     evaluate_retval
>
>     declare -i rdnum=1
>
>     for I in $RAMDISKS; do
>       eval RAMDISK=\$RAMDISK$I
>       eval RDSIZE=\$RDSIZE$I
>
>       echo -n "Create ramdisk for $RAMDISK ..."
>       setup_ramdisk /dev/ram$rdnum $RDSIZE $RAMDISK
>       evaluate_retval
>       ((rdnum++))
>       MNT="`echo $MNT` $RAMDISK"
>     done
>
>    # remounting stuff
> .
> .
> .
> #end

Ok so then what happens when you are using ramfs?

/me just little confused as I am using ramfs already, I see
your point, but am unsure about overmounting this way...

would it be like 
mount -t ramfs ramfs /etc
cp -a /etc /etc

:)?

Bryan





-- 
Unsubscribe: send email to alfs-discuss-request at linuxfromscratch.org
and put unsubscribe in the subject header of the message





More information about the alfs-discuss mailing list