Quantcast
Channel: Debian on NSA325 V1/V2
Viewing all 359 articles
Browse latest View live

Re: NSA 325 V2 Debian Is Possible!

$
0
0
Can you tell me what's wrong? This is my usb with ext2 boot and ext4 rootfs which worked under the old mtd0.
I plugged it into usb 1.
The commands are identical to the one from bobafetthotmail except that I used them from u-boot with setenv instead of fw_setenv.
root@ubuntu-dell:/home/dieter# fdisk -l /dev/sde

Platte /dev/sde: 4184 MByte, 4184342528 Byte
129 Köpfe, 62 Sektoren/Spur, 1021 Zylinder, zusammen 8172544 Sektoren
Einheiten = Sektoren von 1 × 512 = 512 Bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Festplattenidentifikation: 0x0004a9a8

   Gerät  boot.     Anfang        Ende     Blöcke   Id  System
/dev/sde1            2048      206847      102400   83  Linux
/dev/sde2          206848     8171519     3982336   83  Linux
root@ubuntu-dell:/home/dieter# mount | grep sde
/dev/sde1 on /media/dieter/b3d3c5f6-2879-4e20-b1fc-d17a2dd8ff54 type ext2 (rw,nosuid,nodev,uhelper=udisks2)
/dev/sde2 on /media/dieter/rootfs type ext4 (rw,nosuid,nodev,uhelper=udisks2)
root@ubuntu-dell:/home/dieter# 

Re: NSA 325 V2 Debian Is Possible!

$
0
0
I see no error here, let's look again at your U-Boot env:

you don't need a special bootcmd line for each USB port because they are all recognized.
$(loadaddr) points to???

please use it directly as done for loading uInitrd.

ext2load usb 0:1 0x800000 /uImage
ext2load usb 0:1 0x1100000 /uInitrd
bootm 0x800000 0x1100000

Re: NSA 325 V2 Debian Is Possible!

$
0
0
@edinger,

> @bodhi: how can I restore old mtd0 when I cannot
> boot into any system (stock or linux). I tried to
> create one single ext3 usb stick with 8GB, but it
> didn't boot either.

Let's recap the problem and see if there is a simple fix that get you boot into Debian:

- Create the 3.18.5 rootfs on a single Ext3 partition on USB drive. I think you've done this?

- Boot with serial console and interrupt it,
printenv
and then let it boot all the way
boot

- How far you've got at this point? Please post a serial log for entire session (from u-boot banner to the last thing you see on serial console).

Re: NSA 325 V2 Debian Is Possible!

$
0
0
Here is the log. I created a new usb stick with 3.18.5.

Re: NSA 325 V2 Debian Is Possible!

$
0
0
@edinger,

According to the boot log, you have installed uboot.2014.07-tld-4 for NSA325, but did not flash the default u-boot envs in section B. But instead, your current envs are a mixed of stock u-boot envs and the new u-boot default envs (when you did the saveenv, it saves everything in the u-boot envs memory space).

Quote

B. Flashing default u-boot envs image

This is the tarball in section B:

Quote

uboot.2014.07-tld-2.environment.bodhi.tar

This tarball includes 2 files:

uboot.2014.07-tld-2.environment.img (the default envs image to be flashed) 
uboot.2014.07-tld-2.environment (the content of the default envs in text format)


So, to get it booting with the default envs correctly, we have to correct the current u-boot envs that you have saved. The envs are a mess right now, so it is best to restore the set of default envs by using uEnv.txt loading capability.

1. Copy the default envs in text format to the 3.18.5 rootfs on USB. Assuming the USB rootfs is mounted on another Linux box as /media/sdb1:

cp -a uboot.2014.07-tld-2.environment /media/sdb1/boot/uEnv.txt
sync

2. Plug the USB rootfs into the NSA325 and power up, interrupt serial console. At the prompt:

run bootcmd_uenv
setenv arcNumber 4495
setenv machid


3. At this point your current u-boot envs are set to a correct set of u-boot envs to boot the USB rootfs if it is on a single Ext2 or Ext3 partition. So do not save envs. Go ahead and boot

boot

If it does not boot all the way into Debian successfully, please post tthe entire serial console log.

If you've booted into Debian, you can either flash the default envs, using instruction in section B. Or you can reboot, interrupt serial console, and do the uEnv.txt loading steps above again, and then do a saveenv before boot:
saveenv
boot

There are more adjustment needed regarding mtparts, ipaddress, serverip (see instruction in the u-boot installation section B). But they can be adjusted in Debian,

Re: NSA 325 V2 Debian Is Possible!

$
0
0
Hi,

it gets better...but complained about wrong machid, so I changed these values directly in uEnv.txt.
I assume uEnv.txt will be read during boot, so I changed some values:
root@ubuntu-dell:/media/dieter# diff /media/dieter/rootfs/boot/uEnv.txt uboot.2014.07-tld-2.environment
1,2c1,2
< arcNumber=4495
< machid=
---
> arcNumber=2097
> machid=0x831
Now at least it finds kernel and ramdisk, but stucks on booting:
USB0:   USB EHCI 1.00
scanning bus 0 for devices... 3 USB Device(s) found
       scanning usb for storage devices... 1 Storage Device(s) found
2865664 bytes read in 651 ms (4.2 MiB/s)
6535284 bytes read in 556 ms (11.2 MiB/s)
## Booting kernel from Legacy Image at 00800000 ...
   Image Name:   Linux-3.18.5-kirkwood-tld-1
   Created:      2015-02-08   9:02:01 UTC
   Image Type:   ARM Linux Kernel Image (uncompressed)
   Data Size:    2865600 Bytes = 2.7 MiB
   Load Address: 00008000
   Entry Point:  00008000
   Verifying Checksum ... OK
## Loading init Ramdisk from Legacy Image at 01100000 ...
   Image Name:   initramfs-3.18.5-kirkwood-tld-1
   Created:      2015-02-19   1:49:36 UTC
   Image Type:   ARM Linux RAMDisk Image (gzip compressed)
   Data Size:    6535220 Bytes = 6.2 MiB
   Load Address: 00000000
   Entry Point:  00000000
   Verifying Checksum ... OK
   Loading Kernel Image ... OK

Starting kernel ...

Uncompressing Linux... done, booting the kernel.

Error: unrecognized/unsupported machine ID (r1 = 0x0000118f).

Available machine support:

ID (hex)        NAME
ffffffff        Generic DT based system
ffffffff        Marvell Kirkwood (Flattened Device Tree)

Please check your kernel config and/or bootloader.
Maybe it's related to the fact that I just unpacked the 3.18.5 package to the usb stick as I have no running system on NSA325 to create the correct kernel with your descriptions

Re: NSA 325 V2 Debian Is Possible!

$
0
0
edinger,

> Maybe it's related to the fact that I just
> unpacked the 3.18.5 package to the usb stick as I
> have no running system on NSA325 to create the
> correct kernel with your descriptions

Right on! the rootfs can not be used to boot with your current default envs. It nees the DTB appended, as described in the installation instruction.

Quote

4. Create uImage with embbeded DTB (If this is not first time installation, please see Note 2 below).

I'm using the GoFlex Net booting with USB drive as an example here. Please replace its name (kirkwood-goflexnet.dtb) with the box you are installing on (for example, kirkwood-pogo_e02.dtb). Look inside /media/sdb1/boot/dts/ for the correct DTB file name for your box.

cd /media/sdb1/boot
cp -a zImage-3.18.5-kirkwood-tld-1 zImage.fdt
cat dts/kirkwood-goflexnet.dtb >> zImage.fdt
mv uImage uImage.orig
mkimage -A arm -O linux -T kernel -C none -a 0x00008000 -e 0x00008000 -n Linux-3.18.5-kirkwood-tld-1 -d zImage.fdt uImage
sync

You can use any Linux box to create the appended uImage. If mkimage is not installed on that box, then install it:
apt-get install mkimage

and adjust the above instruction (use the kirkwood-nsa325.dtb to append it):
cat dts/kirkwood-nsa325.dtb >> zImage.fdt

Or you can download this uImage I've just created for ziggy on the other thread:
http://forum.doozan.com/read.php?2,23536,23553#msg-23553

Re: NSA 325 V2 Debian Is Possible!

$
0
0
Thanks a lot.
It works now. I wrote your environment-variables again after booting into debian + adjusting mdtpart and hwaddr values and renamed the uEnv.txt file.

What do I have to change now to run a usb stick with 2 partitions (boot and rootfs) - possibly rootfs with ext4?

Re: NSA 325 V2 Debian Is Possible!

$
0
0
edinger,

> What do I have to change now to run a usb stick
> with 2 partitions (boot and rootfs) - possibly
> rootfs with ext4?

See this thread:
http://forum.doozan.com/read.php?3,19093

In summary, if you intend to plug in more than one USB or SATA drives, or having multiple partitions on a drive, you need do both sections A and B.

With the new u-boot, you can use Ext4 for the kernel and rootfs. There is no need to have /boot in a different partition to get around the old u-boot limitation (if that's reason why you want to use a different partition).

Re: NSA 325 V2 Debian Is Possible!

$
0
0
Hi davidedg,

i've have hdparmed all three devices

/dev/sdc:
 Timing cached reads:   578 MB in  2.01 seconds = 287.89 MB/sec
 Timing buffered disk reads: 228 MB in  3.01 seconds =  75.72 MB/sec
root@datacenter:~# hdparm -tT /dev/sdb
=> USB3

/dev/sdb:
 Timing cached reads:   602 MB in  2.00 seconds = 300.74 MB/sec
 Timing buffered disk reads: 428 MB in  3.00 seconds = 142.50 MB/sec
root@datacenter:~# hdparm -tT /dev/sda
=> 4TB HDD

/dev/sda:
 Timing cached reads:   596 MB in  2.00 seconds = 297.80 MB/sec
 Timing buffered disk reads: 462 MB in  3.01 seconds = 153.40 MB/sec
=> 128GB SSD

Now copy data (tried >4GB mkv) fromt the HDD to the USB3 Device and M(idnight)C(ommander) shows me only speed up to 1,5mb/s.

Anything i can check?

Re: NSA 325 V2 Debian Is Possible!

$
0
0
addy75,

> Now copy data (tried >4GB mkv) fromt the HDD to
> the USB3 Device and M(idnight)C(ommander) shows me
> only speed up to 1,5mb/s.
>
> Anything i can check?

What file systems are on these disks? (ext2,3,4,ntfs,...) they are relevant.

Re: NSA 325 V2 Debian Is Possible!

$
0
0
Hi bodhi,

FS on the internal disks (SSD / HDD) ist ext4, USB3 HDD is ntfs.
Datatransfer via network is about 30mb/s

Re: NSA 325 V2 Debian Is Possible!

$
0
0
addy75 Wrote:
-------------------------------------------------------

> FS on the internal disks (SSD / HDD) ist ext4, USB3 HDD is ntfs.

I'd point to this first - try with another format
For example - you may attach the ntfs disk to Windows7+ and shrink it a little bit to carve out space for another partition, which you will format in ext4 on the NAS and try again the tests.
If it is still slow, then it may be related to usb3 (or even not, since hdparm is fast), otherwise it's more likely the ntfs linux driver (btw, which one are you using?)

Re: NSA 325 V2 Debian Is Possible!

$
0
0
I've installed NTFS-3G.

I hope i've configured it the right way ^-^

Re: NSA 325 V2 Debian Is Possible!

$
0
0
Yes :) I agree with davidedg, it is suspected that NTFS is the cause. Please get output of
mount

And as davidedg said, try Ext3 or Ext4 first on USB 3.0 drive.

Re: NSA 325 V2 Debian Is Possible!

$
0
0
Guys, how may I switch off or dim leds on the front?
Is this possible?

Re: NSA 325 V2 Debian Is Possible!

$
0
0
See the content:

cat /sys/class/leds/nsa325\:green\:sys/trigger
none kbd-scrollock kbd-numlock kbd-capslock kbd-kanalock kbd-shiftlock kbd-altgrlock kbd-ctrllock kbd-altlock kbd-shiftllock kbd-shiftrlock kbd-ctrlllock kbd-ctrlrlock nand-disk usb-gadget usb-host timer oneshot ide-disk1 ide-disk2 heartbeat gpio [default-on]

Turn off
echo none > /sys/class/leds/nsa325\:green\:sys/trigger

Turn on
echo default-on > /sys/class/leds/nsa325\:green\:sys/trigger

Re: NSA 325 V2 Debian Is Possible!

$
0
0
Can I go from uboot 2014.07 to stock uboot 1.1.4?

Re: NSA 325 V2 Debian Is Possible!

$
0
0
cratsil1979 Wrote:
-------------------------------------------------------
> Can I go from uboot 2014.07 to stock uboot 1.1.4?

See answer below.

Re: NSA 325 V2 Debian Is Possible!

$
0
0
I don't have any mtd0 backup file to write back to NAND. Can i download it?
Viewing all 359 articles
Browse latest View live




Latest Images