initrd イメージ作成
昨日に引き続き下記の内容をDebianインストールフロッピーでなぞってみます。
http://jr0bak.homelinux.net/~imai/linux/embedded_beginner-4.html#ss4.2
# ls -l initrd -rwxr-xr-x 1 root root 238592 Apr 24 12:22 initrd
ddコマンドでこのサイズのイメージファイルを作ろうとしたのですが、coLinuxでは作れませんでした。代わりにCygwinでmyinitrd.imgを作成しcoLinux側にコピーしました。
# mke2fs myinitrd.img mke2fs 1.40-WIP (14-Nov-2006) myinitrd.img is not a block special device. Proceed anyway? (y,n) y Filesystem label= OS type: Linux Block size=1024 (log=0) Fragment size=1024 (log=0) 32 inodes, 232 blocks 11 blocks (4.74%) reserved for the super user First data block=1 1 block group 8192 blocks per group, 8192 fragments per group 32 inodes per group Writing inode tables: done Writing superblocks and filesystem accounting information: done This filesystem will be automatically checked every 28 mounts or 180 days, whichever comes first. Use tune2fs -c or -i to override.
しかしこの後、helloの実行ファイルが、このイメージファイルよりも大きい事に気付いてこの手順はあえなく断念。
ls -l total 496 -rwxr-xr-x 1 root root 495447 Apr 24 15:56 hello -rw-r--r-- 1 root root 91 Apr 24 15:56 hello.c