Closed evtk closed 9 years ago
Well, if someone can make it work without a package to test that'd be great.
There is a debian package available:
https://github.com/NzbDrone/NzbDrone/wiki/Installation#linux
But I don't have a clue how to install it on synology.
Maybe ...
1 - download deb. 2 - Unzip it 3 - Copy content of folder "data\opt\NzbDrone" on your nas. 4 - run mono package on nas .. 5 - Make a script "mono [Your Path]/NzbDrone.exe"
i am at work so ... will try tonight.
just tried on my syno box... whoops:
DiskStation> mono /volume2/Downloads/NzbDrone/NzbDrone.exe [Info] Bootstrap: Starting NzbDrone Console. Version 2.0.0.691 [Info] MigrationLogger: * Migrating data source=/root/.config/NzbDrone/nzbdrone.db;cache size=-10485760;datetimekind=Utc;journal mode=Wal * [Info] MigrationLogger: * VersionMigration migrating * [Fatal] ConsoleApp: EPIC FAIL!
System.EntryPointNotFoundException: sqlite3_column_database_name
at (wrapper managed-to-native) System.Data.SQLite.UnsafeNativeMethods:sqlite3_column_database_name (intptr,int)
at System.Data.SQLite.SQLite3.ColumnDatabaseName (System.Data.SQLite.SQLiteStatement stmt, Int32 index) [0x00000] in 2& parentToColumns, System.Collections.Generic.Dictionary
2& columnToParent) [0x00000] in
make a report on their issue tracker maybe they could patch the soft.
I have done so:
http://forums.nzbdrone.com/discussion/588/nzbdrone-as-synology-package
Let's see what happens!
Open a ticket to Synology and have them to update sqlite. Seems there's no other way unless recompile mono with our sqlite. I'd like to avoid recompile every package Synology can't compile properly...
Allright, thanks. I will contact synology and post any results here.
this is the answer on updating sqlite.
Unfortunately there is no announced plan to support this feature at the moment. I apologize for your inconvenience. However, I have passed this message to our developers and product management group. They will have more research on such feature. Thank you for bringing this issue to our attention.
That's the reason we build our own packages, if something needs an update we update it. So it seems the solution is to build mono from scratch using spksrc. If someone's up to it let me know.
I want to kick a bit of life in this issue. It seems that sql lite 3 has been updated by Synology on the DSM software, so i'm curious to see ift it would be able to get working now?
NAS> sqlite3 SQLite version 3.8.1 2013-10-17 12:57:35
Currently with latest sqlite installed still the same error :(
@Diaoul does having SQLite version 3.8.1 2013-10-17 make this package a real possibility now? I would be happy to test a package out. Thanks for your help!
is there any word if this will now be possible with this new version of SQlite?
Ive just tried while running DSM 5 and ive gotten something similar
Tried with available libs below and added the OSX one for a laugh, still no joy. libsqlite3.0.dylib libsqlite3.so libsqlite3.so.0 libsqlite3.so.0.8.6
/volume1/@appstore/NzbDrone> mono --debug NzbDrone.exe
[Info] Bootstrap: Starting NzbDrone Console. Version 2.0.0.1181
[Info] ps: Starting ps -p 21113 -o args=
[Error] ps: /bin/ps: invalid option -- 'p'
[Error] ps: BusyBox v1.16.1 (2014-01-20 02:24:47 CST) multi-call binary.
[Error] ps: Usage: ps
[Error] ps: Report process status
[Error] ps: Options:
[Error] ps: w Wide output
[Info] MigrationLogger: * Migrating data source=/root/.config/NzbDrone/nzbdrone.db;cache size=-10485760;datetimekind=Utc;journal mode=Wal *
[Info] MigrationLogger: * VersionMigration migrating *
[Fatal] ConsoleApp: EPIC FAIL!
System.EntryPointNotFoundException: sqlite3_column_database_name
at (wrapper managed-to-native) System.Data.SQLite.UnsafeNativeMethods:sqlite3_column_database_name (intptr,int)
at System.Data.SQLite.SQLite3.ColumnDatabaseName (System.Data.SQLite.SQLiteStatement stmt, Int32 index) [0x00000] in 2& parentToColumns, System.Collections.Generic.Dictionary
2& columnToParent) [0x00000] in
Press any key to exit...
@kevinmce, you got me motivated, so I installed Synology DMS 5.0 in a virtual machine (vmware) and gave it a go also. I am now stuck at the exact same error as you (above:)
System.EntryPointNotFoundException: sqlite3_column_database_name
I am willing to try whatever on this test (virtual machine) so if anyone has any ideas. Throw them at me!
My sqlite version on DSM 5.0beta: DStest> sqlite3 SQLite version 3.8.0.2 2013-09-03 17:11:13
Mono info: DStest> mono -V Mono JIT compiler version 2.11.1 ((no/426188e Mon Jan 13 12:11:24 CST 2014)
Mediainfo: DStest> mediainfo --version MediaInfo Command line, MediaInfoLib - v0.7.61
If you don't want to test on your live Synology box like me, I posted a method for setting up a virtual DSM 5.0 here:
http://forums.nzbdrone.com/discussion/comment/3758#Comment_3758
Humm, ive been looking up the virtual machine also yesterday. It makes me wonder was buying the synology really worth the 550 euro. I could have built a home server for a lot less.
I think requesting support from the synocommunity guys would help. They should be familiar with the issues when creating these packages.
So here is what I have been able to figure out.
It seems that sqlite defaults to not include/enable the column metadata function when compiled. This means that, the sqlite on the synology doesn't include that function. Hence the error we are getting:
System.EntryPointNotFoundException: sqlite3_column_database_name
So..... this means that we either need to get synology to update sqlite on DSM5.0 to include the column_metadata function when compiled or we compile sqlite ourselves with the function. As near as I can figure, adding this flag will compile with the needed feature:
CPPFLAGS="-D SQLITE_ENABLE_COLUMN_METADATA"
I have been trying to compile a version myself but I don't know what I am doing (never really done this before.) You can cross-compile for synology on linux. Here is what I have been trying to follow to do it:
Anyways, I am out of my depth here.....
See this comment here: https://bugzilla.xamarin.com/show_bug.cgi?id=327#c4 (where I found the info about sqlite not compiling with that feature.)
Edit: from sqlite: http://www.sqlite.org/c3ref/column_database_name.html
"These APIs are only available if the library was compiled with the SQLITE_ENABLE_COLUMN_METADATA C-preprocessor symbol."
const char _sqlite3_column_database_name(sqlite3stmt,int); const void _sqlite3_column_database_name16(sqlite3stmt,int); const char _sqlite3_column_table_name(sqlite3stmt,int); const void _sqlite3_column_table_name16(sqlite3stmt,int); const char _sqlite3_column_origin_name(sqlite3stmt,int); const void _sqlite3_column_origin_name16(sqlite3stmt,int);
Nice find Max!
One step closer!(fingers crossed) I unfortunately know probably less about compiling than you.
Ill look into it also, but just reading the first bit and im lost.
Edit: Requested some help over at the synology fourms: http://forum.synology.com/enu/viewtopic.php?f=27&t=75217&p=284643&hilit=nzbdrone#p284643
Would another option be to use an updated version of mono? Since the version of mono we are using(2.11) pre-dates the fix that is mentioned here: https://bugzilla.xamarin.com/show_bug.cgi?id=327
Just found this guide to compile it for synology... maybe its an easier path than compiling SQlite http://blog.hexad.dk/2013/11/mono-323-on-synology-ds210.html
SQlit is the easy part. Recompiling mono is a tough task but is the solution so we don't depend on some Synology package.
Indeed, compiling mono is going to be difficult. I didnt get past the configure command(./configure --prefix=/opt/mono-3.2.3)
Fails when testing the compiler: checking whether the C compiler works... no configure: error: in `/volume1/@appstore/mono-3.2.3': configure: error: C compiler cannot create executables
I'd love to get this running but we definitly need someone with some more (compiling) knowledge. I've tried to compile the new mono but also failed :( Someone posted a guide howto compile mono on a Synology DS210 @ http://blog.hexad.dk/2013/11/mono-323-on-synology-ds210.html
Ive goten further in compiling mono.... but now the next problem.
Anyone able to help diagnose the AWK command problem?
config.status: executing default commands awk: cmd. line:3: Unexpected token
mcs source: mcs
Engine: GC: sgen and bundled Boehm GC with typed GC and parallel mark TLS: pthread SIGALTSTACK: no Engine: Building and using the JIT oprofile: no BigArrays: no DTrace: no LLVM Back End: no (dynamically loaded: no)
Libraries: .NET 2.0/3.5: yes .NET 4.0: yes .NET 4.5: yes MonoDroid: no MonoTouch: no JNI support: IKVM Native libgdiplus: assumed to be installed zlib:
Don't compile on the NAS itself, that's unusable for packaging. Use spksrc instead.
I have not tried a VM / Debian OS. i thought that the NAS unix should be able to do that?
Its already been WAY more time/effort that i expected. Since ive started as a person with no unix knowledge, only some DOS/command prompt memories from way back when.
I may try gettingspkscr going. Will see.
Edit: I posted an error that I was working to resolve but then found that it may be a result of my using a 64 bit Debian install (instead of the recommended 32 bit.) I will report back with the error if it happens on 32 bit also. Thanks
Hey Max,
Been working on it here too... prolly wont start attempting to compile tonight. Gotta head out soon. But at least i have Debian OS installed on my PC now :D
kevinmce,
Haha, hopefully one of us will have success!
@Diaoul
I think I have done everything properly with spksrc. I did all of the items listed here: https://github.com/SynoCommunity/spksrc/blob/develop/README.rst My "make arch-bromolow" seemed to complete successfully.
However, there is no package created in the appropriate directory ( /spksrc/packages/ )
Am I missing something? How do I create the package? Should it have created the package when I ran make arch-bromolow?
edit: I think I figured it out.. I needed to run a make from the spk directory after everything. I'll update if that doesn't work (which makes a load of sense now that I think about it. haha)
Thanks
Do you have enable support for sqlite in mono? You need to depend on cross/sqlite for that.
I get this message when running nzbdrone with the freshly compiled mono 3.2.8:
"The assembly mscorlib.dll was not found or could not be loaded. It should have been installed in the '/usr/local/mono/lib/mono/4.5/mscorlib.dll' directory."
Doesn't mono use .so files (not .dll) on linux?
edit: I am guessing I need to add a configure arg to the compile....
@Diaoul
I'll add the depend for sqlite. Anything else you can think of off the top of your head? Is there a way to look at the dependencies etc. on synology's current beta mono .spk?
It seemed so close, so promising, but I can't get mono to compile with the corlib files that are missing (and causing the error above.) Synology's beta mono version has them. I tried dropping them in place but then I get some wacky errors due to the mismatch in versions. I think I am stuck... unfortunately
Interestingly enough, I tried renaming the sqlite3 binary so that it wouldn't execute and ran nzbdrone (without sqlite on the box!) I was curious, and guess what? You get the same error message without sqlite being available.
I tried this because I compiled sqlite with the SQLITE_ENABLE_COLUMN_METADATA feature (at least I think I did.) and that still didn't resolve the error. After that, I decided to eliminate sqlite in entirety and you get the same error message... This makes me wonder if NzbDrone can't reach sqlite for some reason.
Hummm thats not very promising.
Ive gotten a build of debian on the home PC, ill try to compile mono this evening(too much work time spent at this :yum: ) and take care to include the corlib. Maybe also try the SQlite side of things.
on debian the apt package for mono-complete includes these depends:
Depends: libmono-2.0-1 (= 2.10.8.1-8)
Depends: libmono-cil-dev (= 2.10.8.1-8)
Depends: libmono-profiler (= 2.10.8.1-8)
Depends: mono-2.0-gac (= 2.10.8.1-8)
Depends: mono-2.0-service (= 2.10.8.1-8)
Depends: mono-4.0-gac (= 2.10.8.1-8)
Depends: mono-4.0-service (= 2.10.8.1-8)
Depends: mono-csharp-shell (= 2.10.8.1-8)
Depends: mono-devel (= 2.10.8.1-8)
Depends: mono-dmcs (= 2.10.8.1-8)
Depends: mono-gmcs (= 2.10.8.1-8)
Depends: mono-jay (= 2.10.8.1-8)
Depends: mono-mcs (= 2.10.8.1-8)
Depends: mono-runtime (= 2.10.8.1-8)
Depends: mono-runtime-sgen (= 2.10.8.1-8)
Depends: mono-utils (= 2.10.8.1-8)
Depends: monodoc-base (= 2.10.8.1-8)
Depends: monodoc-manual (= 2.10.8.1-8)
I rage quit trying this when suddenly no matter where i tried to download mono the OS told me that there was no space left.... I just dont understand this OS.
Also retried it on my work PC this morning and now the VM here refuses to connect to the internet connection. It can resolve URL's but then connecting to the server fails.... :(
I give up, im its just not possible without knowing some more basics of the UNIX environment.
I got it compiling and making the dlls . (You need to use the native compile also like python) but I never got around to building a package. Copying to my nas I was able to run hello world.
I have it running! :D
I'll post more details soon
Mono 3 or NZBDrone?
NzbDrone
Did you actually get a mono package built or did you copy everything to the NAS?
Nice work Max, Cant wait to see your solution/package.
Question now is, does everything work as intended, like unrar, post processing, and so on.
But can't wait for your solution.
And the SPK! ;P
Hi all, so here is my pull request: https://github.com/SynoCommunity/spksrc/pull/868
Wasn't sure if it should be on master (instead of develop branch.)
Anyways, sorry for the tease. I spent all night trying to get the SPK working flawlessly. It works wonderfully on DSM 5.0 (for me at least.) It almost works on DSM 4, but I am running into one issue, so I limited it to DSM 5 compatibility for now.
So, what I did to get it to work is quite simple. I compiled a sqlite library with the -DSQLITE_ENABLE_COLUMN_METADATA option and the SPK installer downloads and places that library in the NzbDrone folder along with the exe.
Let me know if you run into any issues. I compiled for arch-bromolow here: removed
Update: Go here now: https://github.com/SynoCommunity/spksrc/issues/671#issuecomment-38209595
I have only tested for bromolow. Let me know if you would like me to compile a different architecture for you (if you don't want to do it yourself.) I believe only busybox gets compiled for arch anyways.
edit: oh, I used Mono 2.11.1 from Synology's beta branch of their repo ("Yes, I want to see beta versions" in package center.) You will also need to add and run MediaInfo from Missilehuggers repository: http://packages.missilehugger.com/ Both are required by the SPK
Update: Go here now and uninstall that 2.11.1 version and install mono 3.2.8! https://github.com/SynoCommunity/spksrc/issues/671#issuecomment-38209595
We should definitely get a newer version of Mono compiled and added as an SPK. While 2.11.1 seems to work fine, Markus101 of NzbDrone told me that Mono 3x is more stable. I got 3x working previously but ran into errors on compile on my last attempt.
Awesome work! And I really appreciate the work you have done, and stepping up to figure all things out. Would it be possible for you to complile a no-arch or a cedarview version from the SPK? I am running DSM 5.0 so that should be no problem.
Hi there,
I don't know if it is even possible to request here, but I would really like to install NZBDrone as package on my synology NAS. Can this be added to the repository?
I read NZBDrone is build on mono, and I have seen an official synology mono package. But I'm no expert and would not know how to use this package to run NZBDrone.
Many thanks!