| 1 | #!/bin/bashscip-shell filesystem . . `/bin/bash`. |
| 2 | |
| 3 | # quick prototype init program for arm |
| 4 | set -x |
| 5 | cd /scip-shell filesystem . . `/`. |
| 6 | export PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/binscip-shell filesystem . . `/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin`. |
| 7 | mountscip-shell system . . mount. /procscip-shell filesystem . . `/proc`. /procscip-shell filesystem . . `/proc`. -t proc |
| 8 | mountscip-shell system . . mount. /dev/ptsscip-shell filesystem . . `/dev/pts`. /dev/ptsscip-shell filesystem . . `/dev/pts`. -t devpts |
| 9 | |
| 10 | for MODULE in lib/modules/linux-live/kernel/drivers/ide/ide-core.ko \ |
| 11 | lib/modules/linux-live/kernel/drivers/ide/ide-disk.ko \ |
| 12 | lib/modules/linux-live/kernel/drivers/ide/ide-generic.ko \ |
| 13 | lib/modules/linux-live/kernel/drivers/scsi/scsi_mod.ko \ |
| 14 | lib/modules/linux-live/kernel/drivers/scsi/scsi_transport_spi.ko \ |
| 15 | lib/modules/linux-live/kernel/drivers/scsi/sym53c8xx_2/sym53c8xx.ko \ |
| 16 | lib/modules/linux-live/kernel/drivers/scsi/sd_mod.ko \ |
| 17 | lib/modules/linux-live/kernel/fs/mbcache.ko \ |
| 18 | lib/modules/linux-live/kernel/fs/jbd/jbd.ko \ |
| 19 | lib/modules/linux-live/kernel/fs/ext2/ext2.ko \ |
| 20 | lib/modules/linux-live/kernel/fs/ext3/ext3.ko \ |
| 21 | lib/modules/linux-live/kernel/drivers/net/smc91x.ko; do |
| 22 | insmod $MODULE |
| 23 | done |
| 24 | # this process is asynchronous, need to wait about 2 seconds until SCSI device is detected. |
| 25 | |
| 26 | echoscip-shell system . . echo. "Try checking inside this initrd, exit to enter the chroot" |
| 27 | /bin/bashscip-shell filesystem . . `/bin/bash`. |
| 28 | |
| 29 | echoscip-shell system . . echo. "Entering chroot" |
| 30 | mountscip-shell system . . mount. /dev/sdascip-shell filesystem . . `/dev/sda`. /mntscip-shell filesystem . . `/mnt`. -t ext3 |
| 31 | chrootscip-shell system . . chroot. /mntscip-shell filesystem . . `/mnt`. /sbin/ifconfigscip-shell filesystem . . `/sbin/ifconfig`. eth0 up |
| 32 | chrootscip-shell system . . chroot. /mntscip-shell filesystem . . `/mnt`. /sbin/dhclientscip-shell filesystem . . `/sbin/dhclient`. eth0 |
| 33 | chrootscip-shell system . . chroot. /mntscip-shell filesystem . . `/mnt`. /usr/bin/apt-getscip-shell filesystem . . `/usr/bin/apt-get`. update |
| 34 | chrootscip-shell system . . chroot. /mntscip-shell filesystem . . `/mnt`. /bin/bashscip-shell filesystem . . `/bin/bash`. |