ts-7000
[Top] [All Lists]

[ts-7000] Re: Simplifying Booting TS-7260 to Debian Sarge in SD card

To:
Subject: [ts-7000] Re: Simplifying Booting TS-7260 to Debian Sarge in SD card
From: "Rekcut_Nod" <>
Date: Sun, 21 Nov 2010 20:55:45 -0000
For some reason, my boot-up now hangs at the

exec /sbin/init

line in the linuxrc file now.  Can you think of why this would happen?  I had 
added a couple of scripts under init.d, but after this, I took out the 
softlinks in the rc#.d directories, hoping to get back to a clean 
initialization, but it still hangs there.

Confused,
Don
> --- In  "lucho_ortega" <lortega@> wrote:
> >
> > 
> > I have tried to boot to an SD Card for a while and was not totally
> > satisfied with the results. At first I was booting to TS-Linux and that
> > chroot'ing to an USB drive. Of course having a TS-7260 with an SD Card
> > option my goal was to boot from this device. Just for the record, I
> > bought a 4 GB SD card. At first I had issues trying to copy the file
> > system to it by dd'ing one of the TS-7300 images available. I do not
> > know if this is really a solution but I ran mke2fs with the -c option.
> > This process took several hours to complete but after that I was able to
> > create the file system. Of course I had to use fdisk to adjust the
> > partition size and also had to extend the partition as explained
> > somewhere in the wiki.
> > 
> > One I had the file system with the Sarge distribution I followed the
> > instruction from the wiki on booting to an SD card on a TS-7260.
> > Unfortunately I could not get it to boot without having to do a force
> > fsck in every reboot. I would get different time span forcing the
> > reboot, depending on which kernel image I would use to boot. I am not
> > sure why this happened but it did.
> > 
> > I decided to understand what the intermediate file system in initrd did
> > and the whole secret resides in the linuxrc script. It is a very simple
> > script that pivot_root's to the Debian file system that is located in
> > partition 3.
> > 
> > I thought about the process recommended to boot to this image in
> > partition 3 and came to the conclusion that, first I do not need to
> > change the kernel the TS-7260 comes with. Second, I do not need to load
> > to flash that intermediate file system containing the linuxrc script.
> > 
> > What I did was a minor change to the redboot script and placed the the
> > linuxrc script in the on-board file system.
> > 
> > the script for redboot is as follows:
> > 
> > fis load vmlinux
> > exec -c "console=ttyAM0,115200 root=/dev/mtdblock1 init=/root/linuxrc
> > rw"
> > 
> > 
> > As you can see the change is at the end of the regular exec line, where
> > I added the init and rw parameters. I placed the linuxrc script in
> > /root.
> > 
> > #!/bin/sh
> > 
> > # I added real time clock time transfer to system
> > hwclock -s
> > 
> > cd /
> > mount -t proc proc /proc
> > insmod -f sdcard.o -o sdcard0 dmaenable=1 #>/dev/null 2>&1
> > mount /dev/sdcard0/disc0/part3 /mnt #>/dev/null 2>&1
> > cd /mnt
> > pivot_root . tmp
> > /bin/umount tmp/proc
> > /bin/mount -n --move tmp/dev /dev
> > /bin/mount -t proc proc /proc
> > exec /usr/sbin/chroot . /bin/sh <<- EOF
> >    /bin/umount tmp
> >    exec /sbin/init
> > EOF
> > 
> > 
> > I did a minor addition as you may see above and that was to add the
> > setting of the system clock from the real time clock I have on my board.
> > Before adding this line I was getting the following as the file system
> > was mounted ( I am not sure about the reason):
> > 
> > /dev/sdcard0/disc0/part3 has gone 13590 days without being checked,
> > check forced.
> > 
> > I do not get that anymore.
> > 
> > I still have the original kernel and the original file system. Should I
> > find the need to boot to it I would interrupt redboot and change the
> > exec command not to use the init=/root/linuxrc parameter. Things could
> > not get any simpler.
> > 
> > For whatever it is worth there you have it. I hope it is useful to
> > someone else. Thinking about it I could have placed the file system on
> > partition 1 but with a 4 GB SD card it is not worth the effort.
> >
>




------------------------------------

Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/ts-7000/

<*> Your email settings:
    Individual Email | Traditional

<*> To change settings online go to:
    http://groups.yahoo.com/group/ts-7000/join
    (Yahoo! ID required)

<*> To change settings via email:
     
    

<*> To unsubscribe from this group, send an email to:
    

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/

<Prev in Thread] Current Thread [Next in Thread>
Admin

Disclaimer: Neither Andrew Taylor nor the University of NSW School of Computer and Engineering take any responsibility for the contents of this archive. It is purely a compilation of material sent by many people to the birding-aus mailing list. It has not been checked for accuracy nor its content verified in any way. If you wish to get material removed from the archive or have other queries about the archive e-mail Andrew Taylor at this address: andrewt@cse.unsw.EDU.AU