Unison qpackage

Tell us your most wanted features from QNAP products.
Post Reply
User avatar
fedoralinux
Easy as a breeze
Posts: 437
Joined: Thu Dec 22, 2011 9:33 pm
Location: The Netherlands
Contact:

Unison qpackage

Post by fedoralinux » Sat Jan 21, 2012 10:28 pm

At first, yes, i know there is a downloadable unison package for qnap, but i need an out of the box package for the latest version
http://www.cis.upenn.edu/~bcpierce/unison/
http://www.seas.upenn.edu/~bcpierce/uni ... es/stable/

i got the latest version on my linux pc, and now i need a latest version for qnap device
thanks
PC: dell laptop running Fedora 18
wd tv live as network mediaplayer

FREE cloudstorage on dropbox
dropbox

avaterera
Starting out
Posts: 11
Joined: Tue Nov 17, 2009 11:36 pm

Re: Unison qpackage

Post by avaterera » Sun Feb 26, 2012 11:04 pm

+1 for Unison qpkg. There is version only for ARM (as far as I know) and we need it for x86.

johnripper
Experience counts
Posts: 1345
Joined: Sun Aug 14, 2011 5:13 am

Re: Unison qpackage

Post by johnripper » Thu Mar 01, 2012 4:49 am


User avatar
trejder
Know my way around
Posts: 181
Joined: Fri Jan 07, 2011 5:13 am

Re: Unison qpackage

Post by trejder » Thu Mar 08, 2012 11:00 pm

Hi,

fedoralinux wrote:At first, yes, i know there is a downloadable unison package for qnap, but i need an out of the box package for the latest version

Many people around this forum keeps talking about Unison package designed specially for QNAP? But where can I get it? There is no such package in QPKG repository and on Unison project website you can only download latest overall version, with no specific releases for either QNAP or any other system / NAS.

So? There is or there isn't ready out-of-the-box solution for getting Unison to QNAP? Can I get it fast or do I need to follow whole procedure of recompilation and instalation, covered in official release documentation?

Cheers,
Trejder
QNAP TS-210 with:
- RAID 0 Stripping Disk Volume using 2x2TB HDD (Samsung HD204UI),
- plus 1,5TB Ext USB HDD (Samsung HD154UI),
- and 0,75TB Ext USB HDD (WD MyPassport).
Latest firmware installed.

ulikio
New here
Posts: 7
Joined: Mon Dec 07, 2009 3:05 am

Re: Unison qpackage

Post by ulikio » Wed May 18, 2016 1:46 am

I absolutely need it too!!! +1

ulikio
New here
Posts: 7
Joined: Mon Dec 07, 2009 3:05 am

Unison working under Entware-ng (DEPRECATED)

Post by ulikio » Thu May 19, 2016 5:14 am

* * * 2019.02.03: GIVEN NEW 64BIT QNAP Hardware TS-453B PLEASE SEE MY UPDATED INSTALL HOWTO BELOW. This procedure only works for my older 32bit Intel system * * *

Alright, I spent two nights on this and finally got a solution that works for me (QNAP TS-439 Pro / Intel CPU). Result: get a working unison binary to use even under stupid entware

The steps I followed
- Deinstall any Qnapware / Entware / whatever-ware
- Optware is depricated but you will still need it temporarily to compile unison using the native ocaml ikpg (get it somewhere on the web & install. filename: Optware_0.99.163_x86.qpkg through QNAP web interface. I found it under: http://forum.qnapclub.de/viewtopic.php?f=67&t=655)
- ipkg update
- ipkg upgrade
- ipkg install ocaml make gcc
- wget http://www.seas.upenn.edu/~bcpierce/uni ... 8.3.tar.gz
- mv unison-2.48.3.tar.gz /share/Public <<--- you need this, ocaml compliation will fail otherwise (if there's a space in the path for instance)
- tar xvfz unison-2.48.3.tar.gz
- cd unison-2.48.3
- make clean
- make NATIVE=false UISTYLE=text
- you will get an error message saying "etags - command not found" - binary is built anyway and usable
- copy unison (binary file) to somewhere safe and /opt/bin if you want to use it
----------------- we could stop here if we wanted to stick with Optware, but we don't ------------------
- now deinstall Optware (through Web interface)
- install Entware-ng
- copy unison binary to whereever you want to use it (you don't need ocaml anymore)
Last edited by ulikio on Sun Feb 03, 2019 10:41 pm, edited 1 time in total.

User avatar
trejder
Know my way around
Posts: 181
Joined: Fri Jan 07, 2011 5:13 am

Re: Unison qpackage

Post by trejder » Thu May 19, 2016 1:45 pm

Thank you for your comprehensive research and for writing this guide. Congratulations on your success!

However, you have replied to FOUR years old topic / question. Yes, I'm still using my old TS-210 and I still wonder, how it is possible, that it still works fine (after six years), but I certainly had to develop some alternative solution back in 2012. That solution was named "Dropbox" (now "OneDrive").

Again, thank you for sharing your thoughts. I hope, this guide will help someone, who is in desperate need to use Unison on QNAP-like devices.
QNAP TS-210 with:
- RAID 0 Stripping Disk Volume using 2x2TB HDD (Samsung HD204UI),
- plus 1,5TB Ext USB HDD (Samsung HD154UI),
- and 0,75TB Ext USB HDD (WD MyPassport).
Latest firmware installed.

halol
Getting the hang of things
Posts: 95
Joined: Thu Aug 09, 2012 9:43 pm

Re: Unison qpackage

Post by halol » Fri May 20, 2016 1:13 am

No harm in reviving old threads! It is still useful to some people (me, for example!)

I used to have an ARM based TS-219P II and have been using unison successfully for a long time. What I noticed when building unison back then was that if I was using the ocaml version provided with Optware, unison would be extremely slow (because of the NATIVE=false flag required with the OOTB ocaml).

The solution for me was to build ocaml as well. Here are the steps I followed at the time:

Compile ocaml:
- get the ocaml 3.12.0 sources from: http://ipkg.nslu2-linux.org/sources/
- tar xvfz ocaml-3.12.0.tar.gz
- configure -prefix /opt
- make world
- make opt
- make install
=> chech that ocamlc and ocamlopt are working

Then build unison:
- ipkg install emacs
- get Unison latest sources (pick up a version compatible with the one of your other machines) and extract them
- make UISTYLE=text

And I would get much much better performances like this (you can drop the NATIVE=false when compiling).

---

Now, I just upgraded to a TVS-663, 64bits and Intel based. The problems started... and I too just spent 2 days pulling my hair trying to get this working!

Here is what I did, as this is a slightly different solution:
- Install Entware using the 64 bits package

As in the past, first compile ocaml. There are a few differences though:
- first, Unison apparently doesn't compile with the version > 4. So get ocaml-3.12.1.
- ./configure -prefix /opt -no-shared-libs -no-curses (not sure which options are absolutely needed here, that's just what worked for me)
- create links to some Entware librairies (otherwise the build process uses 32bit default libraries from /lib and fails. Of course this may not be needed if you have a 32bit architecture):
ln -s /opt/lib/libm-2.23.so /lib64/libm.so.6
ln -s /opt/lib/libdl-2.23.so /lib64/libdl.so.2
ln -s /opt/lib/libncurses.so /lib64/libncurses.so.6
- ldconfig
- make world, make opt and make install

Then compile ctags/etags
- download the sources from http://ctags.sourceforge.net/
- ./configure --prefix=/opt --enable-etags
- make
- make install

Finally, build Unison:
- make UISTYLE=text
- ln -s /opt/lib/libutil-2.23.so /lib64/libutil.so.1 (required to run Unison)
- ldconfig
- test that the binary is working

=> done! well... almost

Any link created in /lib64 will be removed after a reboot, which will break Unison (and ocaml). Beside I don't think that it would be a very good idea to make those libs available system wide as they may disrupt other applications...
So here is what I did:
- mkdir /opt/usr/local/libunison
- create all the links in this directory:
ln -s /opt/lib/libm-2.23.so /opt/usr/local/libunison/libm.so.6
ln -s /opt/lib/libdl-2.23.so /opt/usr/local/libunison/libdl.so.2
ln -s /opt/lib/libncurses.so /opt/usr/local/libunison/libncurses.so.6
ln -s /opt/lib/libutil-2.23.so /opt/usr/local/libunison/libutil.so.1
- mv /opt/bin/unison /opt/bin/unison-bin
- vi /opt/bin/unison (to create a new script), with the following content:

Code: Select all

    #!/bin/sh
    LD_LIBRARY_PATH=/opt/usr/local/libunison
    unison-bin $@

- chmod +x unison

=> you can call Unison using the 'unison' command as usual

Hope this helps!
TVS-663

blackdog
Starting out
Posts: 29
Joined: Sat Aug 13, 2011 9:41 pm

Re: Unison qpackage

Post by blackdog » Tue Aug 30, 2016 1:31 pm

Here is the tutorial to install unison precompiled binary without optware

http://gayberti.de/2016/02/07/unison-au ... atisieren/

nickma
New here
Posts: 8
Joined: Wed Oct 17, 2018 5:26 pm

Re: Unison qpackage

Post by nickma » Fri Nov 02, 2018 3:32 am


"www.gayberti.de Server not found"

nickma
New here
Posts: 8
Joined: Wed Oct 17, 2018 5:26 pm

Re: Unison qpackage

Post by nickma » Sun Nov 04, 2018 4:49 am

I just built unison on my TS-228A using armv8 (aka aarch64) Entware-ng [1] and halol's how to.
halol wrote:The solution for me was to build ocaml as well. Here are the steps I followed at the time:
[...]
Hope this helps!

Thank you so much, it did help!

[1] http://bin.entware.net/aarch64-k3.10/installer/generic.sh

ulikio
New here
Posts: 7
Joined: Mon Dec 07, 2009 3:05 am

Re: Unison qpackage

Post by ulikio » Sun Feb 03, 2019 10:40 pm

hi guys

thanks halol for your indepth update howto. @Trejder, I agree there's no harm in reviving old threads if people keep using (good) software. I have several QNAP's, now a 64bit Intel based TS-453B with firmware 4.3.6.0805 (2018/12/28) installed. I tried my own procedure posted above and it didn't work anymore. tried Halol's, failed on the OCAML compilation. I'm not an expert user so kept searching and found this easy procedure to work for me
- export PATH=$PATH:/opt/bin:/opt/sbin
- deinstall Optware (through Web interface) if installed, it's deprecated
- find entware (2019.02.03: https://github.com/Entware/Entware/wiki ... n-QNAP-NAS) as of QNAP firmware: 4.3.6.0805)
- install Entware-ng through web-UI
- install essential entware packages via ssh/console (package list: https://pkg.entware.net/binaries/armv7/Packages.html)
opkg update & opkg upgrade
opkg install coreutils binutils shadow-su less
- cd /share/Public <<--- you need this, ocaml compliation will fail otherwise (if there's a space in the path for instance)
- wget http://caml.inria.fr/pub/distrib/ocaml- ... 2.0.tar.gz
- tar xvfz ocaml-4.02.0.tar.gz
- cd ocaml-4.02.0
- ./configure -prefix /opt
- make world.opt
- make install
- wget https://www.seas.upenn.edu/~bcpierce/un ... 8.3.tar.gz
- cd ../unison-2.48.3
- make clean
- make UISTYLE=text
- you will get an error message saying "etags - command not found" - binary is built anyway and usable
- chmod 755 unison unison-fsmonitor
- cp unison /opt/bin/ && cp unison-fsmonitor /opt/bin/ <-- copy unison (binary file) to somewhere within the path

gordwait
First post
Posts: 1
Joined: Fri Dec 07, 2018 2:52 am

Re: Unison qpackage

Post by gordwait » Tue Mar 12, 2019 2:25 am

I had to add:

opkg install gcc
opkg install make

to your instructions, otherwise, looks like I have a copy of Unison on my QNAP - thanks!
(Now to see if it works ;)

Post Reply

Return to “Features Wanted”