Network Space vs2 lite - Debian Install

Network Space vs2 lite - Debian Install

Postby mikesmth » Tue Jun 04, 2013 7:40 pm

Hi All,

I'm eagerly trying to get debian on my Lacie nwsp2-lite running natively, but up until now without success.

I followed this article's instructions:
http://lacie-nas.org/doku.php?id=debian_install

I managed to get u-Boot updated:

ns2> version

U-Boot 2011.12-00260-ga24d58e (Feb 17 2012 - 15:46:42) NS v2 Lite
arm-marvell-linux-uclibcgnueabi-gcc (crosstool-NG 1.13.2) 4.6.2 20111004 (prerelease)
GNU ld (crosstool-NG 1.13.2) 2.21.53.20110922

I updated the U-Boot environment as instructed.

I can boot with the files found at :

ftp://lacie-nas.org/debian-installer/network-installer/

after compiling the uInitrd with the preseed.cfg as instructed, I put the files uInitrd and uImage on a USB stick

ns2> fatload usb 0:1 0x800000 uImage
reading uImage

1599360 bytes read
ns2> fatload usb 0:1 0x1200000 uInitrd
reading uInitrd

5114741 bytes read
ns2> bootm 0x800000 0x1200000
## Booting kernel from Legacy Image at 00800000 ...
Image Name: Debian kernel
Image Type: ARM Linux Kernel Image (uncompressed)
Data Size: 1599296 Bytes = 1.5 MiB
Load Address: 00008000
Entry Point: 00008000
Verifying Checksum ... OK
## Loading init Ramdisk from Legacy Image at 01200000 ...
Image Name: ramdisk with preseed.cfg
Image Type: ARM Linux RAMDisk Image (gzip compressed)
Data Size: 5114677 Bytes = 4.9 MiB
Load Address: 00000000
Entry Point: 00000000
Verifying Checksum ... OK
Loading Kernel Image ... OK
OK

Starting kernel ..

And then it hangs and is unfindable with a network scan....

Anyone any suggestions?
mikesmth
 
Posts: 18
Joined: Tue Oct 11, 2011 6:46 pm
Location: Netherlands

Re: Network Space vs2 lite - Debian Install

Postby fvdw » Tue Jun 04, 2013 9:07 pm

I assume you use u-boot to boot the kernel
Then you could try to enble netconsole output by setting environment variables for that
This only works if the kernel you boot has netconsole support set in the configuration

in u-boot enter
Code: Select all
setenv ipaddr ${ipaddr}
setenv serverip ${serverip}
setenv bootargs console=ttyS0,115200 netconsole=6666@${ipaddr}/,6666@${serverip}/


ps probably you also must add the "root=/dev/sdx" to the boot arguments line otherwise the kernel doesn't know were to find the root file system, but I am not sure about this , never used debian ;)

If your kernel supports netconsole then you should get output in u-boot terminal after booting the kernel and message starting kernel and might be able to see were it halts
fvdw
Site Admin - expert
 
Posts: 13471
Joined: Tue Apr 12, 2011 2:30 pm
Location: Netherlands

Re: Network Space vs2 lite - Debian Install

Postby mikesmth » Wed Jun 05, 2013 5:23 am

Thanx!
Changed the env vars. I booted by hand before from u-boot.
Now tried booting directly after reset by setting env to:


autoload=no
baudrate=115200
bootargs=console=ttyS0,115200 root=/dev/sda1 ro reset=0 productType=ASTON_KW
bootcmd=dhcp && run netconsole; if run usbload || run diskload; then bootm 0x800000 0x1200000; fi
bootdelay=3
bootfile=uImage
diskload=ide reset && ext2load ide 0:1 0x800000 uImage && ext2load ide 0:1 0x1200000 uInitrd
dnsip=192.168.179.1
ethact=egiga0
ethaddr=00:d0:4b:90:43:b1
filesize=186780
gatewayip=192.168.179.1
ipaddr=192.168.179.39
loadaddr=0x800000
netconsole=6666@192.168.179.39/,6666@192.168.179.1/
netmask=255.255.255.0
serverip=192.168.179.1
stderr=serial,nc,nc,nc,nc,nc
stdin=serial,nc,nc,nc,nc,nc
stdout=serial,nc,nc,nc,nc,nc
usbload=usb start && fatload usb 0:1 0x800000 uImage

Somehow my bootimage got currupted...

BOOTP broadcast 1
*** Unhandled DHCP Option in OFFER/ACK: 28
*** Unhandled DHCP Option in OFFER/ACK: 42
*** Unhandled DHCP Option in OFFER/ACK: 28
*** Unhandled DHCP Option in OFFER/ACK: 42
DHCP client bound to address 192.168.179.39
Unknown command '6666@192.168.179.39/,6666@192.168.179.1/' - try 'help'
(Re)start USB...
USB: Register 10011 NbrPorts 1
USB EHCI 1.00
scanning bus for devices... 2 USB Device(s) found
scanning bus for storage devices... 1 Storage Device(s) found
reading uImage

1599360 bytes read
## Booting kernel from Legacy Image at 00800000 ...
Image Name: Debian kernel
Image Type: ARM Linux Kernel Image (uncompressed)
Data Size: 1599296 Bytes = 1.5 MiB
Load Address: 00008000
Entry Point: 00008000
Verifying Checksum ... OK
## Loading init Ramdisk from Legacy Image at 01200000 ...
Image Name: ramdisk with preseed.cfg
Image Type: ARM Linux RAMDisk Image (gzip compressed)
Data Size: 5114677 Bytes = 4.9 MiB
Load Address: 00000000
Entry Point: 00000000
Verifying Checksum ... Bad Data CRC
Ramdisk image is corrupt or invalid

I'll continue tonight... t.b.c.
mikesmth
 
Posts: 18
Joined: Tue Oct 11, 2011 6:46 pm
Location: Netherlands

Re: Network Space vs2 lite - Debian Install

Postby fvdw » Wed Jun 05, 2013 6:49 am

Code: Select all
Unknown command '6666@192.168.179.39/,6666@192.168.179.1/' - try 'help'


this means you did not set the command right do, not file in the ip addresses just use what I posted to set netconsole
Code: Select all
setenv ipaddr ${ipaddr}
setenv serverip ${serverip}
setenv bootargs console=ttyS0,115200 netconsole=6666@${ipaddr}/,6666@${serverip}/

so leave ${ipaddr} and ${serverip} unchanged

Also tou should pass the boor args to the kernel otherwise it doesn't know it must start netconsole
Now your boot arguments passed to the kernel are
Code: Select all
bootargs=console=ttyS0,115200 root=/dev/sda1 ro reset=0 productType=ASTON_KW

this should become
Code: Select all
bootargs=console=ttyS0,115200  netconsole=6666@${ipaddr}/,6666@${serverip}/ root=/dev/sda1 ro reset=0 productType=ASTON_KW

This can be accomplished by using this command
Code: Select all
setenv bootargs console=ttyS0,115200  netconsole=6666@${ipaddr}/,6666@${serverip}/ root=/dev/sda1 ro reset=0 productType=ASTON_KW

At least that is what I think
fvdw
Site Admin - expert
 
Posts: 13471
Joined: Tue Apr 12, 2011 2:30 pm
Location: Netherlands

Re: Network Space vs2 lite - Debian Install

Postby mikesmth » Wed Jun 05, 2013 12:13 pm

Yes seen that too. Needs to be

Code: Select all
setenv bootargs 'console=ttyS0,115200  netconsole=6666@${ipaddr}/,6666@${serverip}/ root=/dev/sda1 ro reset=0 productType=ASTON_KW'


if I don't enclose them, the parameters get resolved to hardcode

Around 7pm (GMT+1) I'll get home and try again.
mikesmth
 
Posts: 18
Joined: Tue Oct 11, 2011 6:46 pm
Location: Netherlands

Re: Network Space vs2 lite - Debian Install

Postby mikesmth » Wed Jun 05, 2013 6:48 pm

Tried again... no success

autoload=no
baudrate=115200
bootargs=console=ttyS0,115200 netconsole=6666@192.168.179.39/,6666@192.168.179.24/ root=/dev/sda1 ro reset=0 productType=ASTON_KW
bootcmd=dhcp && run netconsole; if run usbload || run diskload; then bootm 0x800000 0x1200000; fi
bootdelay=10
bootfile=uImage
diskload=ide reset && ext2load ide 0:1 0x800000 uImage && ext2load ide 0:1 0x1200000 uInitrd
dnsip=192.168.179.1
ethact=egiga0
ethaddr=00:d0:4b:90:43:b1
filesize=186780
gatewayip=192.168.179.1
ipaddr=192.168.179.39
loadaddr=0x800000
nc=setenv stdout nc;setenv stdin nc
ncip=192.168.179.24
netconsole=set stdin $stdin,nc; set stdout $stdout,nc; set stderr $stderr,nc;
netmask=255.255.255.0
serverip=192.168.179.1
stderr=serial,nc,nc,nc,nc,nc,nc,nc
stdin=nc,nc,nc
stdout=nc,nc,nc
usbload= usb start && fatload usb 0:1 0x800000 uImage && fatload usb 0:1 0x1200000 uInitrd

ns2> set serverip 192.168.179.24
ns2> boot
BOOTP broadcast 1
*** Unhandled DHCP Option in OFFER/ACK: 28
*** Unhandled DHCP Option in OFFER/ACK: 42
*** Unhandled DHCP Option in OFFER/ACK: 28
*** Unhandled DHCP Option in OFFER/ACK: 42
DHCP client bound to address 192.168.179.39
(Re)start USB...
USB: Register 10011 NbrPorts 1
USB EHCI 1.00
scanning bus for devices... 1 USB Device(s) found
scanning bus for storage devices... 0 Storage Device(s) found

** Invalid boot device **

Reset IDE: Bus 0: OK
Device 0: Model: WDC WD25EZRS-00J99B0 Firm: 80.00A80 Ser#: WD-WCAWZ0117698
Type: Hard Disk
Supports 48-bit addressing
Capacity: 287506.7 MB = 280.7 GB (588813872 x 512)
Loading file "uImage" from ide device 0:1 (hda1)
1599360 bytes read
Loading file "uInitrd" from ide device 0:1 (hda1)
5114741 bytes read
## Booting kernel from Legacy Image at 00800000 ...
Image Name: Debian kernel
Image Type: ARM Linux Kernel Image (uncompressed)
Data Size: 1599296 Bytes = 1.5 MiB
Load Address: 00008000
Entry Point: 00008000
Verifying Checksum ... OK
## Loading init Ramdisk from Legacy Image at 01200000 ...
Image Name: ramdisk with preseed.cfg
Image Type: ARM Linux RAMDisk Image (gzip compressed)
Data Size: 5114677 Bytes = 4.9 MiB
Load Address: 00000000
Entry Point: 00000000
Verifying Checksum ... OK
Loading Kernel Image ... OK
OK

Starting kernel ...

I can't imagine the kernel would not support netconsole booting.....

Seems like the same probs you had starting with differencing nwsp V2 and the lite board... we had the same problem, kind of. hanging boot process....

Can't put a finger on the problem....

There are other posts on other forums using the original Lacie u-boot.
However, I did overwrite that, so if anyone can provide my a copy of the u-boot (nwsp2-lite) I would be thankful at least.
mikesmth
 
Posts: 18
Joined: Tue Oct 11, 2011 6:46 pm
Location: Netherlands

Re: Network Space vs2 lite - Debian Install

Postby fvdw » Wed Jun 05, 2013 10:40 pm

I have the original u-boot of the nwsp2-lite. I attached it for you.
PS no guarantees are given use at own risk.

The debian kernel should have the marvel sata driver enabled in the kernel. That was in that time the problem when we migrated to 2.6.39.4
However it then still should give some output on the netconsole when loading the kernel, it only will not find a disk.
It looks like the kernel is hanging very early in the boot process. Does the u-boot loader uses the correct mach number for the debian kernel? (or is this not needed in case of debian kernel ??)
You do not have the required permissions to view the files attached to this post.
fvdw
Site Admin - expert
 
Posts: 13471
Joined: Tue Apr 12, 2011 2:30 pm
Location: Netherlands

Re: Network Space vs2 lite - Debian Install

Postby mikesmth » Thu Jun 06, 2013 4:44 pm

Oops...

Saving Currupted Environment to SPI Flash...
SF: Detected eligable MX25L4005 with page size 64 KiB, total 512 KiB
Erasing SPI flash...Corrupting SPI flash...done bricking

Bricked!

I guess I will not spend time on JTAGging the old box.

At least I tried.
The plan was to build a surveillance system for my raspberry pi HD streaming camera servers (as a substitute for the more expensive surveillance camera's ;-) )
I was planning for a zoneminder install on my Lacie, as I recently upgraded to a Synology DS1812.

Zoneminder is not installable on the syno, because it used older MySQL libraries which interfere with other programs present.
For that reason I tried to get zoneminder to work on the Lacie nwsp2-lite.
I guess I will buy a NSA320 to do the job. They're relatively cheap these days, and easy to install with debian.
See http://archlinuxarm.org/platforms/armv5/zyxel-nsa320
mikesmth
 
Posts: 18
Joined: Tue Oct 11, 2011 6:46 pm
Location: Netherlands

Re: Network Space vs2 lite - Debian Install

Postby fvdw » Thu Jun 06, 2013 6:24 pm

:disapprove what a waste.

Saving Currupted Environment to SPI Flash...
SF: Detected eligable MX25L4005 with page size 64 KiB, total 512 KiB
Erasing SPI flash...Corrupting SPI flash...done bricking


Is this the real output form flashing process ? Never seen this. Why would it brick itself ?

How did you write the image to flash ? I assume you use mainline u-boot and tried to rewrite the nwsp-lite flash from lacie
I have written it more then 100 times the the flash and it never failed but I always used the u-boot sorce code from lacie and the bubt command.
This could be a learning point for others that writing to the flash using mainline u-boot is a risk...
fvdw
Site Admin - expert
 
Posts: 13471
Joined: Tue Apr 12, 2011 2:30 pm
Location: Netherlands

Re: Network Space vs2 lite - Debian Install

Postby mikesmth » Sat Jun 08, 2013 11:58 am

Couldn't recognise the joke? ;-)

Couldn't resist to figure out possibilities for reprogramming the box using JTAG.
I've seen a multipurpose jumper on the board which most probably has the same pinout as described here
http://lacie.nas-central.org/wiki/NetworkSpace:_Serial_Port_Access
So I ordered a JTAG cable (20 to 6 pin) for use with my RiffBox. That should enable me to resurrect the box, just because I can ;-)

I will keep you informed on the progress... Once I'm able to reflash I'll continue on the Debian-on-nwsp2-lite project.

Thanks for your time and effort.
mikesmth
 
Posts: 18
Joined: Tue Oct 11, 2011 6:46 pm
Location: Netherlands


Return to Development

Who is online

Users browsing this forum: Majestic-12 [Bot] and 8 guests