| FORUM

FEDEVEL
Platform forum

How to use NGINX at iMx6 TinyRex?

hkkang , 01-29-2018, 07:05 PM
Hello again,

I want to install NGINX on my iMx6 TinyRex to communicate with my host PC via web.
Actually, I think I'm familiar with Linux but the pre-installed OS on the board is very new to me.
Code:
root@imx6-tinyrexultra:~# uname -aLinux imx6-tinyrexultra 4.1.36-yocto+g7f55696 #1 SMP PREEMPT Sat Jul 29 17:36:08 CEST 2017 armv7l armv7l armv7l GNU/Linux
Kernel name seems to be 'yocto', which is for embedded system.. Does anyone have any idea how to make use of NGINX on iMx6 boards?

Thanks in advance
marek , 01-30-2018, 10:59 PM
Dear hkkang,

Yocto way
========
Preinstalled OS is based on Yocto 2.1 or 2.0. It is proprietary version from NXP and the used recipe is called fsl-imx-x11. It is demo image with limited capabilities but it include all NXP libraries and firmware. It is possible to include NGINX since there are many recipes in yocto but it is time consuming. You are basically building your own distribution from scratch.
More info about how the demo images are build is here:
http://wiki.voipac.com/xwiki/bin/vie...+tinyrex/yocto

Debian/Ubuntu way (generally speaking easier, but i do have nothing to provide you)
==============
You need to brand some full size distribution (Debian, Ubuntu) to have the possibility to install various packages. Nothing is prepared in this area by Voipac. Basically you need to load kernel and its device tree and set proper bootargs that points to the root filesystem from that distribution. You should end up with system that is trying to boot at least. You must often modify root filesystem to open serial terminal console by default, store you kernel modules into /lib/modules folder, find and compile video driver to get accelerated desktop. And some other tweaks.

Here are some notes from test that was run in past, just as and example
Code:
mmc dev 0mmc rescanext4load mmc 0:1 ${loadaddr} zImage-imx6-tinyrexmax-2.2.binext4load mmc 0:1 ${fdt_addr} zImage-imx6-tinyrexmax-2.2.dtbsetenv bootargs 'console=ttymxc0,115200 root=/dev/mmcblk2p1 rootwait rw'bootz ${loadaddr} - ${fdt_addr}
http://www.voipac.com/downloads/imx/iMX6_TinyRex/test/tinyrexmax-debian.img.gz This should create SD card image: (SD card size must be >=4G).
Code:
#unzip tinyrexmax-debian.img.gz -> tinyrexmax-debian.imgsudo dd if=tinyrexmax-debian.img of=/dev/sdX bs=4M
hkkang , 01-31-2018, 12:34 AM
Thank you, marek!

I'm more familiar to Ubuntu than Yocto but anyway I will try both!
robertferanec , 01-31-2018, 09:40 AM
@hkkang, have a look also here, maybe this can help: Using a downloaded filesystem (supports apt-get command)
alexmorco , 06-29-2019, 02:32 AM
If you want to set up NGINX with Apache, you need to have the SUDO (root) access to the server and follow the step-by-step guide created by DigitalOcean, one of the best cloud hosting providers out there. Check this: Hosting WordPress on NGINX with Apache Can Be the Best Bet
Use our interactive Discord forum to reply or ask new questions.
Discord invite
Discord forum link (after invitation)

Didn't find what you were looking for?