Re: Ramdisk support



In message: <2f3a439f0611142305n441d3adwf7738ae40f9103e3@xxxxxxxxxxxxxx>
"Aditya Godbole" <aag.lists@xxxxxxxxx> writes:
: Is there any ramdisk support in freebsd, as there is in netbsd? If
: there is no such functionality right now, is anyone working on it?
: What are the alternatives if I want to mount a root filesytem from ram?

mdconfig will create one at run time.

If you want to compile it into the kernel, then you need to create
your image (mine is for an ARM, and I call my image ARM-MD). You then
need the following config options:

options MD_ROOT #MD is a potential root device
options MD_ROOT_SIZE=8192 # 8MB ram disk
makeoptions MFS_IMAGE=/home/imp/ARM-MD
options ROOTDEVNAME=\"ufs:md0\"

in your kernel. This is for -current. I'm unsure if the MFS_IMAGE
stuff has been MFC'd or not. If not, then you'll need to perform the
following steps after you build the kernel to add the image:

@dd if="${MFS_IMAGE}" ibs=8192 of="${KERNEL_KO}" \
obs=`strings -at d "${KERNEL_KO}" | \
grep "MFS Filesystem goes here" | awk '{print $$1}'` \
oseek=1 conv=notrunc 2>/dev/null && \
strings ${KERNEL_KO} | \
grep 'MFS Filesystem had better STOP here' > /dev/null || \
(rm ${KERNEL_KO} && echo 'MFS image too large' && false)

where KERNEL_KO is typically 'kernel'.

Warner
_______________________________________________
freebsd-hackers@xxxxxxxxxxx mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to "freebsd-hackers-unsubscribe@xxxxxxxxxxx"



Relevant Pages

  • Re: FreeBSD 5/6/7 kernel emulator for NetBSD 2.x
    ... find all the devices on the system, without being a kernel expert. ... driver and the NetBSD kernel. ... but the FreeBSD device system. ...
    (freebsd-hackers)
  • Re: FreeBSD beginner (NetBSD advanced)
    ... I have used a single 256MB mfs on FreeBSD for months without any problem. ... I can live without them on NetBSD. ... >> Read the handbook on building the kernel. ...
    (freebsd-questions)
  • Ramdisk support
    ... Is there any ramdisk support in freebsd, as there is in netbsd? ... there is no such functionality right now, ...
    (freebsd-hackers)
  • Re: Ramdisk support
    ... Is there any ramdisk support in freebsd, as there is in netbsd? ... there is no such functionality right now, ...
    (freebsd-hackers)
  • FreeBSD Status report for Oct-Dec 2003
    ... Bluetooth stack for FreeBSD ... Not much to report. ... Bluetooth kernel modules appear to be stable. ... concerns and some src committers are willing to commit the patches. ...
    (freebsd-current)