Форум обсуждения систем  

Вернуться   Форум обсуждения систем "Умный дом", проектов Ардуино, OpenWRT и других DIY устройств > Форум умного дома > Сделай сам > Linux для начинающих

Ответ
 
Опции темы Поиск в этой теме Опции просмотра
Старый 28.12.2017, 21:15   #11
sakatgg
Senior Member
 
Регистрация: 15.07.2014
Сообщений: 939
Вес репутации: 989
sakatgg is just really nicesakatgg is just really nicesakatgg is just really nicesakatgg is just really nicesakatgg is just really nice
По умолчанию

Система спасения NAS - FANTEC CL-35B2 и Iconbit I-STOR IS608

(CPU PLX NAS7821), взято здесь, автор der_metzger

1. Винт sata подсоединяем к компу с Linux

2. Качаем fantec_CL-35B2_rescue.tar.gz и распаковываем. Заходим под root в папку NAS

3. Запускаем скрипт sh install.sh /dev/sdx , где sdx - винт для NAS. Внимание: sdx перезаписывается полностью!!!

Команда в терминале Linux

Код:
root@runtu:/home/runtu/1/NAS# sh install.sh /dev/sda
[3;J


32+0 записей получено
32+0 записей отправлено
33554432 байт (34 MB, 32 MiB) скопирован, 1,29859 s, 25,8 MB/s
Информация: Не забудьте обновить /etc/fstab.

Информация: Не забудьте обновить /etc/fstab.                              

Модель: ATA ST380815AS (scsi)                                             
Диск /dev/sda: 80,0GB
Размер сектора (логич./физич.): 512B/512B
Таблица разделов: gpt
Флаги диска: 

Номер  Начало  Конец   Размер  Файловая система  Имя      Флаги
 1     33,6MB  8422MB  8389MB                    primary

0+1 записей получено
0+1 записей отправлено
444 байта скопировано, 0,00775193 s, 57,3 kB/s
17+1 записей получено
17+1 записей отправлено
8808 байт (8,8 kB, 8,6 KiB) скопирован, 0,00891646 s, 988 kB/s
254+1 записей получено
254+1 записей отправлено
130372 байт (130 kB, 127 KiB) скопирован, 0,0369692 s, 3,5 MB/s
4218+1 записей получено
4218+1 записей отправлено
2159948 байт (2,2 MB, 2,1 MiB) скопирован, 0,0722225 s, 29,9 MB/s
17+1 записей получено
17+1 записей отправлено
8808 байт (8,8 kB, 8,6 KiB) скопирован, 0,0746092 s, 118 kB/s
254+1 записей получено
254+1 записей отправлено
130372 байт (130 kB, 127 KiB) скопирован, 0,0245399 s, 5,3 MB/s
4218+1 записей получено
4218+1 записей отправлено
2159948 байт (2,2 MB, 2,1 MiB) скопирован, 0,0230659 s, 93,6 MB/s
mke2fs 1.42.13 (17-May-2015)
Creating filesystem with 2048000 4k blocks and 512064 inodes
Filesystem UUID: ce8a992b-dc47-458a-9c8f-b94c7b1d6607
Superblock backups stored on blocks: 
	32768, 98304, 163840, 229376, 294912, 819200, 884736, 1605632

Allocating group tables: done                            
Сохранение таблицы inod'ов: done                            
Creating journal (32768 blocks): готово
Writing superblocks and filesystem accounting information: готово

fertig! Boote deine NAS!
root@runtu:/home/runtu/1/NAS#
[свернуть]

Получиться разметка как на скрине

Первый 32Mb на диске - есть 1st stage bootloader, u-boot, u-boot environment, kernel + initrd.

4. Подключаем винт к NAS, в моем случае Iconbit I-STOR IS608 (клон).
Если смотреть с лицевой панели, то в правый (Slot1) подключать. В другом не стартует.

5. Подключаем к serial port через usb адаптер 3.3В !!! (использую от телефона Siemens MA-8730P, скрин).

6. Запускаем PuTTY скорость 115200 и включаем NAS.

Система стартует с винта сразу, в том числе и uboot, записанный на раздел винта.

Сеть не работает, как я понял, ядро скомпилировано без поддержки RTL8211D

Serial port

Код:
Stage-1 Bootloader Fri Jun 10 14:12:46 CST 2011
Attempting to set PLLA to 750MHz ...
  plla_ctrl0 : 0x0000000A
  plla_ctrl1 : 0x000F0000
  plla_ctrl2 : 0x001D01A0
  plla_ctrl3 : 0x00000017
PLLA Set

Setup memory, testing
Reading disk 00
  Sector : 0x0000009A
  Hdr len: 0x0001FD3C
  Hdr CRC: 0xC2AB7EEB
 OK
Initialising disks
SATA PHY not ready for device 1
Detecting SATA busses:
Bus 0: Found first device OK
  Device 0: Model: ST380815AS Firm: 3.AAC  Ser#: 6QZ0M5Y2
            Type: Hard Disk
            Capacity: 76318.0 MB = 74.5 GB (156299375 x 512)
  Device 1: not available
Failed to read valid environment from disk, using built-in default


U-Boot 1.1.4 (Jun 20 2013 - 18:14:59)

U-Boot code: 60E00000 -> 60E1FD3C  BSS: -> 60E54564
RAM Configuration:
        Bank #0: 60000000 128 MB
SRAM Configuration:
        64KB at 0x50000000
NAND:256 MiB
*** Warning - bad CRC, using default environment

In:    serial
Out:   serial
Err:   serial
Setting Linux mem= boot arg value

IDE read: device 0 block # 288, count 1 ... 1 blocks read: OK
Hit any key to stop autoboot:  0
Extinguish LED

IDE read: device 0 block # 1290, count 5700 ... 5700 blocks read: OK
## Booting image at 60500000 ...
   Image Name:   Linux-2.6.31.6_SMP_820
   Image Type:   ARM Linux Kernel Image (uncompressed)
   Data Size:    2159884 Bytes =  2.1 MB
   Load Address: 60008000
   Entry Point:  60008000
   Verifying Checksum ... OK
OK

Starting kernel ...

Uncompressing Linux................................................................................................................................... done, booting the kernel.
[    0.000000] Linux version 2.6.31.6_SMP_820 (root@ProDev) (gcc version 4.6.0 20110429 (prerelease) (GCC) ) #100 SMP Sun May 29 04:53:45 EDT 2011
[    0.000000] CPU: ARMv6-compatible processor [410fb025] revision 5 (ARMv7), cr=00c5387f
[    0.000000] CPU: VIPT nonaliasing data cache, VIPT nonaliasing instruction cache
[    0.000000] Machine: Oxsemi NAS
[    0.000000] 1 memory region
[    0.000000] Ignoring unrecognised tag 0x00000000
[    0.000000] Memory policy: ECC disabled, Data cache writealloc
[    0.000000] Built 1 zonelists in Zone order, mobility grouping on.  Total pages: 32512
[    0.000000] Kernel command line: root=/dev/sda1 console=ttyS0,115200 elevator=cfq mac_adr=0x00,0x01,0xd2,0x12,0x54,0xfa rootwait mem=128M poweroutage=yes
[    0.000000] PID hash table entries: 512 (order: 9, 2048 bytes)
[    0.000000] Dentry cache hash table entries: 16384 (order: 4, 65536 bytes)
[    0.000000] Inode-cache hash table entries: 8192 (order: 3, 32768 bytes)
[    0.000000] Memory: 128MB = 128MB total
[    0.000000] Memory: 125496KB available (3692K code, 291K data, 124K init, 0K highmem)
[    0.000000] Hierarchical RCU implementation.
[    0.000000] NR_IRQS:96
[    0.000000] OX820_RPS_init_irq: interrupts 64 to 96
[    0.010000] Console: colour dummy device 80x30
[    0.010000] console [ttyS0] enabled
[    0.020000] Calibrating delay loop... 299.00 BogoMIPS (lpj=1495040)
[    0.240000] Security Framework initialized
[    0.240000] Mount-cache hash table entries: 512
[    0.250000] CPU: Testing write buffer coherency: ok
[    0.250000] Calibrating local timer... 375.50MHz.
[    0.320000] CPU1: Booted secondary processor
[    0.420000] Calibrating delay loop... 299.82 BogoMIPS (lpj=1499136)
[    0.630000] Brought up 2 CPUs
[    0.640000] SMP: Total of 2 processors activated (598.83 BogoMIPS).
[    0.650000] NET: Registered protocol family 16
[    0.650000] Number of DMA channels = 4, version = 4
[    0.660000] Reserving a DMA channel for DirectRAID
[    0.660000] Allocating 389 SRAM generic DMA descriptors
[    0.680000] bio: create slab <bio-0> at 0
[    0.690000] SCSI subsystem initialized
[    0.690000] usbcore: registered new interface driver usbfs
[    0.700000] usbcore: registered new interface driver hub
[    0.700000] usbcore: registered new device driver usb
[    0.730000] NET: Registered protocol family 2
[    0.730000] IP route cache hash table entries: 1024 (order: 0, 4096 bytes)
[    0.740000] Switched to NOHz mode on CPU #0
[    0.740000] TCP established hash table entries: 4096 (order: 3, 32768 bytes)
[    0.740000] Switched to NOHz mode on CPU #1
[    0.750000] TCP bind hash table entries: 4096 (order: 3, 32768 bytes)
[    0.760000] TCP: Hash tables configured (established 4096 bind 4096)
[    0.760000] TCP reno registered
[    0.770000] NET: Registered protocol family 1
[    0.770000] Create fragment cache
[    0.780000] fuse init (API version 7.12)
[    0.780000] msgmni has been set to 245
[    0.790000] alg: No test for stdrng (krng)
[    0.790000] io scheduler noop registered
[    0.800000] io scheduler anticipatory registered
[    0.800000] io scheduler deadline registered
[    0.810000] io scheduler cfq registered (default)
[    0.830000] Serial: 8250/16550 driver, 2 ports, IRQ sharing disabled
[    0.840000] serial8250: ttyS0 at MMIO 0x44200000 (irq = 55) is a 16550A
[    0.850000] brd: module loaded
[    0.860000] loop: module loaded
[    0.860000] ox820sata: OX820 sata core.
[    0.870000] scsi0 : oxnassata
[    0.870000] scsi1 : oxnassata
[    0.880000] ata1: SATA max UDMA/133 irq 50
[    0.880000] ata2: SATA max UDMA/133 irq 50
[    0.880000] ox820sata: reseting SATA core
[    1.410000] ata1: SATA link up 3.0 Gbps (SStatus 123 SControl 300)
[    1.460000] ata1.00: HPA detected: current 156299375, native 156301488
[    1.460000] ata1.00: ATA-7: ST380815AS, 3.AAC, max UDMA/133
[    1.470000] ata1.00: 156299375 sectors, multi 0: LBA48 NCQ (depth 0/32)
[    1.510000] ata1.00: configured for UDMA/133
[    1.520000] ox820sata: reseting SATA core
[    2.230000] ata2: SATA link down (SStatus 0 SControl 300)
[    2.230000] scsi 0:0:0:0: Direct-Access     ATA      ST380815AS       3.AA PQ: 0 ANSI: 5
[    2.240000] sd 0:0:0:0: [sda] 156299375 512-byte logical blocks: (80.0 GB/74.5 GiB)
[    2.250000] sd 0:0:0:0: [sda] Write Protect is off
[    2.250000] sd 0:0:0:0: [sda] Write cache: enabled, read cache: enabled, doesn't support DPO or FUA
[    2.260000] tun: Universal TUN/TAP device driver, 1.6
[    2.260000] tun: (C) 1999-2004 Max Krasnyansky <[email protected]>
[    2.260000] NAND: Page read time 40ms
[    2.260000] NAND device: Manufacturer ID: 0xad, Chip ID: 0xda (Hynix NAND 256MiB 3,3V 8-bit)
[    2.260000] Scanning device for bad blocks
[    2.280000] Bad eraseblock 324 at 0x000002880000
[    2.280000] Bad eraseblock 325 at 0x0000028a0000
[    2.390000] Creating 2 MTD partitions on "NAND 256MiB 3,3V 8-bit":
[    2.400000] 0x000000000000-0x000000e00000 : "boot"
[    2.410000]  sda:
[    2.410000] 0x000000e00000-0x000010000000 : "rootfs"
[    2.420000] ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
[    2.420000] oxnas-ehci oxnas-ehci.0: OXNAS EHCI Host Controller
[    2.430000] oxnas-ehci oxnas-ehci.0: new USB bus registered, assigned bus number 1
[    2.470000] oxnas-ehci oxnas-ehci.0: irq 39, io mem 0x00000000
[    2.470000]  sda1
[    2.480000] sd 0:0:0:0: [sda] Attached SCSI disk
[    2.490000] oxnas-ehci oxnas-ehci.0: USB 0.0 started, EHCI 1.00
[    2.490000] usb usb1: New USB device found, idVendor=1d6b, idProduct=0002
[    2.500000] usb usb1: New USB device strings: Mfr=3, Product=2, SerialNumber=1
[    2.500000] usb usb1: Product: OXNAS EHCI Host Controller
[    2.510000] usb usb1: Manufacturer: Linux 2.6.31.6_SMP_820 ehci_hcd
[    2.520000] usb usb1: SerialNumber: usb
[    2.520000] usb usb1: configuration #1 chosen from 1 choice
[    2.530000] hub 1-0:1.0: USB hub found
[    2.530000] hub 1-0:1.0: 2 ports detected
[    2.540000] Initializing USB Mass Storage driver...
[    2.540000] usbcore: registered new interface driver usb-storage
[    2.550000] USB Mass Storage support registered.
[    2.550000] mice: PS/2 mouse device common for all mice
[    2.560000] TCP cubic registered
[    2.560000] NET: Registered protocol family 10
[    2.570000] NET: Registered protocol family 17
[    2.570000] RPC: Registered udp transport module.
[    2.580000] RPC: Registered tcp transport module.
[    2.660000] kjournald starting.  Commit interval 5 seconds
[    2.660000] EXT3 FS on sda1, internal journal
[    2.660000] EXT3-fs: recovery complete.
[    2.660000] EXT3-fs: mounted filesystem with writeback data mode.
[    2.660000] VFS: Mounted root (ext3 filesystem) on device 8:1.
[    2.660000] Freeing init memory: 124K
modprobe: FATAL: Could not load /lib/modules/2.6.31.6_SMP_820/modules.dep: No such file or directory

                Welcome to Fedora
                Press 'I' to enter interactive startup.
Starting udev: modprobe: FATAL: Could not load /lib/modules/2.6.31.6_SMP_820/modules.dep: No such file or directory

[  OK  ]
Setting hostname localhost:  [  OK  ]
Checking filesystems
WARNING: couldn't open /etc/fstab: No such file or directory
Checking all file systems.
[  OK  ]
warning: can't open /etc/fstab: No such file or directory
mount: can't find / in /etc/fstab or /etc/mtab
Mounting local filesystems:  warning: can't open /etc/fstab: No such file or directory
[  OK  ]
Enabling /etc/fstab swaps:  swapon: /etc/fstab: open failed: No such file or directory
      [FAILED]
modprobe: FATAL: Could not load /lib/modules/2.6.31.6_SMP_820/modules.dep: No such file or directory

modprobe: FATAL: Could not load /lib/modules/2.6.31.6_SMP_820/modules.dep: No such file or directory

Entering non-interactive startup
Starting system logger: [  OK  ]
Starting system message bus: [  OK  ]
/etc/rc3.d/S24avahi-daemon: line 25: /etc/sysconfig/network: No such file or directory
Retrigger failed udev events[  OK  ]
Starting sshd: [  OK  ]

Fedora release 12 (Constantine)
Kernel 2.6.31.6_SMP_820 on an armv6l (/dev/ttyS0)

localhost login: root
Password:
Last login: Wed Dec 31 19:00:27 on ttyS0
root@localhost:~#
[свернуть]
Миниатюры
Нажмите на изображение для увеличения
Название: 111.png
Просмотров: 161
Размер:	14.6 Кб
ID:	4667   Нажмите на изображение для увеличения
Название: 222.png
Просмотров: 148
Размер:	26.7 Кб
ID:	4668   Нажмите на изображение для увеличения
Название: Seial port.jpg
Просмотров: 173
Размер:	221.3 Кб
ID:	4669  

Последний раз редактировалось sakatgg; 29.12.2017 в 04:56.
sakatgg вне форума   Ответить с цитированием
Старый 04.01.2018, 19:17   #12
sakatgg
Senior Member
 
Регистрация: 15.07.2014
Сообщений: 939
Вес репутации: 989
sakatgg is just really nicesakatgg is just really nicesakatgg is just really nicesakatgg is just really nicesakatgg is just really nice
По умолчанию

Запуск Debian с SATA винта на NAS Iconbit I-STOR IS608

Клоны - близнецы

FANTEC CL-35B2,
Iconbit I-STOR IS608,
Eminent EM4172,
AKiTiO MyCloud Duo.

Абсолютно внешне и внутренне одинаковые, различия только в прошивках и то на уровне встройки своих логотипов и дизайна веб интерфейса.

Альтернативу нашел ток на немецком сайте loteks.de, ссылки на полезные советы выкладовал выше.

По моей просьбе der_metzger выложил еще Резервное копирование и восстановление NAND с помощью mtd-utils

В поисках NAS платформы OX82x / NAS782x architecture нашел

PogoPlug v3,
Shuttle KD20,
iomega Home Media,
ZyXEL NSA-212,
Medion MD 8****.

Модели различаются дизайном, PCB, обьемом RAM и Nand, количеством и наличием usb, sata, wifi, pci.

Хорошо их модифицирует bodhi на сайте forum.doozan.com - запуски с usb, с sata, uboot, разгон CPU, сборки rootfs Arch, Debian, Openwrt, мультизагрузка и т.д.

Почитал, много сразу не осилил, хоть с чего-то начать - создал загрузочный sata с Debian готовым скриптом schnee отсюда.

Потребуется 5 мин, установить на компе с Debian предварительно пакеты, и прочитать из архива readme

uboot-mkimage,
util-linux - fdisk должен быть из его состава, (gnu-fdisk удалить из системы),
dosfstools_3.0.27-1_i386 или выше (в нем есть необходимый для скрипта mkfs.fat)

После запуска и отработки скрипта получиться разметка как на скрине

Лог выполнения скрипта

Код:
root@user-2:/home/user/PogoSata# sudo ./pogoSATA.sh /dev/sda
./pogoSATA.sh: line 52: [: =: ожидается использование унарного оператора
WARNING!!!!
ALL DATA ON /dev/sda WILL BE DESTROYED!
PROCEED? (y/N)
y
Deleting partitions...

Command (m for help): Building a new DOS disklabel with disk identifier 0x07c2a223.
Changes will remain in memory only, until you decide to write them.
After that, of course, the previous content won't be recoverable.

Warning: invalid flag 0x0000 of partition table 4 will be corrected by w(rite)

Command (m for help): The partition table has been altered!

Calling ioctl() to re-read partition table.
Syncing disks.
Creating partions....
Command (m for help): Partition type:
   p   primary (0 primary, 0 extended, 4 free)
   e   extended
Select (default p): Partition number (1-4, default 1): First sector (2048-156299374, default 2048): Last sector, +sectors or +size{K,M,G} (2048-156299374, default 156299374): 
Command (m for help): Partition type:
   p   primary (1 primary, 0 extended, 3 free)
   e   extended
Select (default p): Partition number (1-4, default 2): First sector (34816-156299374, default 34816): Using default value 34816
Last sector, +sectors or +size{K,M,G} (34816-156299374, default 156299374): 
Command (m for help): Partition type:
   p   primary (2 primary, 0 extended, 2 free)
   e   extended
Select (default p): Partition number (1-4, default 3): First sector (8423424-156299374, default 8423424): Using default value 8423424
Last sector, +sectors or +size{K,M,G} (8423424-156299374, default 156299374): Using default value 156299374

Command (m for help): The partition table has been altered!

Calling ioctl() to re-read partition table.
Syncing disks.
  Done!
Formating /dev/sda1...mkfs.fat 3.0.27 (2014-11-12)
 Done!
Formating /dev/sda2...mke2fs 1.42.5 (29-Jul-2012)
Filesystem label=rootfs
OS type: Linux
Block size=4096 (log=2)
Fragment size=4096 (log=2)
Stride=0 blocks, Stripe width=0 blocks
262144 inodes, 1048576 blocks
52428 blocks (5.00%) reserved for the super user
First data block=0
Maximum filesystem blocks=1073741824
32 block groups
32768 blocks per group, 32768 fragments per group
8192 inodes per group
Superblock backups stored on blocks: 
	32768, 98304, 163840, 229376, 294912, 819200, 884736

Allocating group tables: done                            
Writing inode tables: done                            
Creating journal (32768 blocks): done
Writing superblocks and filesystem accounting information: done 

 Done!
Formating /dev/sda3...mke2fs 1.42.5 (29-Jul-2012)
Filesystem label=home
OS type: Linux
Block size=4096 (log=2)
Fragment size=4096 (log=2)
Stride=0 blocks, Stripe width=0 blocks
4628480 inodes, 18484493 blocks
924224 blocks (5.00%) reserved for the super user
First data block=0
Maximum filesystem blocks=0
565 block groups
32768 blocks per group, 32768 fragments per group
8192 inodes per group
Superblock backups stored on blocks: 
	32768, 98304, 163840, 229376, 294912, 819200, 884736, 1605632, 2654208, 
	4096000, 7962624, 11239424

Allocating group tables: done                            
Writing inode tables: done                            
Writing superblocks and filesystem accounting information: done   

 Done!
Copying uBoot files...rmdir: не удалось удалить «./boot»: Каталог не пуст
 Done!
Create magic...0+1 записей считано
0+1 записей написано
 скопировано 444 байта (444 B), 0,0448587 c, 9,9 kB/c
 Done!
Writing stage 156+1 записей считано
56+1 записей написано
 скопировано 29172 байта (29 kB), 0,0627369 c, 465 kB/c
Mount rootfs... Done!
Copy root filesystem... Done!
Extract rootfs... Done!
Copying new kernel... Done!
Finalizing...umount: /dev/sda1: not mounted
umount: /dev/sda2: not mounted
umount: /dev/sda3: not mounted
 Done!
Finished!
Connect the drive to the Pogo and boot! Connect a serial console and an enthernet cable to the Pogo and boot it. Let .1stboot.sh to finish after you loged on!
Username: root, Password:root
ENJOY!
root@user-2:/home/user/PogoSata#
[свернуть]

Вставляем в правый слот sata с лица и включаем, первая загрузка - ничего не трогаем, ждем чтобы сам перезагрузился (sshd генерирует ключ, обновляется на 4.1 kernel, создается 512MB swap file)

в serial port после перезагрузки:

Serial port

Код:
U-Boot SPL 2013.10-ga72eb8f-dirty (Feb 19 2014 - 15:21:12)
  Boot device: SATA
Attempting to set PLLA to 800 MHz ...
  plla_ctrl0 : 0000030a
  plla_ctrl1 : 00400000
  plla_ctrl2 : 007f0068
  plla_ctrl3 : 00000193

PLLA Set
Bus 0: OK
  Device 0:
reading bootargs.bin
reading u-boot.img
reading u-boot.img


U-Boot 2013.10-ga72eb8f-dirty (Feb 19 2014 - 15:21:12) for OXNAS

DRAM:  128 MiB
IDE:   Bus 0: OK
  Device 0: Model: ST380815AS Firm: 3.AAC  Ser#: 6QZ0M5Y2
            Type: Hard Disk
            Supports 48-bit addressing
            Capacity: 76318.0 MB = 74.5 GB (156299375 x 512)
NAND:  256 MiB
reading u-boot.env
In:    serial
Out:   serial
Err:   serial
Net:   mii0
## Error: "safeboot" not defined
Hit any key to stop autoboot:  0
4488520 bytes read in 709 ms (6 MiB/s)
7033 bytes read in 26 ms (263.7 KiB/s)
magic:                  0xd00dfeed
totalsize:              0x1b79 (7033)
off_dt_struct:          0x38
off_dt_strings:         0x18d4
off_mem_rsvmap:         0x28
version:                17
last_comp_version:      16
boot_cpuid_phys:        0x0
size_dt_strings:        0x2a5
size_dt_struct:         0x189c
number mem_rsv:         0x0

## Booting kernel from Legacy Image at 60000000 ...
   Image Name:   Linux-4.1.0-oxnas-tld-1
   Image Type:   ARM Linux Kernel Image (uncompressed)
   Data Size:    4488456 Bytes = 4.3 MiB
   Load Address: 60008000
   Entry Point:  60008000
   Verifying Checksum ... OK
## Flattened Device Tree blob at 61000000
   Booting using the fdt blob at 0x61000000
   Loading Kernel Image ... OK
   Loading Device Tree to 67e26000, end 67e2ab78 ... OK

Starting kernel ...

Uncompressing Linux... done, booting the kernel.
[    0.000000] Booting Linux on physical CPU 0x0
[    0.000000] Linux version 4.1.0-oxnas-tld-1 (root@tldDebian) (gcc version 4.9.2 (Debian 4.9.2-10) ) #3 SMP PREEMPT Wed Jul 1 05:11:47 PDT 2015
[    0.000000] CPU: ARMv6-compatible processor [410fb025] revision 5 (ARMv7), cr=00c5787d
[    0.000000] CPU: PIPT / VIPT nonaliasing data cache, VIPT aliasing instruction cache
[    0.000000] Machine model: Pogoplug Pro
[    0.000000] Memory policy: Data cache writealloc
[    0.000000] DT missing boot CPU MPIDR[23:0], fall back to default cpu_logical_map
[    0.000000] Start Ox820 platform
[    0.000000] PERCPU: Embedded 11 pages/cpu @c7edc000 s15456 r8192 d21408 u45056
[    0.000000] Built 1 zonelists in Zone order, mobility grouping on.  Total pages: 32512
[    0.000000] Kernel command line: console=ttyS0,115200n8 root=/dev/sda2 rootfstype=ext4 ubi.mtd=data,512
[    0.000000] PID hash table entries: 512 (order: -1, 2048 bytes)
[    0.000000] Dentry cache hash table entries: 16384 (order: 4, 65536 bytes)
[    0.000000] Inode-cache hash table entries: 8192 (order: 3, 32768 bytes)
[    0.000000] Memory: 120984K/131072K available (6235K kernel code, 275K rwdata, 1852K rodata, 200K init, 237K bss, 10088K reserved, 0K cma-reserved)
[    0.000000] Virtual kernel memory layout:
[    0.000000]     vector  : 0xffff0000 - 0xffff1000   (   4 kB)
[    0.000000]     fixmap  : 0xffc00000 - 0xfff00000   (3072 kB)
[    0.000000]     vmalloc : 0xc8800000 - 0xff000000   ( 872 MB)
[    0.000000]     lowmem  : 0xc0000000 - 0xc8000000   ( 128 MB)
[    0.000000]     modules : 0xbf000000 - 0xc0000000   (  16 MB)
[    0.000000]       .text : 0xc0008000 - 0xc07edec8   (8088 kB)
[    0.000000]       .init : 0xc07ee000 - 0xc0820000   ( 200 kB)
[    0.000000]       .data : 0xc0820000 - 0xc0864fa0   ( 276 kB)
[    0.000000]        .bss : 0xc0864fa0 - 0xc08a06a0   ( 238 kB)
[    0.000000] SLUB: HWalign=32, Order=0-3, MinObjects=0, CPUs=2, Nodes=1
[    0.000000] Preemptible hierarchical RCU implementation.
[    0.000000] NR_IRQS:160
[    0.000000] clocksource rps_clocksource_timer: mask: 0xffffff max_cycles: 0xffffff, max_idle_ns: 19112603332 ns
[    0.000010] sched_clock: 24 bits at 390kHz, resolution 2560ns, wraps every 21474835200ns
[    0.000176] Console: colour dummy device 80x30
[    0.000209] Calibrating delay loop... 319.48 BogoMIPS (lpj=1597440)
[    0.050032] pid_max: default: 32768 minimum: 301
[    0.050191] Mount-cache hash table entries: 1024 (order: 0, 4096 bytes)
[    0.050209] Mountpoint-cache hash table entries: 1024 (order: 0, 4096 bytes)
[    0.051082] Initializing cgroup subsys net_cls
[    0.051148] CPU: Testing write buffer coherency: ok
[    0.051548] Setting up static identity map for 0x60008220 - 0x60008258
[    0.170145] Brought up 2 CPUs
[    0.170168] SMP: Total of 2 processors activated (638.97 BogoMIPS).
[    0.171151] devtmpfs: initialized
[    0.176826] clocksource jiffies: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 19112604462750000 ns
[    0.177062] prandom: seed boundary self test passed
[    0.181744] prandom: 100 self tests passed
[    0.181775] pinctrl core: initialized pinctrl subsystem
[    0.182668] NET: Registered protocol family 16
[    0.183242] DMA: preallocated 256 KiB pool for atomic coherent allocations
[    0.210009] cpuidle: using governor ladder
[    0.240005] cpuidle: using governor menu
[    0.245104] gpio-oxnas 44000000.gpio: at address c8848000
[    0.245445] gpio-oxnas 44100000.gpio: at address c884a000
[    0.246041] pinctrl-oxnas pinctrl: initialized OX820 pinctrl driver
[    0.260183] vgaarb: loaded
[    0.260720] SCSI subsystem initialized
[    0.261591] usbcore: registered new interface driver usbfs
[    0.261703] usbcore: registered new interface driver hub
[    0.261857] usbcore: registered new device driver usb
[    0.262082] pps_core: LinuxPPS API ver. 1 registered
[    0.262095] pps_core: Software ver. 5.3.6 - Copyright 2005-2007 Rodolfo Giometti <[email protected]>
[    0.262146] PTP clock support registered
[    0.263895] cfg80211: Calling CRDA to update world regulatory domain
[    0.264422] Switched to clocksource rps_clocksource_timer
[    0.283983] NET: Registered protocol family 2
[    0.284974] TCP established hash table entries: 1024 (order: 0, 4096 bytes)
[    0.285020] TCP bind hash table entries: 1024 (order: 1, 8192 bytes)
[    0.285061] TCP: Hash tables configured (established 1024 bind 1024)
[    0.285163] UDP hash table entries: 256 (order: 1, 8192 bytes)
[    0.285209] UDP-Lite hash table entries: 256 (order: 1, 8192 bytes)
[    0.285498] NET: Registered protocol family 1
[    0.286003] RPC: Registered named UNIX socket transport module.
[    0.286023] RPC: Registered udp transport module.
[    0.286036] RPC: Registered tcp transport module.
[    0.286046] RPC: Registered tcp NFSv4.1 backchannel transport module.
[    0.287856] futex hash table entries: 512 (order: 2, 16384 bytes)
[    0.287938] Initialise system trusted keyring
[    0.302192] zpool: loaded
[    0.302218] zbud: loaded
[    0.307663] NFS: Registering the id_resolver key type
[    0.307729] Key type id_resolver registered
[    0.307742] Key type id_legacy registered
[    0.307781] nfs4filelayout_init: NFSv4 File Layout Driver Registering...
[    0.307804] Installing knfsd (copyright (C) 1996 [email protected]).
[    0.308751] fuse init (API version 7.23)
[    0.310571] Key type big_key registered
[    0.316482] alg: No test for stdrng (krng)
[    0.366873] Key type asymmetric registered
[    0.366906] Asymmetric key parser 'x509' registered
[    0.367047] Block layer SCSI generic (bsg) driver version 0.4 loaded (major 252)
[    0.367080] io scheduler noop registered
[    0.367104] io scheduler deadline registered
[    0.367493] io scheduler cfq registered (default)
[    0.368202] Serial: 8250/16550 driver, 1 ports, IRQ sharing disabled
[    0.369710] console [ttyS0] disabled
[    0.369802] 44200000.uart: ttyS0 at MMIO 0x44200000 (irq = 6, base_baud = 390625) is a 16550A
[    0.898398] console [ttyS0] enabled
[    0.912499] loop: module loaded
[    0.917557] scsi host0: sata_oxnas
[    0.921443] ata1: SATA max UDMA/133 irq 7
[    0.925706] ox820sata: reseting SATA core
[    0.926620] nand: Could not find valid ONFI parameter page; aborting
[    0.926663] nand: device found, Manufacturer ID: 0xad, Chip ID: 0xda
[    0.926668] nand: Hynix NAND 256MiB 3,3V 8-bit
[    0.926676] nand: 256 MiB, SLC, erase size: 128 KiB, page size: 2048, OOB size: 64
[    0.926694] Scanning device for bad blocks
[    0.953830] Bad eraseblock 324 at 0x000002880000
[    0.953879] Bad eraseblock 325 at 0x0000028a0000
[    1.096760] 2 ofpart partitions found on MTD device 41000000.nand
[    1.102855] Creating 2 MTD partitions on "41000000.nand":
[    1.108234] 0x000000000000-0x000000e00000 : "boot"
[    1.114752] 0x000000e00000-0x000008000000 : "data"
[    1.122081] stmmaceth 40400000.ethernet: no reset control found
[    1.127982] stmmac - user ID: 0x12, Synopsys ID: 0x35
[    1.133038]  Ring mode enabled
[    1.136079]  DMA HW capability register supported
[    1.140602]  Enhanced/Alternate descriptors
[    1.144931]  Enabled extended descriptors
[    1.148915]  RX Checksum Offload Engine supported (type 2)
[    1.154383]  TX Checksum insertion supported
[    1.158625]  Wake-Up On Lan supported
[    1.162280]  Enable RX Mitigation via HW Watchdog Timer
[    1.171328] libphy: stmmac: probed
[    1.174727] eth0: PHY ID 001cc914 at 0 IRQ POLL (stmmac-0:00) active
[    1.181068] eth0: PHY ID 001cc914 at 3 IRQ POLL (stmmac-0:03)
[    1.186885] PPP generic driver version 2.4.2
[    1.191777] ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
[    1.198287] ehci-pci: EHCI PCI platform driver
[    1.203266] oxnas-ehci 40200100.ehci: EHCI Host Controller
[    1.208762] oxnas-ehci 40200100.ehci: new USB bus registered, assigned bus number 1
[    1.216634] oxnas-ehci 40200100.ehci: irq 10, io mem 0x40200100
[    1.240576] oxnas-ehci 40200100.ehci: USB 2.0 started, EHCI 1.00
[    1.246881] usb usb1: New USB device found, idVendor=1d6b, idProduct=0002
[    1.253675] usb usb1: New USB device strings: Mfr=3, Product=2, SerialNumber=1
[    1.260884] usb usb1: Product: EHCI Host Controller
[    1.265735] usb usb1: Manufacturer: Linux 4.1.0-oxnas-tld-1 ehci_hcd
[    1.272071] usb usb1: SerialNumber: 40200100.ehci
[    1.277724] hub 1-0:1.0: USB hub found
[    1.281582] hub 1-0:1.0: 2 ports detected
[    1.286553] usbcore: registered new interface driver cdc_acm
[    1.292226] cdc_acm: USB Abstract Control Model driver for USB modems and ISDN adapters
[    1.300308] usbcore: registered new interface driver cdc_wdm
[    1.306140] usbcore: registered new interface driver usb-storage
[    1.312394] usbcore: registered new interface driver usbserial
[    1.318287] usbcore: registered new interface driver usbserial_generic
[    1.324881] usbserial: USB Serial support registered for generic
[    1.331302] mousedev: PS/2 mouse device common for all mice
[    1.337024] i2c /dev entries driver
[    1.341903] hidraw: raw HID events driver (C) Jiri Kosina
[    1.347527] usbcore: registered new interface driver usbhid
[    1.353111] usbhid: USB HID core driver
[    1.358878] NET: Registered protocol family 10
[    1.364951] sit: IPv6 over IPv4 tunneling driver
[    1.370780] NET: Registered protocol family 17
[    1.375390] Key type dns_resolver registered
[    1.381350] Loading compiled-in X.509 certificates
[    1.390453] Key type encrypted registered
[    1.395322] ubi0: attaching mtd1
[    1.480010] ata1: SATA link up 1.5 Gbps (SStatus 113 SControl 310)
[    1.541562] ata1.00: HPA detected: current 156299375, native 156301488
[    1.548083] ata1.00: ATA-7: ST380815AS, 3.AAC, max UDMA/133
[    1.549772] ubi0: scanning is finished
[    1.549975] ubi0 error: ubi_read_volume_table: the layout volume was not found
[    1.550886] ubi0 error: ubi_attach_mtd_dev: failed to attach mtd1, error -22
[    1.571604] UBI error: cannot attach mtd1
[    1.571607] ata1.00: 156299375 sectors, multi 0: LBA48 NCQ (depth 0/32)
[    1.616542] ata1.00: configured for UDMA/133
[    1.640453] scsi 0:0:0:0: Direct-Access     ATA      ST380815AS       C    PQ: 0 ANSI: 5
[    1.649927] sd 0:0:0:0: [sda] 156299375 512-byte logical blocks: (80.0 GB/74.5 GiB)
[    1.658654] sd 0:0:0:0: [sda] Write Protect is off
[    1.663713] sd 0:0:0:0: [sda] Write cache: enabled, read cache: enabled, doesn't support DPO or FUA
[    1.698472]  sda: sda1 sda2 sda3
[    1.704348] sd 0:0:0:0: [sda] Attached SCSI disk
[    1.734382] EXT4-fs (sda2): mounted filesystem with ordered data mode. Opts: (null)
[    1.742156] VFS: Mounted root (ext4 filesystem) readonly on device 8:2.
[    1.765342] devtmpfs: mounted
[    1.768634] Freeing unused kernel memory: 200K (c07ee000 - c0820000)
INIT: version 2.88 booting
[info] Using makefile-style concurrent boot in runlevel S.
[....] Starting the hotplug events dispatcher: udevd[    3.236339] udevd[187]: starting version 175
. ok
[    3.472514] cfg80211: Calling CRDA to update world regulatory domain
[ ok ] Synthesizing the initial hotplug events...done.
[ ok ] Waiting for /dev to be fully populated...done.
[    5.355609] EXT4-fs (sda2): re-mounted. Opts: (null)
[....] Checking root file system...fsck from util-linux 2.20.1
rootfs: clean, 26997/262144 files, 281881/1048576 blocks
done.
[    5.669125] EXT4-fs (sda2): re-mounted. Opts: errors=remount-ro
[ ok ] Cleaning up temporary files... /tmp /lib/init/rw.
[ ok ] Loading kernel modules...done.
[    6.630318] cfg80211: Calling CRDA to update world regulatory domain
[....] Activating lvm and md swap...[    9.568325] Adding 524284k swap on /swapfile1.  Priority:-1 extents:3 across:540668k FS
done.
[....] Checking file systems...fsck from util-linux 2.20.1
[    9.790108] cfg80211: Calling CRDA to update world regulatory domain
home: clean, 11/4628480 files, 303741/18484493 blocks
[    9.873221] random: nonblocking pool is initialized
done.
[ ok ] Mounting local filesystems...done.
[ ok ] Activating swapfile swap...done.
[ ok ] Cleaning up temporary files....
[ ok ] Setting kernel variables ...done.
[....] Configuring network interfaces...Internet Systems Consortium DHCP Client 4.2.2
Copyright 2004-2011 Internet Systems Consortium.
All rights reserved.
For info, please visit https://www.isc.org/software/dhcp/

Listening on LPF/eth0/74:f0:11:11:11:11
Sending on   LPF/eth0/74:f0:11:11:11:11
Sending on   Socket/fallback
DHCPREQUEST on eth0 to 255.255.255.255 port 67
[   12.950018] cfg80211: Calling CRDA to update world regulatory domain
[   16.110005] cfg80211: Calling CRDA to update world regulatory domain
[   17.560727] stmmaceth 40400000.ethernet eth0: Link is Up - 1Gbps/Full - flow control rx/tx
DHCPREQUEST on eth0 to 255.255.255.255 port 67
DHCPACK from 192.168.3.1
[   19.270056] cfg80211: Calling CRDA to update world regulatory domain
bound to 192.168.3.179 -- renewal in 19909 seconds.
done.
[ ok ] Starting rpcbind daemon....
[ ok ] Starting NFS common utilities: statd idmapd.
[ ok ] Cleaning up temporary files....
INIT: Entering runlevel: 2
[info] Using makefile-style concurrent boot in runlevel 2.
[   22.440122] cfg80211: Calling CRDA to update world regulatory domain
[ ok ] Starting NTP server: ntpd.
[ ok ] Starting rpcbind daemon...[....] Already running..
[ ok ] Starting system message bus: dbus.
[....] Starting busybox' syslogd implementation : syslogdStarting /sbin/syslogd...
1692 (syslogd)
. ok
[ ok ] Starting NFS common utilities: statd idmapd.
[....] Starting busybox' klogd implementation : klogdStarting /sbin/klogd...
[ ok ] Starting Avahi mDNS/DNS-SD Daemon: avahi-daemon.
[warn] Not starting NFS kernel daemon: no exports. ... (warning).
[ ok ] Starting OpenBSD Secure Shell server: sshd.
1695 (klogd)
. ok
[   25.610012] cfg80211: Calling CRDA to update world regulatory domain

Debian GNU/Linux 7 debian ttyS0

debian login: [   28.770012] cfg80211: Calling CRDA to update world regulatory domain
[   31.930009] cfg80211: Calling CRDA to update world regulatory domain
[   35.090017] cfg80211: Exceeded CRDA call max attempts. Not calling CRDA

Debian GNU/Linux 7 debian ttyS0

debian login: root
Password:
Last login: Wed Dec 31 16:00:40 PST 1969 on ttyS0
Linux debian 4.1.0-oxnas-tld-1 #3 SMP PREEMPT Wed Jul 1 05:11:47 PDT 2015 armv6l

The programs included with the Debian GNU/Linux system are free software;
the exact distribution terms for each program are described in the
individual files in /usr/share/doc/*/copyright.

Debian GNU/Linux comes with ABSOLUTELY NO WARRANTY, to the extent
permitted by applicable law.
root@debian:~#
[свернуть]


Сеть работает, вроде как и DHCP Server включается, если роутера нет.

CPU с 700Мгц до 800Мгц разогнан. Есть разгон и до 850Мгц.

WiFi usb свистки TEW-664UB и DWA-140 rev В2 не увидел, но тут ядро похоже старое (скрипт писался 2,5г назад), в более новых вроде как включена поддержка некоторых, цитата

"loaded automatically during kernel booting: ATH9K, RT2X00, RT2800PCI,CFG80211, MAC80211."

GPIO светодиоды и кнопки не задействованы, но думаю это решаемо, не все сразу

Файловую систему UBI на Nand флешь не видит, саму Nand распознает.

Можно зайти через WinSCP (sshd стартует по умолчанию)

Если специально подготовленный sata винт вытащить, то будет как обычно грузиться с Nand.
Миниатюры
Нажмите на изображение для увеличения
Название: Снимок экрана.png
Просмотров: 152
Размер:	74.6 Кб
ID:	4686  

Последний раз редактировалось sakatgg; 05.01.2018 в 01:01.
sakatgg вне форума   Ответить с цитированием
Старый 13.02.2018, 20:51   #13
sakatgg
Senior Member
 
Регистрация: 15.07.2014
Сообщений: 939
Вес репутации: 989
sakatgg is just really nicesakatgg is just really nicesakatgg is just really nicesakatgg is just really nicesakatgg is just really nice
По умолчанию

Установка RootFS Debian-4.4.54-oxnas (Debian stretch)

1. Качаем Rootfs Debian-4.4.54-oxnas-tld-1-rootfs-bodhi.tar.bz2 (от 02 Aug 2017) с этой страницы

2. Подключаем винт к компу и удаляем всё с раздела rootfs (/dev/sda2) (разметка выше)

3. Извлекаем архив в корень раздела

Код:
tar -xjf Debian-4.4.54-oxnas-tld-1-rootfs-bodhi.tar.bz2
4. В /etc/fstab ставим
Код:
LABEL=rootfs    /               ext4    noatime,errors=remount-ro 0 1
5. Вставляем hdd в NAS и загружаемся

6. Генерируем SSH key
Код:
rm /etc/ssh/ssh_host*
ssh-keygen -A
7. Обновляемся
Код:
apt-get update
apt-get upgrade
Log upgrade NAS

8. Лог в serial port

Log serial port

Код:
U-Boot SPL 2013.10-ga72eb8f-dirty (Feb 19 2014 - 15:21:12)
  Boot device: SATA
Attempting to set PLLA to 800 MHz ...
  plla_ctrl0 : 0000030a
  plla_ctrl1 : 00400000
  plla_ctrl2 : 007f0068
  plla_ctrl3 : 00000193

PLLA Set
Bus 0: OK
  Device 0:
reading bootargs.bin
reading u-boot.img
reading u-boot.img


U-Boot 2013.10-ga72eb8f-dirty (Feb 19 2014 - 15:21:12) for OXNAS

DRAM:  128 MiB
IDE:   Bus 0: OK
  Device 0: Model: ST380815AS Firm: 3.AAC  Ser#: 6QZ0M5Y2
            Type: Hard Disk
            Supports 48-bit addressing
            Capacity: 76318.0 MB = 74.5 GB (156299375 x 512)
NAND:  256 MiB
reading u-boot.env
In:    serial
Out:   serial
Err:   serial
Net:   mii0
## Error: "safeboot" not defined
Hit any key to stop autoboot:  0
4621824 bytes read in 730 ms (6 MiB/s)
7075 bytes read in 26 ms (265.6 KiB/s)
magic:                  0xd00dfeed
totalsize:              0x1ba3 (7075)
off_dt_struct:          0x38
off_dt_strings:         0x18f4
off_mem_rsvmap:         0x28
version:                17
last_comp_version:      16
boot_cpuid_phys:        0x0
size_dt_strings:        0x2af
size_dt_struct:         0x18bc
number mem_rsv:         0x0

## Booting kernel from Legacy Image at 60000000 ...
   Image Name:   Linux-4.4.54-oxnas-tld-1
   Image Type:   ARM Linux Kernel Image (uncompressed)
   Data Size:    4621760 Bytes = 4.4 MiB
   Load Address: 60008000
   Entry Point:  60008000
   Verifying Checksum ... OK
## Flattened Device Tree blob at 61000000
   Booting using the fdt blob at 0x61000000
   Loading Kernel Image ... OK
   Loading Device Tree to 67e26000, end 67e2aba2 ... OK

Starting kernel ...

Uncompressing Linux... done, booting the kernel.
[    0.000000] Booting Linux on physical CPU 0x0
[    0.000000] Linux version 4.4.54-oxnas-tld-1 (root@tldDebian) (gcc version 4.9.2 (Debian 4.9.2-10) ) #2 SMP PREEMPT Sat Mar 18 23:09:58 PDT 2017
[    0.000000] CPU: ARMv6-compatible processor [410fb025] revision 5 (ARMv7), cr=00c5787d
[    0.000000] CPU: PIPT / VIPT nonaliasing data cache, VIPT aliasing instruction cache
[    0.000000] Machine model: Pogoplug V3 Classic
[    0.000000] Memory policy: Data cache writealloc
[    0.000000] DT missing boot CPU MPIDR[23:0], fall back to default cpu_logical_map
[    0.000000] PERCPU: Embedded 12 pages/cpu @c7eda000 s17696 r8192 d23264 u49152
[    0.000000] Built 1 zonelists in Zone order, mobility grouping on.  Total pages: 32512
[    0.000000] Kernel command line: console=ttyS0,115200n8 root=/dev/sda2 rootfstype=ext4 ubi.mtd=data,512
[    0.000000] PID hash table entries: 512 (order: -1, 2048 bytes)
[    0.000000] Dentry cache hash table entries: 16384 (order: 4, 65536 bytes)
[    0.000000] Inode-cache hash table entries: 8192 (order: 3, 32768 bytes)
[    0.000000] Memory: 120696K/131072K available (6410K kernel code, 288K rwdata, 1908K rodata, 224K init, 247K bss, 10376K reserved, 0K cma-reserved)
[    0.000000] Virtual kernel memory layout:
[    0.000000]     vector  : 0xffff0000 - 0xffff1000   (   4 kB)
[    0.000000]     fixmap  : 0xffc00000 - 0xfff00000   (3072 kB)
[    0.000000]     vmalloc : 0xc8800000 - 0xff800000   ( 880 MB)
[    0.000000]     lowmem  : 0xc0000000 - 0xc8000000   ( 128 MB)
[    0.000000]     modules : 0xbf000000 - 0xc0000000   (  16 MB)
[    0.000000]       .text : 0xc0008000 - 0xc0827e14   (8320 kB)
[    0.000000]       .init : 0xc0828000 - 0xc0860000   ( 224 kB)
[    0.000000]       .data : 0xc0860000 - 0xc08a8378   ( 289 kB)
[    0.000000]        .bss : 0xc08a8378 - 0xc08e6350   ( 248 kB)
[    0.000000] SLUB: HWalign=32, Order=0-3, MinObjects=0, CPUs=2, Nodes=1
[    0.000000] Preemptible hierarchical RCU implementation.
[    0.000000] NR_IRQS:160
[    0.000000] clocksource: rps_clocksource_timer: mask: 0xffffff max_cycles: 0xffffff, max_idle_ns: 19112603332 ns
[    0.000007] sched_clock: 24 bits at 390kHz, resolution 2560ns, wraps every 21474835200ns
[    0.000174] Console: colour dummy device 80x30
[    0.000209] Calibrating delay loop... 319.48 BogoMIPS (lpj=1597440)
[    0.050030] pid_max: default: 32768 minimum: 301
[    0.050206] Mount-cache hash table entries: 1024 (order: 0, 4096 bytes)
[    0.050227] Mountpoint-cache hash table entries: 1024 (order: 0, 4096 bytes)
[    0.051087] Initializing cgroup subsys net_cls
[    0.051174] CPU: Testing write buffer coherency: ok
[    0.051617] Setting up static identity map for 0x60008220 - 0x60008258
[    0.190151] Brought up 2 CPUs
[    0.190177] SMP: Total of 2 processors activated (638.97 BogoMIPS).
[    0.191001] devtmpfs: initialized
[    0.196615] clocksource: jiffies: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 19112604462750000 ns
[    0.196661] futex hash table entries: 512 (order: 2, 16384 bytes)
[    0.196994] prandom: seed boundary self test passed
[    0.201687] prandom: 100 self tests passed
[    0.201717] pinctrl core: initialized pinctrl subsystem
[    0.202588] NET: Registered protocol family 16
[    0.203174] DMA: preallocated 256 KiB pool for atomic coherent allocations
[    0.230016] cpuidle: using governor ladder
[    0.260008] cpuidle: using governor menu
[    0.265290] gpio-oxnas 44000000.gpio: at address c8848000
[    0.265728] gpio-oxnas 44100000.gpio: at address c884a000
[    0.266329] pinctrl-oxnas pinctrl: initialized OX820 pinctrl driver
[    0.280435] vgaarb: loaded
[    0.280949] SCSI subsystem initialized
[    0.281861] usbcore: registered new interface driver usbfs
[    0.281976] usbcore: registered new interface driver hub
[    0.282132] usbcore: registered new device driver usb
[    0.282332] pps_core: LinuxPPS API ver. 1 registered
[    0.282350] pps_core: Software ver. 5.3.6 - Copyright 2005-2007 Rodolfo Giometti <[email protected]>
[    0.282398] PTP clock support registered
[    0.284666] clocksource: Switched to clocksource rps_clocksource_timer
[    0.304299] NET: Registered protocol family 2
[    0.305239] TCP established hash table entries: 1024 (order: 0, 4096 bytes)
[    0.305285] TCP bind hash table entries: 1024 (order: 1, 8192 bytes)
[    0.305320] TCP: Hash tables configured (established 1024 bind 1024)
[    0.305425] UDP hash table entries: 256 (order: 1, 8192 bytes)
[    0.305469] UDP-Lite hash table entries: 256 (order: 1, 8192 bytes)
[    0.305748] NET: Registered protocol family 1
[    0.306304] RPC: Registered named UNIX socket transport module.
[    0.306327] RPC: Registered udp transport module.
[    0.306337] RPC: Registered tcp transport module.
[    0.306350] RPC: Registered tcp NFSv4.1 backchannel transport module.
[    0.308303] Initialise system trusted keyring
[    0.322938] zbud: loaded
[    0.328885] NFS: Registering the id_resolver key type
[    0.328949] Key type id_resolver registered
[    0.328965] Key type id_legacy registered
[    0.329008] nfs4filelayout_init: NFSv4 File Layout Driver Registering...
[    0.329031] Installing knfsd (copyright (C) 1996 [email protected]).
[    0.330199] fuse init (API version 7.23)
[    0.332318] Key type big_key registered
[    0.398632] Key type asymmetric registered
[    0.398671] Asymmetric key parser 'x509' registered
[    0.398812] Block layer SCSI generic (bsg) driver version 0.4 loaded (major 252)
[    0.398840] io scheduler noop registered
[    0.398860] io scheduler deadline registered
[    0.398942] io scheduler cfq registered (default)
[    0.399664] Serial: 8250/16550 driver, 1 ports, IRQ sharing disabled
[    0.401384] console [ttyS0] disabled
[    0.401487] 44200000.uart: ttyS0 at MMIO 0x44200000 (irq = 6, base_baud = 390625) is a 16550A
[    0.916080] console [ttyS0] enabled
[    0.931927] loop: module loaded
[    0.937118] scsi host0: sata_oxnas
[    0.941048] ata1: SATA max UDMA/133 irq 7
[    0.945144] sata_oxnas: resetting SATA core
[    0.946268] nand: Could not find valid ONFI parameter page; aborting
[    0.946311] nand: device found, Manufacturer ID: 0xad, Chip ID: 0xda
[    0.946319] nand: Hynix NAND 256MiB 3,3V 8-bit
[    0.946327] nand: 256 MiB, SLC, erase size: 128 KiB, page size: 2048, OOB size: 64
[    0.946344] Scanning device for bad blocks
[    0.973345] Bad eraseblock 324 at 0x000002880000
[    0.973393] Bad eraseblock 325 at 0x0000028a0000
[    1.115258] 2 ofpart partitions found on MTD device 41000000.nand
[    1.121356] Creating 2 MTD partitions on "41000000.nand":
[    1.126735] 0x000000000000-0x000000e00000 : "boot"
[    1.133596] 0x000000e00000-0x000008000000 : "data"
[    1.141145] oxnas-gmac 40400000.ethernet: no reset control found
[    1.147136] stmmac - user ID: 0x12, Synopsys ID: 0x35
[    1.152212]  Ring mode enabled
[    1.155253]  DMA HW capability register supported
[    1.159756]  Enhanced/Alternate descriptors
[    1.164111]  Enabled extended descriptors
[    1.168099]  RX Checksum Offload Engine supported (type 2)
[    1.173578]  TX Checksum insertion supported
[    1.177822]  Wake-Up On Lan supported
[    1.181483]  Enable RX Mitigation via HW Watchdog Timer
[    1.189391] libphy: stmmac: probed
[    1.192890] eth%d: PHY ID 001cc914 at 0 IRQ POLL (stmmac-0:00) active
[    1.199306] eth%d: PHY ID 001cc914 at 3 IRQ POLL (stmmac-0:03)
[    1.206108] PPP generic driver version 2.4.2
[    1.211095] ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
[    1.217610] ehci-pci: EHCI PCI platform driver
[    1.222709] oxnas-ehci 40200100.ehci: EHCI Host Controller
[    1.228216] oxnas-ehci 40200100.ehci: new USB bus registered, assigned bus number 1
[    1.236142] oxnas-ehci 40200100.ehci: irq 10, io mem 0x40200100
[    1.259996] oxnas-ehci 40200100.ehci: USB 2.0 started, EHCI 1.00
[    1.266347] usb usb1: New USB device found, idVendor=1d6b, idProduct=0002
[    1.273159] usb usb1: New USB device strings: Mfr=3, Product=2, SerialNumber=1
[    1.280376] usb usb1: Product: EHCI Host Controller
[    1.285235] usb usb1: Manufacturer: Linux 4.4.54-oxnas-tld-1 ehci_hcd
[    1.291668] usb usb1: SerialNumber: 40200100.ehci
[    1.297384] hub 1-0:1.0: USB hub found
[    1.301294] hub 1-0:1.0: 2 ports detected
[    1.306470] usbcore: registered new interface driver cdc_acm
[    1.312217] cdc_acm: USB Abstract Control Model driver for USB modems and ISDN adapters
[    1.320378] usbcore: registered new interface driver cdc_wdm
[    1.326182] usbcore: registered new interface driver usb-storage
[    1.332380] usbcore: registered new interface driver usbserial
[    1.338270] usbcore: registered new interface driver usbserial_generic
[    1.344890] usbserial: USB Serial support registered for generic
[    1.351377] mousedev: PS/2 mouse device common for all mice
[    1.357104] i2c /dev entries driver
[    1.362053] hidraw: raw HID events driver (C) Jiri Kosina
[    1.367697] usbcore: registered new interface driver usbhid
[    1.373360] usbhid: USB HID core driver
[    1.379292] NET: Registered protocol family 10
[    1.400867] sit: IPv6 over IPv4 tunneling driver
[    1.406535] NET: Registered protocol family 17
[    1.411258] Key type dns_resolver registered
[    1.416977] registered taskstats version 1
[    1.421148] Loading compiled-in X.509 certificates
[    1.426045] zswap: loaded using pool lzo/zbud
[    1.432601] Key type encrypted registered
[    1.437555] ubi0: attaching mtd1
[    1.490168] ata1: SATA link up 1.5 Gbps (SStatus 113 SControl 310)
[    1.541337] ata1.00: HPA detected: current 156299375, native 156301488
[    1.547852] ata1.00: ATA-7: ST380815AS, 3.AAC, max UDMA/133
[    1.553433] ata1.00: 156299375 sectors, multi 0: LBA48 NCQ (depth 0/32)
[    1.585902] ubi0: scanning is finished
[    1.589803] ubi0 error: ubi_read_volume_table: the layout volume was not found
[    1.597975] ubi0 error: ubi_attach_mtd_dev: failed to attach mtd1, error -22
[    1.605127] UBI error: cannot attach mtd1
[    1.605127] ata1.00: configured for UDMA/133
[    1.630561] scsi 0:0:0:0: Direct-Access     ATA      ST380815AS       C    PQ: 0 ANSI: 5
[    1.640230] sd 0:0:0:0: [sda] 156299375 512-byte logical blocks: (80.0 GB/74.5 GiB)
[    1.649024] sd 0:0:0:0: [sda] Write Protect is off
[    1.654110] sd 0:0:0:0: [sda] Write cache: enabled, read cache: enabled, doesn't support DPO or FUA
[    1.689914]  sda: sda1 sda2 sda3
[    1.695946] sd 0:0:0:0: [sda] Attached SCSI disk
[    1.725816] EXT4-fs (sda2): mounted filesystem with ordered data mode. Opts: (null)
[    1.733619] VFS: Mounted root (ext4 filesystem) readonly on device 8:2.
[    1.759375] devtmpfs: mounted
[    1.762757] Freeing unused kernel memory: 224K (c0828000 - c0860000)
INIT: version 2.88 booting
[info] Using makefile-style concurrent boot in runlevel S.
ERROR: could not open /proc/stat: No such file or directory
findfs: unable to resolve 'LABEL=rootfs'
[....] Starting the hotplug events dispatcher: systemd-udevdstarting version 232
[    3.621841] random: systemd-udevd: uninitialized urandom read (16 bytes read, 47 bits of entropy available)
[    3.668349] random: systemd-udevd: uninitialized urandom read (16 bytes read, 49 bits of entropy available)
[    3.678656] random: systemd-udevd: uninitialized urandom read (16 bytes read, 49 bits of entropy available)
[    3.688972] random: systemd-udevd: uninitialized urandom read (16 bytes read, 49 bits of entropy available)
.
[....] Synthesizing the initial hotplug events...[    3.762944] random: udevadm: uninitialized urandom read (16 bytes read, 52 bits of entropy available)
[    3.775203] random: udevadm: uninitialized urandom read (16 bytes read, 53 bits of entropy available)
[    3.784747] random: udevadm: uninitialized urandom read (16 bytes read, 53 bits of entropy available)
[    3.795445] random: udevadm: uninitialized urandom read (16 bytes read, 53 bits of entropy available)
[    3.812577] random: udevadm: uninitialized urandom read (16 bytes read, 53 bits of entropy available)
[    3.823155] random: udevadm: uninitialized urandom read (16 bytes read, 53 bits of entropy available)
done.
[ ok ] Waiting for /dev to be fully populated...done.
[ ok ] Activating swap...done.
[    6.283837] EXT4-fs (sda2): re-mounted. Opts: (null)
[....] Checking root file system...fsck from util-linux 2.29.2
rootfs: clean, 14006/262144 files, 294854/1048576 blocks
done.
[    6.654067] EXT4-fs (sda2): re-mounted. Opts: errors=remount-ro
[ ok ] Activating lvm and md swap...done.
[....] Checking file systems...fsck from util-linux 2.29.2
done.
[    8.065937] random: nonblocking pool is initialized
[ ok ] Loading kernel modules...done.
[ ok ] Cleaning up temporary files... /tmp.
[ ok ] Mounting local filesystems...done.
[ ok ] Activating swapfile swap...done.
[ ok ] Cleaning up temporary files....
[ ok ] Setting kernel variables...done.
[....] Configuring network interfaces...Internet Systems Consortium DHCP Client 4.3.5
Copyright 2004-2016 Internet Systems Consortium.
All rights reserved.
For info, please visit https://www.isc.org/software/dhcp/

Listening on LPF/eth0/11:11:11:11:11:11
Sending on   LPF/eth0/11:11:11:11:11:11
Sending on   Socket/fallback
DHCPREQUEST of 192.168.0.16 on eth0 to 255.255.255.255 port 67
[   15.600320] oxnas-gmac 40400000.ethernet eth0: Link is Up - 1Gbps/Full - flow control rx/tx
DHCPREQUEST of 192.168.0.16 on eth0 to 255.255.255.255 port 67
DHCPNAK from 192.168.3.1
DHCPDISCOVER on eth0 to 255.255.255.255 port 67 interval 6
DHCPREQUEST of 192.168.3.179 on eth0 to 255.255.255.255 port 67
DHCPOFFER of 192.168.3.179 from 192.168.3.1
DHCPACK of 192.168.3.179 from 192.168.3.1
bound to 192.168.3.179 -- renewal in 21183 seconds.
invoke-rc.d: could not determine current runlevel
Stopping Avahi mDNS/DNS-SD Daemon: avahi-daemon.
done.
[ ok ] Starting RPC port mapper daemon: rpcbind.
[ ok ] Starting NFS common utilities: statd idmapd.
[ ok ] Cleaning up temporary files....
INIT: Entering runlevel: 2
[info] Using makefile-style concurrent boot in runlevel 2.
[....] Starting busybox' syslogd implementation : syslogdStarting /sbin/syslogd...
1196 (syslogd)
. ok
[ ok ] Starting NFS common utilities: statd idmapd.
[ ok ] Starting system message bus: dbus.
[warn] Not starting NFS kernel daemon: no exports. ... (warning).
[....] Starting Avahi mDNS/DNS-SD Daemon: avahi-daemon[....] avahi-daemon disabled because there is a unicast [warnl domain ... (warning).
[ ok ] Starting OpenBSD Secure Shell server: sshd.
[....] Starting busybox' klogd implementation : klogdStarting /sbin/klogd...
1199 (klogd)
. ok
[ ok ] Starting NTP server: ntpd.

Debian GNU/Linux 9 debian ttyS0

debian login: root
Password:
Last login: Tue Aug  1 17:15:07 PDT 2017 from 192.168.0.220 on pts/0
Linux debian 4.4.54-oxnas-tld-1 #2 SMP PREEMPT Sat Mar 18 23:09:58 PDT 2017 armv6l

The programs included with the Debian GNU/Linux system are free software;
the exact distribution terms for each program are described in the
individual files in /usr/share/doc/*/copyright.

Debian GNU/Linux comes with ABSOLUTELY NO WARRANTY, to the extent
permitted by applicable law.
root@debian:~#
[свернуть]

cat /etc/*-release

Код:
root@debian:~# cat /etc/*-release
PRETTY_NAME="Debian GNU/Linux 9 (stretch)"
NAME="Debian GNU/Linux"
VERSION_ID="9"
VERSION="9 (stretch)"
ID=debian
HOME_URL="https://www.debian.org/"
SUPPORT_URL="https://www.debian.org/support"
BUG_REPORT_URL="https://bugs.debian.org/"
[свернуть]

Вот ток не пойму про systemd, сообщение что означает в логе:

"random: systemd-udevd: uninitialized urandom read"
"random: udevadm: uninitialized urandom read"

Автор пишет что нужно через uboot
Код:
init=/bin/systemd
Но у меня uboot другой, с загрузкой с sata hdd

Последний раз редактировалось sakatgg; 13.02.2018 в 22:27.
sakatgg вне форума   Ответить с цитированием
Старый 13.02.2018, 22:14   #14
sunny
Senior Member
 
Аватар для sunny
 
Регистрация: 22.10.2015
Адрес: Там где сосны и песок
Сообщений: 1,534
Вес репутации: 1600
sunny is a name known to allsunny is a name known to allsunny is a name known to allsunny is a name known to allsunny is a name known to allsunny is a name known to all
По умолчанию

Поиск по "random: systemd-udevd: uninitialized urandom read" вроде бездонный..
https://www.google.com/search?client...utf-8&oe=utf-8
Вроде как сообщают о баге..
__________________
Читаю ваши мысли по аватару ...
sunny вне форума   Ответить с цитированием
Старый 13.02.2018, 22:57   #15
sakatgg
Senior Member
 
Регистрация: 15.07.2014
Сообщений: 939
Вес репутации: 989
sakatgg is just really nicesakatgg is just really nicesakatgg is just really nicesakatgg is just really nicesakatgg is just really nice
По умолчанию

Установка ядра Linux Kernel 4.4.89 Oxnas (OX820)

1. Качаем с этой страницы архив linux-4.4.89-oxnas-tld-1.bodhi.tar.bz2 (от 06 Oct 2017)

2. Извлекаем:
Код:
cd /boot
tar -xjf linux-4.4.89-oxnas-tld-1.bodhi.tar.bz2
3. Извлекаем dtb файл, для Iconbit I-STOR IS608 используется ox820-pogoplug-classic.dtb (без PCI WiFi)
Он из себя представляет файл *.dts, преобразованный в бинарный *.dtb
Код:
tar -xf linux-dtb-4.4.89-oxnas-tld-1.tar
4. Устанавливаем:
Код:
dpkg -i linux-image-4.4.89-oxnas-tld-1_1.0_armel.deb
headers - я пока не ставил, вроде и так работает, если надо, то так:
Код:
dpkg -i linux-headers-4.4.89-oxnas-tld-1_1.0_armel.deb
5. Создаём uImage и uInitrd вручную, сначало бекапим на всякий случай:
Код:
cd /boot
mv uImage uImage.bak
mv uInitrd uInitrd.bak
Инсталлируем:
Код:
mkimage -A arm -O linux -T kernel -C none -a 0x60008000 -e 0x60008000 -n linux-dtb-4.4.89-oxnas-tld-1 -d vmlinuz-4.4.89-oxnas-tld-1 uImage
mkimage -A arm -O linux -T ramdisk -C gzip -a 0x60000000 -e 0x60000000 -n initramfs-4.4.89-oxnas-tld-1  -d initrd.img-4.4.89-oxnas-tld-1 uInitrd
6. Перезагружаемся:
Код:
reboot
Спасибо говорим bodhi

Последний раз редактировалось sakatgg; 14.02.2018 в 00:43.
sakatgg вне форума   Ответить с цитированием
Старый 13.02.2018, 23:25   #16
sakatgg
Senior Member
 
Регистрация: 15.07.2014
Сообщений: 939
Вес репутации: 989
sakatgg is just really nicesakatgg is just really nicesakatgg is just really nicesakatgg is just really nicesakatgg is just really nice
По умолчанию

Кросс-компиляция ядра ARM для Oxnas (OX820) из под Debian 8

Можно конечно использовать готовое ядро по ссылке выше. Для тех, кто хочет собрать со своим конфигом:

Готовый кросс-компилятор для ARM из репозитория:

Информация отсюда CrossToolchains

1. Создаем /etc/apt/sources.list.d/crosstools.list
Код:
deb http://emdebian.org/tools/debian/ jessie main
2. Устанавливаем:
Код:
sudo apt-get install curl
curl http://emdebian.org/tools/debian/emdebian-toolchain-archive.key | sudo apt-key add -
Код:
sudo dpkg --add-architecture armel
sudo apt-get update
sudo apt-get install crossbuild-essential-armel
В результате установиться кросс-компилятор arm-linux-gnueabi- в среде Debian


Компиляция ядра ARM

1. Качаем исходник нужного ядра www.kernel.org

2. Извлекаем в папку в /user/
Код:
xz -cd linux-4.4.89.tar.xz | tar xvf -
3. Патчим, сам патч взять из архива выше linux-4.4.89-oxnas-tld-1.bodhi.tar.bz2
Код:
patch -p1 < linux-4.4.89-oxnas-tld-1.patch
4. Выполняем:
Код:
export ARCH=arm
export CROSS_COMPILE=arm-linux-gnueabi-
5. Выполняем очистку:
Код:
make mrproper
make clean
6. Конфиг ядра config-4.4.89-oxnas-tld-1 (из архива с патчем) переименовать в .config и копируем в папку с sources.

make menuconfig не делать, если нужен точно как у автора.
Если нужно поднастроить под себя, то запускаем и сохраняем.

7. Запускаем кросс-компиляцию:
Код:
DEB_HOST_ARCH=armel make-kpkg --rootcmd fakeroot -j 5 --cross-compile arm-linux-gnueabi- --append-to-version=-oxnas --revision=1.0 --initrd kernel_image kernel_headers --arch arm
Будут предупреждение, не обращаем внимание.
Мож кто подскажет, какой ключ использовать, чтобы игнорировалось сообщение.
Код:
dpkg-architecture: предупреждение: указанный системный тип GNU arm-linux-gnu не совпадает с системным типом gcc x86_64-linux-gnu, попробуйте задать правильное значение в переменной окружения CC
Полученные linux-headers-4.4.89-oxnas-tld-1_1.0_armel.deb и linux-image-4.4.89-oxnas-tld-1_1.0_armel.deb будут находиться вверх по дереву каталога исходника

Обновился на NAS - вроде встало без проблем и ошибок.
Если кто найдет ошибки, подправлю.


Сделать dtb файл

Код:
export ARCH=arm
export CROSS_COMPILE=arm-linux-gnueabi-
make ox820-pogoplug-classic.dtb
Будет находиться здесь .../linux-4.4.89/arch/arm/boot/dts/

Дополнительно:
Если нужно перекомпилировать все ядро ​​с нуля, то:
Код:
make distclean

Последний раз редактировалось sakatgg; 14.02.2018 в 01:06.
sakatgg вне форума   Ответить с цитированием
Старый 20.02.2018, 04:14   #17
sakatgg
Senior Member
 
Регистрация: 15.07.2014
Сообщений: 939
Вес репутации: 989
sakatgg is just really nicesakatgg is just really nicesakatgg is just really nicesakatgg is just really nicesakatgg is just really nice
По умолчанию

Включение поддержки RTC (Real Time Clock)

На плате находиться модуль DS1307/ST M41T00, с подпиткой от литиевой батарейки 3.3В.
В ядре linux-4.4.89-oxnas-tld-1.bodhi не включена поддержка RTC.
Попросил чтобы bodhi в следующем релизе включил в .config.
Код:
Device Drivers -> Real Time Clock -> Dallas/Maxim DS1307/37/38/39/40, ST M41T00, EPSON RX-8025
Скомпилил пока сам. Как поставить само ядро на систему выше писал.


Настройки Uboot (serial port)

В uboot подключаем профиль ox820-akitio.dtb (находятся в /boot/dts), он более подходит для Iconbit I-STOR IS608 (включен RTC)
но т.к. он по умолчанию не грузит корректно ядро с sata HDD, то прописываем непосредственно в uboot bootargs
Код:
OX820 # setenv bootargs "console=ttyS0,115200 root=/dev/sda2 rootfstype=ext4 ubi.mtd=data,512"
Прописываем профиль
Код:
OX820 # setenv ext4_dtb ext4load ide 0:2 61000000 /boot/dts/ox820-akitio.dtb
Сохраняем, иначе при перезагрузке останется по старому.
Код:
OX820 # saveenv
Saving Environment to FAT...
writing u-boot.env
done
Посмотреть какие настройки записаны в uboot (u-boot.env)

printenv

Код:
OX820 # printenv
SET_dtb=fdt addr ${fdtaddr} ; fdt header
autoload=no
baudrate=115200
bootargs=console=ttyS0,115200 root=/dev/sda2 rootfstype=ext4 ubi.mtd=data,512
bootcmd=run ideboot
bootdelay=3
bootnew=bootm 60000000 - 61000000
bootold=bootm 60000000
console=console=ttyS0,115200n8
ethact=mii0
ethaddr=74:F0:6D:6A:1D:17
ext2_dtb=ext2load ide 0:2 61000000 /boot/dts/ox820-pogoplug-classic.dtb
ext2_ideboot=run ext2_uimage ; run ext2_dtb ; run SET_dtb ; run bootnew
ext2_uimage=ext2load ide 0:2 60000000 /boot/uImage
ext4_dtb=ext4load ide 0:2 61000000 /boot/dts/ox820-akitio.dtb
ext4_ideboot=run ext4_uimage ; run ext4_dtb ; run SET_dtb ; run bootnew
ext4_uimage=ext4load ide 0:2 60000000 /boot/uImage
fdtaddr=61000000
filesize=3eb330
ideboot=run ext4_ideboot
idebootold=${loadold} ;${bootold}
imgaddr=60000000
ipaddr=10.0.0.71
keypressed=1
mtdids=nand0=41000000.nand
mtdparts=mtdparts=41000000.nand:14m(boot),-(data)
netcon=echo switch to net console;setenv stderr nc;setenv stdin nc;setenv stdout nc;echo switch to net console
preboot=run safeboot
serialcon=echo switch to serial console;setenv stderr serial;setenv stdin serial;setenv stdout serial;echo switch to serial console
stderr=serial
stdin=serial
stdout=serial
updboot=bootp;tftp 60000000 u-boot.img;ide write 60000000 400 400

Environment size: 1339/16380 bytes
OX820 #
[свернуть]

Загружаемся, Log serial port


Проверяем работу RTC
Код:
root@debian:~# dmesg | grep "rtc"
[    1.452633] hctosys: unable to open rtc device (rtc0)
[    6.231418] rtc-ds1307 0-0068: rtc core: registered ds1307 as rtc0
[    6.237619] rtc-ds1307 0-0068: 56 bytes nvram
Код:
root@debian:~# hwclock -r
2018-02-15 18:59:55.672925-0800
root@debian:~#

GPIO I2C

Код:
root@debian:~# mount -t debugfs none /sys/kernel/debug
root@debian:~# cat /sys/kernel/debug/gpio
GPIOs 0-31, platform/44000000.gpio, 44000000.gpio:
[?] GPIO44000000.gpio11: [gpio] clear
[?] GPIO44000000.gpio29: [gpio] clear

GPIOs 32-49, platform/44100000.gpio, 44100000.gpio:
[?] GPIO44100000.gpio6: [gpio] clear
[sda] GPIO44100000.gpio9: [gpio] clear
[scl] GPIO44100000.gpio10: [gpio] clear
[?] GPIO44100000.gpio13: [gpio] clear
root@debian:~# i2cdetect 0
WARNING! This program can confuse your I2C bus, cause data loss and worse!
I will probe file /dev/i2c-0.
I will probe address range 0x03-0x77.
Continue? [Y/n] y
     0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
00:          -- -- -- -- -- -- -- -- -- -- -- -- --
10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
20: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
40: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
50: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
60: -- -- -- -- -- -- -- -- 68 -- -- -- -- -- -- --
70: -- -- -- -- -- -- -- --
root@debian:~#
[свернуть]

Правда при первом включении
Код:
6.118259] rtc-ds1307: probe of 0-0068 failed with error -5
6.139243] i2c-gpio i2c-gpio: using pins 41 (SDA) and 42 (SCL)
Но после
Код:
reboot
все нормально.


Подключение второго SATA Hdd

Тут все сразу подключилось.

Log

Код:
root@debian:~# dmesg | grep ata
[    0.000000] CPU: PIPT / VIPT nonaliasing data cache, VIPT aliasing instruction cache
[    0.000000] Memory policy: Data cache writealloc
[    0.000000] Kernel command line: console=ttyS0,115200n8 root=/dev/sda2 rootfstype=ext4 ubi.mtd=data,512
[    0.000000] Memory: 121768K/131072K available (5676K kernel code, 285K rwdata, 1572K rodata, 228K init, 243K bss, 9304K reserved, 0K cma-reserved)
                     .data : 0xc0756000 - 0xc079d718   ( 286 kB)
[    0.280798] libata version 3.00 loaded.
[    0.941416] scsi host0: sata_oxnas
[    0.945635] scsi host1: sata_oxnas
[    0.949521] ata1: SATA max UDMA/133 irq 7
[    0.953571] ata2: SATA max UDMA/133 irq 7
[    0.957672] sata_oxnas: resetting SATA core
[    1.432427] UBI error: cannot open mtd data, error -2
[    1.510164] ata1: SATA link up 1.5 Gbps (SStatus 113 SControl 310)
[    1.559864] ata1.00: HPA detected: current 156299375, native 156301488
[    1.566410] ata1.00: ATA-7: ST380815AS, 3.AAC, max UDMA/133
[    1.571980] ata1.00: 156299375 sectors, multi 0: LBA48 NCQ (depth 0/32)
[    1.618193] ata1.00: configured for UDMA/133
[    1.658398] sata_oxnas: resetting SATA core
[    1.700067] sata_oxnas: resetting SATA core
[    2.460019] ata1: exception Emask 0x10 SAct 0x0 SErr 0x0 action 0xe frozen
[    2.466885] ata1: hard resetting link
[    2.939985] ata2: SATA link up 3.0 Gbps (SStatus 123 SControl 300)
[    2.974671] ata2.00: HPA detected: current 312579695, native 312581808
[    2.981253] ata2.00: ATA-8: ST3160813AS, CC2J, max UDMA/133
[    2.986803] ata2.00: 312579695 sectors, multi 0: LBA48 NCQ (depth 0/32)
[    3.035130] ata2.00: configured for UDMA/133
[    3.390005] ata1: SATA link up 1.5 Gbps (SStatus 113 SControl 310)
[    3.484075] ata1.00: configured for UDMA/133
[    3.488348] ata1: EH complete
[    3.591311] EXT4-fs (sda2): mounted filesystem with ordered data mode. Opts: (null)
[   11.171427] FAT-fs (sda1): Volume was not properly unmounted. Some data may be corrupt. Please run fsck.
root@debian:~#
[свернуть]

Ругается на FAT-fs (sda1), где находиться uboot, но вроде проблем нет.

Log

Код:
root@debian:df
Filesystem     1K-blocks    Used Available Use% Mounted on
/dev/root        3997376 1154840   2616440  31% /
devtmpfs           60884       0     60884   0% /dev
tmpfs              12200     148     12052   2% /run
tmpfs               5120       0      5120   0% /run/lock
tmpfs              24380       0     24380   0% /run/shm
tmpfs              60996       0     60996   0% /tmp
/dev/sda3       72776020 6179936  62899188   9% /home
/dev/sda1          16334     518     15816   4% /mnt
root@debian:/etc# ls /mnt
.  ..  u-boot.env  u-boot.img
root@debian:/etc# cp fstab /mnt
root@debian:/etc# ls /mnt
.  ..  fstab  u-boot.env  u-boot.img
root@debian:/etc#
[свернуть]

Последний раз редактировалось sakatgg; 20.02.2018 в 04:33.
sakatgg вне форума   Ответить с цитированием
Старый 21.02.2018, 02:29   #18
sakatgg
Senior Member
 
Регистрация: 15.07.2014
Сообщений: 939
Вес репутации: 989
sakatgg is just really nicesakatgg is just really nicesakatgg is just really nicesakatgg is just really nicesakatgg is just really nice
По умолчанию

Подключение WiFi usb


Устанавливаем wpasupplicant
Код:
apt-get install wpasupplicant
Устанавливаем firmware-ralink для TEW-684UB, DWA-140 rev B2, TEW-664-UB
Код:
apt-get install firmware-ralink
Или просто скопировать rt2870.bin в /lib/firmware/4.4.89-oxnas-tld-1/

Добавляем в /etc/network/interfaces
Код:
auto wlx111111111111
iface wlx111111111111 inet dhcp
wpa-ssid Wrt
wpa-psk openwrtopenwrt
wlx111111111111 - интерфейс WiFi в Debian stretch
111111111111 - MAC WiFi usb свистка.

Log инициализации WiFi свистков

Код:
TEW-684UB

[  127.520281] usb 1-2: new high-speed USB device number 2 using oxnas-ehci
[  127.686799] usb 1-2: New USB device found, idVendor=148f, idProduct=3573
[  127.693529] usb 1-2: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[  127.700712] usb 1-2: Product: 802.11 n WLAN
[  127.705100] usb 1-2: Manufacturer: Ralink
[  127.709102] usb 1-2: SerialNumber: 1.0
[  127.990028] usb 1-2: reset high-speed USB device number 2 using oxnas-ehci
[  128.149688] ieee80211 phy0: rt2x00_set_rt: Info - RT chipset 3593, rev 0402 detected
[  128.186296] ieee80211 phy0: rt2x00_set_rf: Info - RF chipset 000d detected
[  128.198382] usbcore: registered new interface driver rt2800usb

DWA-140 rev B2

[  235.971694] usb 1-2: USB disconnect, device number 2
[  254.000053] usb 1-2: new high-speed USB device number 3 using oxnas-ehci
[  254.166174] usb 1-2: New USB device found, idVendor=07d1, idProduct=3c0a
[  254.172904] usb 1-2: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[  254.180096] usb 1-2: Product: 11n Adapter
[  254.184094] usb 1-2: Manufacturer: Ralink
[  254.188085] usb 1-2: SerialNumber: 1.0
[  254.320058] usb 1-2: reset high-speed USB device number 3 using oxnas-ehci
[  254.479685] ieee80211 phy1: rt2x00_set_rt: Info - RT chipset 3071, rev 0213 detected
[  254.516418] ieee80211 phy1: rt2x00_set_rf: Info - RF chipset 0008 detected

TEW-664-UB

[  316.629611] usb 1-2: USB disconnect, device number 3
[  325.350074] usb 1-2: new high-speed USB device number 4 using oxnas-ehci
[  325.518046] usb 1-2: New USB device found, idVendor=148f, idProduct=2870
[  325.524779] usb 1-2: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[  325.531962] usb 1-2: Product: 802.11 n WLAN
[  325.536135] usb 1-2: Manufacturer: Ralink
[  325.540160] usb 1-2: SerialNumber: 1.0
[  325.670077] usb 1-2: reset high-speed USB device number 4 using oxnas-ehci
[  325.831057] ieee80211 phy2: rt2x00_set_rt: Info - RT chipset 2872, rev 0202 detected
[  325.893309] ieee80211 phy2: rt2x00_set_rf: Info - RF chipset 0002 detected
[свернуть]


dmesg iwconfig

Код:
root@debian:~# dmesg | grep wlx
[    7.728220] rt2800usb 1-2:1.0 wlx111111111111: renamed from wlan0
[   95.147371] IPv6: ADDRCONF(NETDEV_UP): wlx111111111111: link is not ready
[  102.365614] wlx111111111111: authenticate with 11:11:11:11:11:11
[  102.427722] wlx111111111111: send auth to 11:11:11:11:11:11 (try 1/3)
[  102.435392] wlx111111111111: authenticated
[  102.450068] wlx111111111111: associate with 11:11:11:11:11:11 (try 1/3)
[  102.458001] wlx111111111111: RX AssocResp from 11:11:11:11:11:11 (capab=0x11 status=0 aid=1)
[  102.475599] IPv6: ADDRCONF(NETDEV_CHANGE): wlx111111111111: link becomes ready
[  102.482856] wlx111111111111: associated
root@debian:~# iwconfig
wlx111111111111  IEEE 802.11abgn  ESSID:"Wrt"
          Mode:Managed  Frequency:5.18 GHz  Access Point: 11:11:11:11:11:11
          Bit Rate=90 Mb/s   Tx-Power=20 dBm
          Retry short limit:7   RTS thr:off   Fragment thr:off
          Encryption key:off
          Power Management:off
          Link Quality=50/70  Signal level=-60 dBm
          Rx invalid nwid:0  Rx invalid crypt:0  Rx invalid frag:0
          Tx excessive retries:0  Invalid misc:26   Missed beacon:0

sit0      no wireless extensions.

lo        no wireless extensions.

eth0      no wireless extensions.

root@debian:~#
[свернуть]


Переводим интерфейс WiFi в wlan0


Копируем /lib/udev/rules.d/80-net-setup-link.rules в /etc/udev/rules.d/

Заменяем строку в /etc/udev/rules.d/80-net-setup-link.rules
Код:
NAME=="", ENV{ID_NET_NAME}!="", NAME="$env{ID_NET_NAME}"
на
Код:
NAME=="", ENV{ID_NET_NAME}!="", NAME="wlan0"

iwconfig

Код:
root@debian:~# iwconfig
wlan0     IEEE 802.11abgn  ESSID:"Wrt"
          Mode:Managed  Frequency:5.18 GHz  Access Point: 11:11:11:11:11:11
          Bit Rate=6 Mb/s   Tx-Power=20 dBm
          Retry short limit:7   RTS thr:off   Fragment thr:off
          Encryption key:off
          Power Management:off
          Link Quality=48/70  Signal level=-62 dBm
          Rx invalid nwid:0  Rx invalid crypt:0  Rx invalid frag:0
          Tx excessive retries:0  Invalid misc:25   Missed beacon:0

sit0      no wireless extensions.

lo        no wireless extensions.

eth0      no wireless extensions.

root@debian:~#
[свернуть]


Теперь NAS подключен по WiFi
Миниатюры
Нажмите на изображение для увеличения
Название: NAS WiFi 1a.jpg
Просмотров: 141
Размер:	159.3 Кб
ID:	4862  

Последний раз редактировалось sakatgg; 21.02.2018 в 02:58.
sakatgg вне форума   Ответить с цитированием
Старый 24.02.2018, 02:44   #19
sakatgg
Senior Member
 
Регистрация: 15.07.2014
Сообщений: 939
Вес репутации: 989
sakatgg is just really nicesakatgg is just really nicesakatgg is just really nicesakatgg is just really nicesakatgg is just really nice
По умолчанию

Установка motion и вебкамеры

Код:
apt-get install motion
Настройка /etc/motion/motion.conf, изменил ток эти параметры:
Код:
v4l2_palette 17
width 640
height 480
framerate 15
output_pictures off
ffmpeg_video_codec mkv
target_dir /home/Motion
Камера инициализируется как /dev/video0 (в ядре поддержка включена)

Запускаем
Код:
motion
Нормально *.mkv 15кадров/сек пишет. Качество на mkv заметно лучше и размер меньше.
В top проц загружен при движении до 138% (mkv) и 100% (mp4)

Вебкамеры проверил Logitech С110, С270, С510.
При запуске motion, когда движения нет, загрузка проца на С110 - 20%, на остальных 25%.


P.S. Чтобы попасть в web просмотр (8081) и web setup (8080), ставим в motion.conf и заходим, например 192.168.3.179:8081 в браузере.
Код:
stream_localhost off
webcontrol_localhost off
При просмотре проц грузится 90-100% (640х480х30) и это при отключеном детекте движения в motion.conf.
Код:
ffmpeg_output_movies off
Поток похоже процом ужимается, где-то 170-250кбайт.
С одной стороны хорошо, меньше траффик, с другой проц грузится.

Наверное для просмотра в локалке лучше юэать mjpg-streamer, но в репе Debian stretch его нет.


Демоном не запускается, пробовал в motion.conf
Код:
daemon on
В /etc/default/motion
Код:
start_motion_daemon=yes
Не стартует
Код:
root@debian:~# /etc/init.d/motion start
[ ok ] Starting motion detection daemon: motion.
root@debian:~# /etc/init.d/motion status
[FAIL] motion is not running ... failed!
root@debian:~#
Не стартует демоном и после перезагрузки


sunny, Спасибо за скрипт и работу по скинам к openwrt, симпотно серо-черные выглядят


Номерация GPIO

Код:
 11 (A11) green1 (hdd1) 
 25 (A25) reset (button) 
 27 (A27) copy (button) 
 28 (A28) red (error) 
 29 (A29) blue (OS) 
 38 (B6) green2 (hdd2) 
 39 (B7) orange (copy) 
 41 (B9) sda (i2c) 
 42 (B10) scl (i2c)
Кнопка Power OFF/ON с gpio не связана. Похоже на проц хардварно заведена.
Если выключать NAS командой poweroff, то выключается полностью и включить можно с этой кнопки.

Расположение на передней панели моем Iconbit I-STOR IS608, такое же, как и на Akitio MyCloud Duo
Миниатюры
Нажмите на изображение для увеличения
Название: Akitio MyCloud Duo.jpg
Просмотров: 132
Размер:	33.8 Кб
ID:	4876  

Последний раз редактировалось sakatgg; 24.02.2018 в 21:35.
sakatgg вне форума   Ответить с цитированием
Старый 24.02.2018, 12:25   #20
sunny
Senior Member
 
Аватар для sunny
 
Регистрация: 22.10.2015
Адрес: Там где сосны и песок
Сообщений: 1,534
Вес репутации: 1600
sunny is a name known to allsunny is a name known to allsunny is a name known to allsunny is a name known to allsunny is a name known to allsunny is a name known to all
По умолчанию

Скрипт для сортировки файлов по времени и дате для debian:
Код:
#!/bin/sh

SRC_DIR="/home/user/Папка в которую пишет motion"
DST_DIR="/home/user/Папка в которой файлы сортируются по времени и дате/$(date +%Y-%m-%d)/$(date +%Y-%m-%d_%H)"
for F in ${SRC_DIR}/*; do
	SUB=$("$(stat -c%y "${F}")" +%Y%m%d)
	mkdir -p "${DST_DIR}/${SUB}"
	mv "${F}" "${DST_DIR}/${SUB}/"
done
Можно еще alsa поставить и звук писать...
Вложения
Тип файла: txt ssort.txt (237 байт, 138 просмотров)
__________________
Читаю ваши мысли по аватару ...

Последний раз редактировалось sunny; 24.02.2018 в 13:00.
sunny вне форума   Ответить с цитированием
Ответ


Здесь присутствуют: 8 (пользователей: 0 , гостей: 8)
 
Опции темы Поиск в этой теме
Поиск в этой теме:

Расширенный поиск
Опции просмотра

Ваши права в разделе
Вы не можете создавать новые темы
Вы не можете отвечать в темах
Вы не можете прикреплять вложения
Вы не можете редактировать свои сообщения

BB коды Вкл.
Смайлы Вкл.
[IMG] код Вкл.
HTML код Выкл.

Быстрый переход


Текущее время: 17:40. Часовой пояс GMT +3.


Powered by vBulletin® Version 3.8.5
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd. Перевод: zCarot
Яндекс.Метрика