HIP:TS-7000:mke2fs

From Earlham Cluster Department

Jump to: navigation, search

Compiling

arm@crow:~/e2fsprogs-1.39$ ./configure --host=arm-unknown-linux-gnu --build=arm --with-cc=/opt/crosstool/gcc-4.0.1-glibc-2.3.5/arm-unknown-linux-gnu/arm-unknown-linux-gnu/bin/gcc --with-ld=/opt/crosstool/gcc-4.0.1-glibc-2.3.5/arm-unknown-linux-gnu/arm-unknown-linux-gnu/bin/ld
...
arm@crow:~/e2fsprogs-1.39$ make
....
arm@crow:~/e2fsprogs-1.39$ file misc/mke2fs
misc/mke2fs: ELF 32-bit LSB executable, ARM, version 1, for GNU/Linux 2.4.3, dynamically linked (uses shared libs), not stripped

Creating a ramdisk

Using these directions...

  1. Catch the bootloader using the RedBoot directions.
  2. Add the kernel parameter: ramdisk_size=3000 (expressed in 1024-byte blocks)
  3. Added the following script as /etc/init.d/ramdisk
  4. Add a symlink:
$ cd etc/rc.d/rc3.d/
$ ln -s ../../init.d/dropbear S99dropbear

The init.d script

OPTIONS=""

case "$1" in

   start)
      echo "Formatting and mounting ramdisk"
      mke2fs -m 0 /dev/rd/0
      mount /dev/rd/0 /mnt/rd
   ;;
   stop)
       echo "Unmounting ramdisk"
       umount /mnt/rd
   ;;                     
   restart)
       $0 stop 
       $0 start
   ;;
   *)
      echo "usage: start|stop|restart"
   ;;

esac

Personal tools
Namespaces
Variants
Actions
websites
wiki
this semester
Toolbox