Debian on GoFlex net - any full noob how to?

This forum is for Marvell Kirkwood devices such as the GoFlex Home/Net, PogoPlug v1/v2, SheevaPlug, and ZyXEL devices.

Re: Debian on GoFlex net - any full noob how to?

Postby crimsonredmk » Sun Feb 20, 2011 9:20 pm

You can't SSH in? The LED might be off, but the system is really booted. What do you see in the console after loading the kernel?
Remember, Arch Linux ARM is completely donation-supported, and is totally awesome.
crimsonredmk
Site Admin
 
Posts: 433
Joined: Wed Dec 30, 2009 5:17 pm
Location: #archlinux-arm on irc.freenode.net

Re: Debian on GoFlex net - any full noob how to?

Postby squeezeplug » Sun Feb 20, 2011 10:30 pm

Admin wrote:You can't SSH in? The LED might be off, but the system is really booted. What do you see in the console after loading the kernel?

I'm not sure if this post belongs to my questions, I'll answer anyway!
I have a straight green LED and it seems the system is running. I can't see an DHCP request. So I edited the interfaces file for a static IP but that also don't work. with Arch Linux ARM install Linux from the NAND everything works fine. With a Debian USB-Stick I don't get an IP-Connection. I tried different methods to create the stick but none of them works! I've posted my output from netconsole a few posts before!

Thx for your help
Greetings Thomas
squeezeplug
 
Posts: 27
Joined: Thu Feb 17, 2011 6:42 am

Re: Debian on GoFlex net - any full noob how to?

Postby peaslaker » Sun Feb 20, 2011 10:53 pm

Code: Select all
## Booting kernel from Legacy Image at 00680000 ...
   Image Name:   Linux-2.6.36-ubit-01575-gd36fea8
   Image Type:   ARM Linux Kernel Image (uncompressed)
   Data Size:    2895700 Bytes = 2.8 MiB
   Load Address: 00008000
   Entry Point:  00008000
   Verifying Checksum ... OK
## Loading init Ramdisk from Legacy Image at 01100000 ...
   Image Name:   initramfs-2.6.32-5-kirkwood
   Image Type:   ARM Linux RAMDisk Image (gzip compressed)
   Data Size:    4736713 Bytes = 4.5 MiB
   Load Address: 00000000
   Entry Point:  00000000
   Verifying Checksum ... OK
   Loading Kernel Image ... OK
OK


Code: Select all
console=ttyS0,115200 mtdparts=orion_nand:1M(u-boot),4M(uImage),32M(pogoplug),-(root) root=/dev/sda1 rootdelay=10 netconsole=@10.10.10.6/eth0,@10.10.10.4/


The kernel boots. It starts the ramdisk by running the '/init' script. I don't know what else to say having not tried it myself but the documentation and code for that ramdisk are part of the Debian project and there is limited expertise (apart from fellow enthusiasts) here. Unpack the ramdisk and look at what 'init' does. The kernel gets passed root=/dev/sda1 which will be correct for your USB stick right up until you have SATA disks plugged in at which point the SATA system will take /dev/sda and /dev/sdb for itself and the USB will be bumped to /dev/sdc (or /dev/sdb with a single SATA disk in the right hand slot). What that means is that the root= specification could be wrong.

I'm clutching at straws. Netconsole just shows us that the kernel is booting. Apparently it doesn't panic, so the machine is probably sitting waiting for a login somewhere. Running a ramdisk provided by Debian on a platform that isn't supported by Debian isn't really a promise. Initial ramdisks usually just exist to mount a root partition. Without documentation of their behaviour you have no idea of what they attempt to achieve. You get Debian running *after* the ramdisk has finished up and handed control to the root filesystem. Perhaps the ramdisk is a complete distraction in this situation.

If you had a serial console you'd have more idea what is going on. This is pioneering stuff and you should expect a few bumps on the road.
peaslaker
 
Posts: 101
Joined: Tue Sep 07, 2010 10:40 pm

Re: Debian on GoFlex net - any full noob how to?

Postby JohnH » Mon Feb 21, 2011 8:14 am

Just want to add that I have been in contact with Thomas and I have given him a dump of the image I have created on my USB stick (a debian system), basically done by following this thread and http://Arch Linux ARM.com/index.php5?title=Ru ... and_kernel

I am perfectly able to boot my stick with this image, but Thomas seems not to be able?

One of the differences is that I am running UBIT v 0.4 whereas Thomas is running the newer v. 0.5. Could that mean anything?
JohnH
 
Posts: 9
Joined: Tue Jan 25, 2011 7:01 pm

Re: Debian on GoFlex net - any full noob how to?

Postby squeezeplug » Mon Feb 21, 2011 4:58 pm

JohnH wrote:Just want to add that I have been in contact with Thomas and I have given him a dump of the image I have created on my USB stick (a debian system), basically done by following this thread and http://Arch Linux ARM.com/index.php5?title=Ru ... and_kernel

I am perfectly able to boot my stick with this image, but Thomas seems not to be able?

One of the differences is that I am running UBIT v 0.4 whereas Thomas is running the newer v. 0.5. Could that mean anything?


Hi John,
you are right, thx for this post. I tried my own installation, your image and another setup with bootstrap. None of them works! Strait green LED but no IP-Address. So I have really no idea whats going wrong. I'll try to install PluboxLinux on USB later to see if this works for me.

Greetings,
Thomas
squeezeplug
 
Posts: 27
Joined: Thu Feb 17, 2011 6:42 am

Re: Debian on GoFlex net - any full noob how to?

Postby peaslaker » Mon Feb 21, 2011 5:03 pm

I'm looking into this to see how the guidance can be updated for versions of UBIT later than 0.4.

Don't get hung up on the LED having any significant meaning. It may, for instance, have been programmed as the default setting for the kernel, which merely means that the kernel sets it at start up. It has no bearing on whether the system remains sensibly operational and the system may even have panicked and still be showing an LED.
peaslaker
 
Posts: 101
Joined: Tue Sep 07, 2010 10:40 pm

Re: Debian on GoFlex net - any full noob how to?

Postby JohnH » Mon Feb 21, 2011 5:07 pm

If you want to have a go at the debian image that I have which is working perfectly for my USB stick in a version 0.4 UBIT with NAND plug-linux, you can download the image here:

http://dl.dropbox.com/u/21395927/backupDebian.rar
JohnH
 
Posts: 9
Joined: Tue Jan 25, 2011 7:01 pm

Re: Debian on GoFlex net - any full noob how to?

Postby JohnH » Mon Feb 21, 2011 7:38 pm

squeezeplug wrote:Here is the output from netconsole (kernel):

Code: Select all
Linux version 2.6.36-ubit-01575-gd36fea8 (root@vmdebian-cli) (gcc version 4.4.1 (Sourcery G++ Lite 2009q3-67) ) #1 Fri Dec 17 17:43:50 GMT 2010
CPU: Feroceon 88FR131 [56251311] revision 1 (ARMv5TE), cr=00053977
CPU: VIVT data cache, VIVT instruction cache
Machine: Seagate GoFlex Net
Memory policy: ECC disabled, Data cache writeback
Built 1 zonelists in Zone order, mobility grouping on.  Total pages: 32512
Kernel command line: console=ttyS0,115200 mtdparts=orion_nand:1M(u-boot),4M(uImage),32M(pogoplug),-(root) root=/dev/sda1 rootdelay=10 netconsole=@10.10.10.6/eth0,@10.10.10.4/
PID hash table entries: 512 (order: -1, 2048 bytes)
Dentry cache hash table entries: 16384 (order: 4, 65536 bytes)
Inode-cache hash table entries: 8192 (order: 3, 32768 bytes)
Memory: 128MB = 128MB total
Memory: 118848k/118848k available, 12224k reserved, 0K highmem
Virtual kernel memory layout:
    vector  : 0xffff0000 - 0xffff1000   (   4 kB)
    fixmap  : 0xfff00000 - 0xfffe0000   ( 896 kB)
    DMA     : 0xffc00000 - 0xffe00000   (   2 MB)
    vmalloc : 0xc8800000 - 0xfe800000   ( 864 MB)
    lowmem  : 0xc0000000 - 0xc8000000   ( 128 MB)
    modules : 0xbf000000 - 0xc0000000   (  16 MB)
      .init : 0xc0008000 - 0xc002e000   ( 152 kB)
      .text : 0xc002e000 - 0xc052a000   (5104 kB)
      .data : 0xc0550000 - 0xc0585880   ( 215 kB)
SLUB: Genslabs=11, HWalign=32, Order=0-3, MinObjects=0, CPUs=1, Nodes=1
Hierarchical RCU implementation.
    RCU-based detection of stalled CPUs is disabled.
    Verbose stalled-CPUs detection is disabled.
NR_IRQS:114
Console: colour dummy device 80x30
Calibrating delay loop... 1192.75 BogoMIPS (lpj=5963776)
pid_max: default: 32768 minimum: 301
Mount-cache hash table entries: 512
CPU: Testing write buffer coherency: ok
NET: Registered protocol family 16
Kirkwood: MV88F6281-A1, TCLK=200000000.
Feroceon L2: Cache support initialised.
bio: create slab <bio-0> at 0
vgaarb: loaded
SCSI subsystem initialized
usbcore: registered new interface driver usbfs
usbcore: registered new interface driver hub
usbcore: registered new device driver usb
cfg80211: Calling CRDA to update world regulatory domain
Switching to clocksource orion_clocksource
NET: Registered protocol family 2
IP route cache hash table entries: 1024 (order: 0, 4096 bytes)
TCP established hash table entries: 4096 (order: 3, 32768 bytes)
TCP bind hash table entries: 4096 (order: 2, 16384 bytes)
TCP: Hash tables configured (established 4096 bind 4096)
TCP reno registered
UDP hash table entries: 256 (order: 0, 4096 bytes)
UDP-Lite hash table entries: 256 (order: 0, 4096 bytes)
NET: Registered protocol family 1
RPC: Registered udp transport module.
RPC: Registered tcp transport module.
RPC: Registered tcp NFSv4.1 backchannel transport module.
Trying to unpack rootfs image as initramfs...
Freeing initrd memory: 4624K
JFFS2 version 2.2. (NAND) © 2001-2006 Red Hat, Inc.
aufs 2.1-36
msgmni has been set to 241
io scheduler noop registered
io scheduler deadline registered
io scheduler cfq registered (default)
Serial: 8250/16550 driver, 2 ports, IRQ sharing disabled
serial8250.0: ttyS0 at MMIO 0xf1012000 (irq = 33) is a 16550A
console [ttyS0] enabled
brd: module loaded
loop: module loaded
sata_mv sata_mv.0: version 1.28
sata_mv sata_mv.0: slots 32 ports 2
scsi0 : sata_mv
scsi1 : sata_mv
ata1: SATA max UDMA/133 irq 21
ata2: SATA max UDMA/133 irq 21
NAND device: Manufacturer ID: 0x2c, Chip ID: 0xda (Micron NAND 256MiB 3,3V 8-bit)
Scanning device for bad blocks
Bad eraseblock 513 at 0x000004020000
4 cmdlinepart partitions found on MTD device orion_nand
Creating 4 MTD partitions on "orion_nand":
0x000000000000-0x000000100000 : "u-boot"
0x000000100000-0x000000500000 : "uImage"
0x000000500000-0x000002500000 : "pogoplug"
0x000002500000-0x000010000000 : "root"
MV-643xx 10/100/1000 ethernet driver version 1.4
mv643xx_eth smi: probed
net eth0: port 0 with MAC address 00:10:75:26:3d:4e
netconsole: local port 6665
netconsole: local IP 10.10.10.6
netconsole: interface 'eth0'
netconsole: remote port 6666
netconsole: remote IP 10.10.10.4
netconsole: remote ethernet address ff:ff:ff:ff:ff:ff
netconsole: device eth0 not up yet, forcing it
ata1: SATA link down (SStatus 0 SControl F300)
ata2: SATA link down (SStatus 0 SControl F300)
eth0: link up, 1000 Mb/s, full duplex, flow control disabled
console [netcon0] enabled
netconsole: network logging started
ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
orion-ehci orion-ehci.0: Marvell Orion EHCI
orion-ehci orion-ehci.0: new USB bus registered, assigned bus number 1
orion-ehci orion-ehci.0: irq 19, io mem 0xf1050000
orion-ehci orion-ehci.0: USB 2.0 started, EHCI 1.00
hub 1-0:1.0: USB hub found
hub 1-0:1.0: 1 port detected
Initializing USB Mass Storage driver...
usbcore: registered new interface driver usb-storage
USB Mass Storage support registered.
usbcore: registered new interface driver ums-datafab
usbcore: registered new interface driver ums-freecom
usbcore: registered new interface driver ums-jumpshot
usbcore: registered new interface driver ums-sddr09
usbcore: registered new interface driver ums-sddr55
mice: PS/2 mouse device common for all mice
usb 1-1: new high speed USB device using orion-ehci and address 2
scsi2 : usb-storage 1-1:1.0
rtc-mv rtc-mv: internal RTC not ticking
i2c /dev entries driver
cpuidle: using governor ladder
cpuidle: using governor menu
sdhci: Secure Digital Host Controller Interface driver
sdhci: Copyright(c) Pierre Ossman
mv_xor_shared mv_xor_shared.0: Marvell shared XOR driver
mv_xor_shared mv_xor_shared.1: Marvell shared XOR driver
mv_xor mv_xor.0: Marvell XOR: ( xor cpy )
mv_xor mv_xor.1: Marvell XOR: ( xor fill cpy )
mv_xor mv_xor.2: Marvell XOR: ( xor cpy )
mv_xor mv_xor.3: Marvell XOR: ( xor fill cpy )
usbcore: registered new interface driver hiddev
usbcore: registered new interface driver usbhid
usbhid: USB HID core driver
oprofile: hardware counters not available
oprofile: using timer interrupt.
TCP cubic registered
NET: Registered protocol family 17
lib80211: common routines for IEEE802.11 drivers
Registering the dns_resolver key type
registered taskstats version 1
drivers/rtc/hctosys.c: unable to open rtc device (rtc0)
Freeing init memory: 152K
scsi 2:0:0:0: Direct-Access     Kingston DataTraveler 410 1.00 PQ: 0 ANSI: 2
sd 2:0:0:0: [sda] 7571944 512-byte logical blocks: (3.87 GB/3.61 GiB)
sd 2:0:0:0: [sda] Write Protect is off
sd 2:0:0:0: [sda] Assuming drive cache: write through
sd 2:0:0:0: Attached scsi generic sg0 type 0
sd 2:0:0:0: [sda] Assuming drive cache: write through
 sda: sda1 sda2 sda3
sda: p3 size 6273024 extends beyond EOD, enabling native capacity
sd 2:0:0:0: [sda] Assuming drive cache: write through
 sda: sda1 sda2 sda3
sda: p3 size 6273024 extends beyond EOD, truncated
sd 2:0:0:0: [sda] Assuming drive cache: write through
sd 2:0:0:0: [sda] Attached SCSI removable disk


Anyone an idea what's going wrong here?


Looking at the kernel-output, it reminds very much of what tomcheng76 experienced in this viewtopic.php?f=18&t=494&start=10#p3467

It stops at the same place. Also without ssh. The question is what he did to get it to work? :)
JohnH
 
Posts: 9
Joined: Tue Jan 25, 2011 7:01 pm

Re: Debian on GoFlex net - any full noob how to?

Postby peaslaker » Tue Feb 22, 2011 12:35 am

Right. I got bored with this and plugged in my serial console.

The Debian 3.6.32-5-kirkwood kernel doesn't support the GoFlex Net machine ID:
Code: Select all
Available machine support:

ID (hex)        NAME
00000690        Marvell DB-88F6281-BP Development Board
00000691        Marvell RD-88F6192-NAS Development Board
00000692        Marvell RD-88F6281 Reference Board
0000078c        Marvell 88F6281 GTW GE Board
00000a76        Marvell eSATA SheevaPlug Reference Board
00000831        Marvell SheevaPlug Reference Board
00000a63        Marvell GuruPlug Reference Board
0000085b        QNAP TS-119/TS-219
000009c6        QNAP TS-41x
00000bb6        Seagate FreeAgent DockStar
00000b44        Marvell OpenRD Ultimate Board
00000939        Marvell OpenRD Client Board
00000915        Marvell OpenRD Base Board
00000b1e        HP t5325 Thin Client

Please check your kernel config and/or bootloader.


All attempts to boot with the Debian Kernel will fail. So you have to use a UBIT kernel and ramdisk.... which takes a few steps out of the whole process:

First you partition and format just a single ext3 partition for Debian's rootfs. You don't need a separate boot partition, although it makes sense to add a swap partition.

Working on your existing Debian install and presuming your GoFlex Net Debian disk is /dev/sdb1:
Code: Select all
    sudo apt-get install debootstrap
    sudo mount /dev/sdb1 /mnt  # change /dev/sdb1 to the appropriate partition.
    sudo debootstrap --foreign --arch=armel \
        --include=ntp,usbmount,openssh-server \
        squeeze /mnt http://ftp.us.debian.org/debian
    sudo umount /mnt  # with a USB flash drive this will take a long time



Startup your goflex net. Wait for it boot Arch Linux ARM install Linux from NAND. Insert the USB drive, which should mount at /media/usbhd-sda1. Login over ssh and then chroot into the half-finished Debian root filesystem:
Code: Select all
    mount -t proc none /media/usbhd-sda1/proc
    mount -o bind /dev /media/usbhd-sda1/dev
    mount -o bind /.aufs/modules /media/usbhd-sda1/mnt
    chroot /media/usbhd-sda1 /bin/bash



Within the chrooted root filesystem, we run the second half of debootstrap and set up the network interfaces, hostname, Debian mirrors and root password:
Code: Select all
    /debootstrap/debootstrap --second-stage
    echo "goflex" > /etc/hostname
    echo "auto lo" >> /etc/network/interfaces
    echo "iface lo inet loopback" >> /etc/network/interfaces
    echo "auto eth0" >> /etc/network/interfaces
    echo "iface eth0 inet dhcp" >> /etc/network/interfaces
    echo "deb http://ftp.us.debian.org/debian squeeze main" >> /etc/apt/sources.list
    echo "deb-src http://ftp.us.debian.org/debian squeeze main" >> /etc/apt/sources.list
    passwd root  # this requires your input of a new password.



We need to add a copy of the UBIT kernel's modules to the root filesystem:
Code: Select all
# obviously replacing with your actual kernel version
cp -pr /mnt/lib/modules/2.6.xx-ubit-NNNNN-gMMMMMM /lib/modules/
umount /mnt


We need to mark the USB drive as bootable (as far as UBIT is concerned):
Code: Select all
tune2fs -L "rootfs" /dev/sda1



That is it. Working Debian on GoFlex Net.

Code: Select all
exit
reboot
Last edited by peaslaker on Thu Feb 24, 2011 2:07 pm, edited 5 times in total.
peaslaker
 
Posts: 101
Joined: Tue Sep 07, 2010 10:40 pm

Re: Debian on GoFlex net - any full noob how to?

Postby squeezeplug » Tue Feb 22, 2011 11:28 am

peaslaker wrote:...Working on your existing Debian install and presuming your GoFlex Net Debian disk is /dev/sdd1:
Code: Select all
    sudo apt-get install debootstrap
    sudo mount /dev/sdd1 /mnt  # change /dev/sdd1 to the appropriate partition.
    sudo /usr/sbin/debootstrap --foreign --arch=armel \
        --include=ntp,usbmount,openssh-server \
        squeeze /mnt http://ftp.us.debian.org/debian
    sudo umount /mnt
...


Hi peaslaker,
thanks a lot for your help! I'll check this out tonight. I've got one question about this:
Can I use any Debian Installation or even Ubuntu to do this first step?

Greetings,
Thomas
squeezeplug
 
Posts: 27
Joined: Thu Feb 17, 2011 6:42 am

PreviousNext

Return to Marvell Kirkwood

Who is online

Users browsing this forum: Bing [Bot] and 1 guest