Jump to content
XPEnology Community

Aigor

Member
  • Posts

    690
  • Joined

  • Last visited

  • Days Won

    6

Everything posted by Aigor

  1. They publish their source kernel
  2. Continuing investigation i have a problem, i can boot bzimage with initrd.boot as initramfs, but i'm running into some trouble. here is how i did First, download X86 firmware from Qnap site unzip and you obtain a encrypted image file you can decrypt using program posted on first post with this commandline root@dev-linux:/opt/qnap#unzip SS-2479U_20160812-4.2.2.zip Archive: SS-2479U_20160812-4.2.2.zip inflating: SS-2479U_20160812-4.2.2.img Now we can decrypt image file into tar.gz archive root@dev-linux:/opt/qnap#pc1 d QNAPNASVERSION4 SS-2479U_20160812-4.2.2.img SS-2479U_20160812-4.2.2.tar.gz Using 120-bit encryption - (QNAPNASVERSION4) len=1048576 model name = SS-2479U version = 4.2.2 root@dev-linux:/opt/qnap#file SS-2479U_20160812-4.2.2.tar.gz SS-2479U_20160812-4.2.2.tar.gz: gzip compressed data, from Unix, last modified: Fri Aug 12 04:05:45 2016 root@dev-linux:/opt/qnap# As you can see we have regular tar.gz archive. Inside we can found all the stuff need to boot something. root@dev-linux:/opt/qnap/appo#ls -l totale 181900 -rw-r--r--. 1 root root 145 12 ago 04.05 bios_layout drwxr-xr-x. 2 root root 6 12 ago 04.05 boot -rw-r--r--. 1 root root 5075008 12 ago 04.05 bzImage -rw-r--r--. 1 root root 70 12 ago 04.05 bzImage.cksum drwxr-xr-x. 2 root root 6 12 ago 04.05 config -rwxr-xr-x. 1 root root 278840 12 ago 04.05 flashrom -rw-r--r--. 1 root root 8388608 12 ago 04.05 flashrom.img -rw-r--r--. 1 root root 33 12 ago 04.05 fw_info -rw-r--r--. 1 root root 12716367 12 ago 04.05 initrd.boot -rw-r--r--. 1 root root 76 12 ago 04.05 initrd.boot.cksum -rw-r--r--. 1 root root 0 12 ago 04.05 IS_STORAGE_V2 -rwxr-xr-x. 1 root root 1655372 12 ago 04.05 libcrypto.so.1.0.0 -rwxr-xr-x. 1 root root 384412 12 ago 04.05 libssl.so.1.0.0 -rw-r--r--. 1 root root 104058880 12 ago 04.05 qpkg.tar -rw-r--r--. 1 root root 74 12 ago 04.05 qpkg.tar.cksum -rw-r--r--. 1 root root 45950458 12 ago 04.05 rootfs2.bz -rw-r--r--. 1 root root 75 12 ago 04.05 rootfs2.bz.cksum -rw-r--r--. 1 root root 7660120 12 ago 04.05 rootfs_ext.tgz -rw-r--r--. 1 root root 78 12 ago 04.05 rootfs_ext.tgz.cksum drwxr-xr-x. 2 root root 4096 12 ago 04.05 sas_fw drwxr-xr-x. 2 root root 6 12 ago 04.05 update -rw-r--r--. 1 root root 108 12 ago 04.05 update_bios.conf -rwxr-xr-x. 1 root root 3438 12 ago 04.05 update_bios.sh -rwxr-xr-x. 1 root root 34017 12 ago 04.05 update_img.sh root@dev-linux:/opt/qnap/appo# You can see bzImage, initrd.boot and two rootfs file, i'm using VM and pxe to boot VM and my command line is KERNEL images/qnap/bzImage APPEND initrd=images/qnap/initrd2.boot root=/dev/ram0 rw Initrd.boot is a lzma cpio archive, inside in we can found a shell file called init root@dev-linux:/opt/qnap/appo/init#ls -l totale 54656 drwxr-xr-x. 2 root root 4096 23 ago 14.57 bin drwxr-xr-x. 5 root root 16384 23 ago 14.57 dev drwxr-xr-x. 27 root root 4096 23 ago 14.57 etc -rwxr-xr-x. 1 root root 255 23 ago 14.57 init -rw-r--r--. 1 root root 55877632 23 ago 14.55 initrd.boot drwxr-xr-x. 4 root root 4096 23 ago 14.57 lib drwxr-xr-x. 2 root root 4096 23 ago 14.57 lib64 lrwxrwxrwx. 1 root root 11 23 ago 14.57 linuxrc -> bin/busybox drwx------. 2 root root 6 23 ago 14.57 lost+found drwxr-xr-x. 4 root root 29 23 ago 14.57 mnt drwxr-sr-x. 2 root root 33 23 ago 14.57 opt lrwxrwxrwx. 1 root root 19 23 ago 14.57 php.ini -> /etc/config/php.ini drwxr-sr-x. 2 root root 6 23 ago 14.57 proc drwxr-xr-x. 3 root root 4096 23 ago 14.57 root drwxr-xr-x. 2 root root 12288 23 ago 14.57 sbin drwxrwxr-x. 29 root root 4096 23 ago 14.57 share drwxrwxrwx. 4 root root 30 23 ago 14.57 tmp drwxr-xr-x. 5 root root 39 23 ago 14.57 usr drwxrwxrwx. 9 root root 4096 23 ago 14.57 var root@dev-linux:/opt/qnap/appo/init# it seems the first program executed after boot is completed #!/bin/sh mkdir new_root mount -t tmpfs -o mode=0755,size=256000k none /new_root /bin/busybox tar -cf - . | tar -xf - -C /new_root /bin/rm -fr /new_root/init /bin/mount -t devtmpfs devtmpfs /new_root/dev exec /bin/busybox switch_root /new_root /sbin/init This is what i discover, but i don't know howto use rootfs2.bz and rootfs_ext.tgz, that are not encrypted
  3. If you want compile Xpenoboot maybe you should use toolchains from Synology
  4. Hi TomS interesting, my knoweldge in docker is poor i'm in "try to understand" In my regular job i work with VM environement
  5. But if you use docker system you obtain a sort of VM, could be interesting make package with rigth options to samba to act AD domain But this involves the use of Dynami Dns to store AD data, have you checked if original Synology samba has the rigth compiled options?
  6. Hi, i don't know if is interesting or not, googoling around the web i found a way to decode qnap firmware, it seems it's similar to synology if anyone is intersted, this is the link https://sites.google.com/site/nliaudat/nas/test2/qnap401t-decryptencryptfirmware
  7. Hi, i think it's a packing problem of the kernel and rd.gz, i tried to setup a VM which boots from network, compile my own kernel, use rd.gz from original Xpenoboot img, same result. What i did extract rd.cpio from Xpenoboot img, expanded in a temp dir, compile kernel without path of rd.cpio into kernel config, compile modules, add new modules comes from kernel compiling to rd.cpio espanded, repack rd into rd.cpio, gzip rd.cpio, copy both bzImage and rd,gz into /tftp on boot server no luck installation error at this point we have to wait kernel dev if they could show us a entire process to build .img in rigth way
  8. Searching on google showme kernel part that need to be included in kernel compiling, but i suspect it's a little beat out of your knoweldge as you said before. try to red viewtopic.php?f=15&t=551
  9. It means they are already loaded, at this point i don't know why you can't shutdown VM in safe way.
  10. cd /lib/modules insmod "name of module.ko"
  11. start VM and after boot is complete load those modules, if you don't see any error, try to shutdown VM
  12. Hi, ssh in your NAS, go in /lib/modules/ check if there are modules with this command DiskStation> pwd /lib/modules DiskStation> DiskStation> find hv* hv_balloon.ko hv_netvsc.ko hv_storvsc.ko hv_vmbus.ko If you have these modules, load them,and try if they work Forgot to mention my version DSM 5.2-5565 Update 2
  13. Aigor

    Working DSM 6

    Do your volume still mounted?
  14. As far i saw there are already compiled as modules in last xpenoboot bootloader Microsoft Hyper-V client drivers Microsoft Hyper-V Balloon driver
  15. Thank you nearffxx but i'm only at the beginning i would like to build complete package but it's almost out of my knoweldge
  16. Good News ! Xpenology Devs release source of their kernel, with this source i have been able to compile SCST subsystem, now i see QLA card on my test-system, next step, try to build LUN, export this LUN to an host and start some test to check stability and performance. To start, you need two systems, one for compiling and other for testing, fisrt one can be virtual but it's' mandatory that the second one must be physical with qla card installed. In the future i need someone who help me build a synology package to handle WWN and LUN in easily way, but it's' another project I'm in writing HowTo in where i explain howto build SCST subsystem against Xpenology source kernel.
  17. Aigor

    [Dev Questiion ]

    I'm using same compiler as toolchain to compile SCST subsystem. My kernel won't boot it stuck after booting kernel with blank screen , assistant can't found any synology Another question, when i use binwalk -e vmlinux, i get a lot of files but i don't know if i have to add them into new image or not
  18. Aigor

    [Dev Questiion ]

    Thank you for info, but i need to test if compiled module is ok, i'v already compiled modules against running kernel, but when try to load i get a error. Suspecting something strange i try to compile inside kernel-tree qla module to test, same result, so there is something wrong, my suspect is that i must use same kernel compiled instead running one , so i need to recompile whole kernel and modules, pack new .img file to test my theory
  19. Aigor

    [Dev Questiion ]

    Thanks for your work, but i would like to know howto extract. I'm trying to add Fiber Channel Support to synology, but i need to use SCST subsystem that involve compile new QLA module, doing using .config extracted from /proc i get an error when i try to load module, so i suspect that i need to use kernel compiled with modules, but without rd.cpio o can't try if i can load module that recognize card i can try write an Howto .
  20. Hi, in which way you have extracted rd.cpio from zImage? I have the same problem for one my project and, maybe i found a way.
  21. Hi, i would like compile my own kernel and modules, i'v already downloaded last bootloader source, but i have a question. Compilation start but stuck ask me someting about rd.cpio that i suppose to be a iniramfs file, where i can find this file? can i use a stock rd.gz from .PAT file with some patch applied ? Where i can find patches? Many thanks
  22. Have you added serial interface on both VM?
  23. Yes, i apologize for incomplete hints. You can create volume AFTER cluster has been created
  24. Aigor

    dsm 6.0

    Funziona bene solo in ambiente virtuale, su ambiente fisico il btrfs non funziona, da quello che ho letto crea il volume ma non lo monta, per cui devi farlo a mano ad ogni reboot. Le opzioni che sono state compilate nel kernel prevedono l'output solo su seriale ecco perche' non vedi nulla. Basta una modifica al syslinux.cfg e si risolve. Configurazione di test Acer Veriton V270 Per installare devi scegliere l'opzione 2 della schermata di boot della chiavetta usb, diversamente, non funziona. Una volta partito usi il sinology assistant e completi l'installazione dandogli in pasto il .pat a mano. Reboot, scegli sempre la seconda opzione del bootloader. In questo modo funziona su hardware fisico, ma continua a non funzionare la creazione del volume SHR su btrfs, non ho verificato la parte ISCsi che nel mio caso sarebbe indispensabile, funziona tutto il resto, il quickconnect non l'ho mai usato, nat/pat sul router e vivo felice.
  25. Thank You, do i need to use some tricks to use this card?
×
×
  • Create New...