General NAS-Central Forums

Welcome to the NAS community
It is currently Sun Jun 25, 2017 7:03 pm

All times are UTC




Post new topic Reply to topic  [ 69 posts ]  Go to page 1, 2, 3, 4, 5  Next
Author Message
 Post subject: New package: Entware-ng
PostPosted: Fri Jan 29, 2016 10:20 pm 
Offline

Joined: Mon Jun 16, 2008 10:45 am
Posts: 6002
What is it?
Entware-ng is a software repository for embedded devices like routers and network attached storages. The project is started to offer an alternative for the very outdated Optware packages.

Entware-ng is installed in /opt, and is self containing. The binaries are not dependent on any firmware library, all needed libraries are installed in /opt/lib. Entware-ng is available for ARMv5, ARMv7, Mipsel, x86 and AMD64.

Entware-ng uses the opkg package manager.

Entware-ng has at the moment more than 1800 packages.

Entware-ng vs FFP
Both Entware-ng and FFP are self-containing, and independent of firmware libraries. Entware-ng installs in /opt, FFP in /ffp.

FFP is aging. The base system is unmaintained, and it dates from 2012. 3th party developers are doing a lot of work to update parts of it, but for beginners it's hard to gather the newest packages together, partly due to a missing package management.
Entware-ng is alive and kicking, and it has a proper package management. If you install a package, all it's dependencies are automatically installed either. The same is true for upgrading a package.

FFP is designed for NAS boxes. As on a NAS storage room is seldom an issue, the packages are in most cases not trimmed down. Entware-ng is more or less based on OpenWRT, which is an OS for embedded routers. On those boxes storage and ram are sparse, and for that reason the packages are slimmed down.
For instance, Asterisk on Entware-ng is splitted in 180 subpackages. This way you don't need to use storage room for functionality you don't need. On FFP Asterisk is a single package. This puts the 1800 packages of Entware-ng in perspective.

As FFP is installed in /ffp. and Entware-ng in /opt, they can coexist.

'Old' kernel patch
By default Entware-ng targets kernel 2.6.32 or newer. As our NSA300 boxes have kernel 2.6.31.8, Entware-ng errors out with 'Kernel too old'. To solve this I have rebuild libc with kernel support down to 2.6.24 (The NSA210 and -221 have kernel 2.6.24.4). The libc is the same as the 'stock' one, only some configuration flag is changed. I *think* all binaries depending on libc won't care, at least I couldn't find any problems.

How to install
Install MetaRepository, and Entware-ng should show up in the package list. The first start will take a while, as the base system will have to be downloaded and installed (about 25 MB).

Entware-ng-stick
As a self-containing stick is available here.

It is possible to let the zypkg start Entware-ng from an usb stick. By default it's installed in /usr/local/zy-pkgs/opt/. You can copy (or move) this to an usb stick (need to have an ext file system), and put an (executable) script redirect.sh in the old opt/ directory. The output (stdout) of that script should be the opt directory on the stick.


Top
 Profile  
 
PostPosted: Fri Jan 29, 2016 10:33 pm 
Online

Joined: Sun Apr 29, 2012 5:24 pm
Posts: 2280
Congrats Mijzelf. You did it. ;)
This topic worth to be sticky :!:
It is the future.


Top
 Profile  
 
PostPosted: Sat Jan 30, 2016 6:58 am 
Offline
User avatar

Joined: Mon Dec 21, 2015 7:21 pm
Posts: 594
Amazing! I've just installed on my zyxel nsa320s. It's working fine! :) Nice work!


Top
 Profile  
 
PostPosted: Sun Jan 31, 2016 9:48 am 
Offline
User avatar

Joined: Mon Dec 21, 2015 7:21 pm
Posts: 594
Hi Mijzelf!

I tried to install znc. It was successfull, but I Can't start it...:

Code:
root@NSA320S~# /opt/etc/init.d/S99znc start
chmod: missing operand after `666'
Try `chmod --help' for more information.
 Starting znc...              done.
root@NSA320S:~# /opt/etc/init.d/S99znc check
chmod: missing operand after `666'
Try `chmod --help' for more information.
 Checking znc...              dead.
root@NSA320S:~#


What's missing?

Thanks!

_________________
Thanks nas-central the lot of help! :)


Top
 Profile  
 
PostPosted: Sun Jan 31, 2016 2:03 pm 
Offline

Joined: Mon Jun 16, 2008 10:45 am
Posts: 6002
I guess an uninitialized variable. You can try to execute
Code:
sh -x /opt/etc/init.d/S99znc start
and compare the output with the script source, to find the problem.


Top
 Profile  
 
PostPosted: Sun Jan 31, 2016 2:59 pm 
Offline
User avatar

Joined: Mon Dec 21, 2015 7:21 pm
Posts: 594
Ok. Here is the output:


Code:
root@NSA320S:~# sh -x /opt/etc/init.d/S99znc start
+ find /opt/share/znc/ -type f
+ xargs chmod 666
chmod: missing operand after `666'
Try `chmod --help' for more information.
+ find /opt/share/znc/ -type d
+ xargs chmod 777
+ ENABLED=yes
+ PROCS=znc
+ ARGS='-d /opt/share/znc'
+ PREARGS=
+ DESC=znc
+ PATH=/opt/sbin:/opt/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
+ . /opt/etc/init.d/rc.func
++ ACTION=start
++ CALLER=
++ ansi_red='\033[1;31m'
++ ansi_white='\033[1;37m'
++ ansi_green='\033[1;32m'
++ ansi_yellow='\033[1;33m'
++ ansi_blue='\033[1;34m'
++ ansi_bell='\007'
++ ansi_blink='\033[5m'
++ ansi_std='\033[m'
++ ansi_rev='\033[7m'
++ ansi_ul='\033[4m'
++ for PROC in '$PROCS'
++ case $ACTION in
++ start
++ '[' '' '!=' yes -a '' = cron ']'
++ '[' yes '!=' yes ']'
++ echo -e -n '\033[1;37m Starting znc... '
 Starting znc... +++ pidof znc
++ '[' -n '' ']'
++ COUNTER=0
++ LIMIT=10
+++ pidof znc
++ znc -d /opt/share/znc
++ '[' -z '' -a 0 -le 10 ']'
++ sleep 1
+++ expr 0 + 1
++ COUNTER=1
+++ pidof znc
++ '[' -z '' -a 1 -le 10 ']'
++ sleep 1
+++ expr 1 + 1
++ COUNTER=2
+++ pidof znc
++ '[' -z '' -a 2 -le 10 ']'
++ sleep 1
+++ expr 2 + 1
++ COUNTER=3
+++ pidof znc
++ '[' -z '' -a 3 -le 10 ']'
++ sleep 1
+++ expr 3 + 1
++ COUNTER=4
+++ pidof znc
++ '[' -z '' -a 4 -le 10 ']'
++ sleep 1
+++ expr 4 + 1
++ COUNTER=5
+++ pidof znc
++ '[' -z '' -a 5 -le 10 ']'
++ sleep 1
+++ expr 5 + 1
++ COUNTER=6
+++ pidof znc
++ '[' -z '' -a 6 -le 10 ']'
++ sleep 1
+++ expr 6 + 1
++ COUNTER=7
+++ pidof znc
++ '[' -z '' -a 7 -le 10 ']'
++ sleep 1
+++ expr 7 + 1
++ COUNTER=8
+++ pidof znc
++ '[' -z '' -a 8 -le 10 ']'
++ sleep 1
+++ expr 8 + 1
++ COUNTER=9
+++ pidof znc
++ '[' -z '' -a 9 -le 10 ']'
++ sleep 1
+++ expr 9 + 1
++ COUNTER=10
+++ pidof znc
++ '[' -z '' -a 10 -le 10 ']'
++ sleep 1
+++ expr 10 + 1
++ COUNTER=11
+++ pidof znc
++ '[' -z '' -a 11 -le 10 ']'
+++ pidof znc
++ '[' -z '' ']'
++ echo -e '            \033[1;31m failed. \033[m'
             failed.
++ logger 'Failed to start znc from .'
++ return 255
root@NSA320S:~#

_________________
Thanks nas-central the lot of help! :)


Top
 Profile  
 
PostPosted: Sun Jan 31, 2016 9:46 pm 
Offline

Joined: Mon Jun 16, 2008 10:45 am
Posts: 6002
Seeing
Code:
+ find /opt/share/znc/ -type f
+ xargs chmod 666
chmod: missing operand after `666'
Try `chmod --help' for more information.
I guess the script does
Code:
find /opt/share/znc/ -type f | xargs chmod 666
Don't know why this fails. Does it also fail when executed manually?


Top
 Profile  
 
PostPosted: Mon Feb 01, 2016 1:56 pm 
Offline
User avatar

Joined: Mon Dec 21, 2015 7:21 pm
Posts: 594
Yes. It gives a similar error:

Code:
root@NSA320S:~# find /opt/share/znc/ -type f | xargs chmod 666
chmod: missing operand after `666'
Try `chmod --help' for more information.

_________________
Thanks nas-central the lot of help! :)


Top
 Profile  
 
PostPosted: Tue Feb 02, 2016 7:20 pm 
Offline

Joined: Mon Jun 16, 2008 10:45 am
Posts: 6002
Some investigation shows the daemon is started with
Code:
znc -d /opt/share/snc
When I do so manually, I get
Code:
[ .. ] Checking for list of available modules...
[ !! ] failed
[ ** ] No modules found. Perhaps you didn't install ZNC properly?
[ ** ] Read http://wiki.znc.in/Installation for instructions.
[ ?? ] Do you really want to run ZNC without any modules? (yes/no) [no]:
What is your output?


Top
 Profile  
 
PostPosted: Wed Feb 03, 2016 7:48 pm 
Offline

Joined: Thu Mar 20, 2014 6:28 pm
Posts: 13
login as: root
root@192.168.1.2's password:
== Welcome at FFP version 0.7/arm, running on NSA310_ZyXEL nsa310, firmware V4.70(AFK.1) ==
root@nsa310:~# /opt/bin/opkg install znc
Installing znc (1.6.1-1) to root...
Downloading http://pkg.entware.net/binaries/armv5/z ... v5soft.ipk.
Configuring znc.
root@nsa310:~# /opt/bin/znc -d /opt/share/znc/ --makeconf
[ .. ] Checking for list of available modules...
[ !! ] failed
[ ** ] No modules found. Perhaps you didn't install ZNC properly?
[ ** ] Read http://wiki.znc.in/Installation for instructions.
[ ?? ] Do you really want to run ZNC without any modules? (yes/no) [no]: yes
[ >> ] ok
[ ** ]
[ ** ] -- Global settings --
[ ** ]
[ ?? ] Listen on port (1025 to 65534): 5555
[ ?? ] Listen using SSL (yes/no) [no]: no
[ ?? ] Listen using both IPv4 and IPv6 (yes/no) [yes]: yes
[ .. ] Verifying the listener...
[ >> ] ok
[ ** ] Unable to locate pem file: [/opt/share/znc/znc.pem], creating it
[ .. ] Writing Pem file [/opt/share/znc/znc.pem]...
[ >> ] ok
[ ** ] Enabled global modules []
[ ** ]
[ ** ] -- Admin user settings --
[ ** ]
[ ?? ] Username (alphanumeric): Doky
[ ?? ] Enter password:
[ ?? ] Confirm password:
[ ?? ] Nick [Doky]: Doky
[ ?? ] Alternate nick [Doky_]: Doky_
[ ?? ] Ident [Doky]: doky
[ ?? ] Real name [Got ZNC?]: Doky
[ ?? ] Bind host (optional):
[ ** ] Enabled user modules []
[ ** ]
[ ?? ] Set up a network? (yes/no) [yes]: yes
[ ** ]
[ ** ] -- Network settings --
[ ** ]
[ ?? ] Name [freenode]: atw
[ ?? ] Server host (host only): atw.irc.hu
[ ?? ] Server uses SSL? (yes/no) [no]: no
[ ?? ] Server port (1 to 65535) [6667]: 6667
[ ?? ] Server password (probably empty):
[ ?? ] Initial channels: #doky
[ ** ] Enabled network modules []
[ ** ]
[ .. ] Writing config [/opt/share/znc//configs/znc.conf]...
[ >> ] ok
[ ** ]
[ ** ] To connect to this ZNC you need to connect to it as your IRC server
[ ** ] using the port that you supplied. You have to supply your login info
[ ** ] as the IRC server password like this: user/network:pass.
[ ** ]
[ ** ] Try something like this in your IRC client...
[ ** ] /server <znc_server_ip> 5555 Doky:<pass>
[ ** ]
[ ** ] To manage settings, users and networks, point your web browser to
[ ** ] http://<znc_server_ip>:5555/
[ ** ]
[ ?? ] Launch ZNC now? (yes/no) [yes]: no
root@nsa310:~# mc
# /opt/etc/init.d/S99znc
Usage: /opt/etc/init.d/S99znc (start|stop|restart|check|kill|reconfigure)

root@nsa310:~# /opt/etc/init.d/S99znc start
Starting znc... failed.
root@nsa310:~#


Top
 Profile  
 
PostPosted: Tue Feb 23, 2016 12:45 pm 
Offline

Joined: Sun Feb 17, 2013 10:00 pm
Posts: 302
Im being stupid i think, but i cannot get opkg going, Installed v20160131zypkg005 on my NSA325 fw4.80 via packages in web admin , enabled in the package list but trying to run opkg i get
Code:
root@NSA325:/opt/bin# opkg
-sh: opkg: command not found


dunno where im going wrong


Top
 Profile  
 
PostPosted: Tue Feb 23, 2016 2:23 pm 
Offline

Joined: Mon Jun 16, 2008 10:45 am
Posts: 6002
./opkg?

The PATH should be adapted, but only if you login /after/ the package is started.


Top
 Profile  
 
PostPosted: Wed Feb 24, 2016 10:16 am 
Offline

Joined: Sun Feb 17, 2013 10:00 pm
Posts: 302
Thanks Mijzelf, I said i was being stupid!

./opkg worked as expected, but i had to add /opt/bin to PATH manually, but has solved the issue. Saying that i get this error from $PATH now
Code:
root@NSA325:/opt/bin# $PATH
-sh: /ffp/sbin:/usr/sbin:/sbin:/ffp/bin:/usr/bin:/bin:/opt/bin: No such file or directory

Im running alongside ffp for info

Also is there a par2 or par2cmdline package available?


Top
 Profile  
 
PostPosted: Wed Feb 24, 2016 8:00 pm 
Offline

Joined: Mon Jun 16, 2008 10:45 am
Posts: 6002
burbulence wrote:
Saying that i get this error from $PATH now
Code:
root@NSA325:/opt/bin# $PATH
-sh: /ffp/sbin:/usr/sbin:/sbin:/ffp/bin:/usr/bin:/bin:/opt/bin: No such file or directory
What did you expect? You are running $PATH as a command.
It's more convenient to echo it
Code:
echo $PATH

Quote:
Im running alongside ffp for info
Ah. That's why the PATH isn't adapted. I wrote about that on the webinterface of the zy-pkgs version.
Quote:
Also is there a par2 or par2cmdline package available?
I don't think so.


Top
 Profile  
 
PostPosted: Thu Feb 25, 2016 9:31 am 
Offline

Joined: Sun Feb 17, 2013 10:00 pm
Posts: 302
having read the info on the webinterface again i understand better. My plan is to move over to entware-ng over the next week but wanted to test everything on my Nas before making the leap, that being the reason for running alongside FFP.


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 69 posts ]  Go to page 1, 2, 3, 4, 5  Next

All times are UTC


Who is online

Users browsing this forum: barmalej2, Google [Bot] and 44 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Group