Page 1 of 1

V4 Synology NAS

Posted: Mon 18 Mar 2024 9:02 am
by water01
For anyone who wants to run CumulusMX on a Synology NAS, a version of .NET V8.0.1 has been released and I have V4 running natively on the my Synology NAS DS720+.

This is using DSM 7.2, I am not sure if .NET V8 has been released on DSM 6.xx.xx.

No need for dockers or anything else just .NET V8 and MX, runs and stops using the Task Scheduler.

Re: V4 Synology NAS

Posted: Sat 25 May 2024 5:44 pm
by pdw112
can you explain my step by step how you install and run cumulusMX4 on synology.

I also want to try Cumulus MX4 run on my NAS

Re: V4 Synology NAS

Posted: Sat 25 May 2024 10:17 pm
by water01
I will put something together tomorrow and post it here, only just saw this.

Re: V4 Synology NAS

Posted: Sun 26 May 2024 1:06 pm
by water01
Ok here goes!! This is what I did.
First and this is a major point I am using DSM 7.2.1. I am not sure if the.NET 8 install is available on DSM 6.
First I created a shared directory on my raid volume called cumulusmx
I then downloaded CMX4 to my Windows Pc, unzipped it and copied the entire contents to my the cumulusmx directory on the NAS.
I then copied my V3 Cumulus.ini and strings.ini to the NAS cumulusmx Directory.
I then copied my V3 /data and /Reports folders to the NAS cumulusmx Directory.
I then renamed the /data folder in the CumulusMX directory to /datav3.
I then installed the .NET 8 runtime from the Community package source (if you do not have this source in your Package Center settings add it as http://packages.synocommunity.com/).
I then SSH'd into the NAS under my user and tested the .NET 8 install by using "dotnet –-info" at the command line.
This should give you something like this :
David@SynologyNAS:~$ dotnet --info

Host:
Version: 8.0.4
Architecture: x64
Commit: 2d7eea2529
RID: linux-x64

.NET SDKs installed:
No SDKs were found.

.NET runtimes installed:
Microsoft.AspNetCore.App 8.0.4 [/volume1/@appstore/dotnet8-runtime/share/dotnet/shared/Microsoft.AspNetCore.App]
Microsoft.NETCore.App 8.0.4 [/volume1/@appstore/dotnet8-runtime/share/dotnet/shared/Microsoft.NETCore.App]

Other architectures found:
None

Environment variables:
Not set

global.json file:
Not found

Learn more:
https://aka.ms/dotnet/info

Download .NET:
https://aka.ms/dotnet/download


Using the SSH command line I then navigated to cumulusmx directory in the volume1 directory i.e. David@SynologyNAS:/volume1/cumulusmx$ (this assumes you know how to use basic linux commands such as CD to get to a directory).
I then ran the data conversion by using the command line "dotnet MigrateData3to4.dll".
The data conversion should then run hopefully with no errors. Also note I did not have any Custom Daily log files, so no parameters were needed.
I then set up two tasks in Control Panel Task Scheduler, one to start CumulusMX and the other to stop it, so that it would automatically start and stop CumulusMX i.e. on a restart or DSM upgrade. So to do this click on Create and choose Triggered Task > User-defined script.

The “CulmulusMX Start” task is setup to run under root on Boot-up with Task settings to Run Command

dotnet /volume1/cumulusmx/CumulusMX.dll

The “CulmulusMX Stop” task is setup to run under root on Shutdown with Task settings to Run Command

pkill -f "dotnet"

OK that should be all, so to start Version 4 for the first time go back to main page of the Task Scheduler, highlight “CumulusMX Start” and then click on Run in the top headings of Task Scheduler.

Updating to a new version I run the “CumulusMX Stop” task, delete the interface and runtimes directories, and then copy the new versions from the release. I then copy all the main CumulusMX files from “Acknowledgements,txt” to “Updates.txt” over the existing files and then start CumulusMx as above.

Any problems let me know.

Re: V4 Synology NAS

Posted: Fri 31 May 2024 3:42 am
by Ricco
water01 wrote: Sun 26 May 2024 1:06 pm Ok here goes!! This is what I did.
First and this is a major point I am using DSM 7.2.1. I am not sure if the.NET 8 install is available on DSM 6.
First I created a shared directory on my raid volume called cumulusmx
I then downloaded CMX4 to my Windows Pc, unzipped it and copied the entire contents to my the cumulusmx directory on the NAS.
I then copied my V3 Cumulus.ini and strings.ini to the NAS cumulusmx Directory.
I then copied my V3 /data and /Reports folders to the NAS cumulusmx Directory.
I then renamed the /data folder in the CumulusMX directory to /datav3.
I then installed the .NET 8 runtime from the Community package source (if you do not have this source in your Package Center settings add it as http://packages.synocommunity.com/).
I then SSH'd into the NAS under my user and tested the .NET 8 install by using "dotnet –-info" at the command line.
This should give you something like this :
David@SynologyNAS:~$ dotnet --info

Host:
Version: 8.0.4
Architecture: x64
Commit: 2d7eea2529
RID: linux-x64

.NET SDKs installed:
No SDKs were found.

.NET runtimes installed:
Microsoft.AspNetCore.App 8.0.4 [/volume1/@appstore/dotnet8-runtime/share/dotnet/shared/Microsoft.AspNetCore.App]
Microsoft.NETCore.App 8.0.4 [/volume1/@appstore/dotnet8-runtime/share/dotnet/shared/Microsoft.NETCore.App]

Other architectures found:
None

Environment variables:
Not set

global.json file:
Not found

Learn more:
https://aka.ms/dotnet/info

Download .NET:
https://aka.ms/dotnet/download


Using the SSH command line I then navigated to cumulusmx directory in the volume1 directory i.e. David@SynologyNAS:/volume1/cumulusmx$ (this assumes you know how to use basic linux commands such as CD to get to a directory).
I then ran the data conversion by using the command line "dotnet MigrateData3to4.dll".
The data conversion should then run hopefully with no errors. Also note I did not have any Custom Daily log files, so no parameters were needed.
I then set up two tasks in Control Panel Task Scheduler, one to start CumulusMX and the other to stop it, so that it would automatically start and stop CumulusMX i.e. on a restart or DSM upgrade. So to do this click on Create and choose Triggered Task > User-defined script.

The “CulmulusMX Start” task is setup to run under root on Boot-up with Task settings to Run Command

dotnet /volume1/cumulusmx/CumulusMX.dll

The “CulmulusMX Stop” task is setup to run under root on Shutdown with Task settings to Run Command

pkill -f "dotnet"

OK that should be all, so to start Version 4 for the first time go back to main page of the Task Scheduler, highlight “CumulusMX Start” and then click on Run in the top headings of Task Scheduler.

Updating to a new version I run the “CumulusMX Stop” task, delete the interface and runtimes directories, and then copy the new versions from the release. I then copy all the main CumulusMX files from “Acknowledgements,txt” to “Updates.txt” over the existing files and then start CumulusMx as above.

Any problems let me know.
I created an account on this site just to come here and say thank you so much for this! I just got it up and running on my Syno in a few mins and even migrated my V4 data over from a Raspberry Pi.. That now free's up my Raspberry Pi to run HomeAssistant!

Re: V4 Synology NAS

Posted: Fri 31 May 2024 7:17 am
by water01
No problem glad it worked.

Re: V4 Synology NAS

Posted: Fri 31 May 2024 10:27 am
by nm3cxrdc
@water01 - another vote of thanks. Just like @ricco, I created an account specifically so I could thank you.

I was able to get CumulusMX up and running on my Synology NAS (ds220j) following your excellent instructions with no issues at all. I'm new to this (WH2900 weather station set up today and Cumulus downloaded and set up from scratch today) so I got a bit to learn about all the things I can do with Cumuls.

Re: V4 Synology NAS

Posted: Fri 31 May 2024 11:54 am
by water01
Welcome to the Synology NAS club!! Any problems or questions let me know, I have been running Cumulus and CumulusMX since 2011.

Re: V4 Synology NAS

Posted: Fri 31 May 2024 3:06 pm
by pdw112
thanks for your install manual.

I have a problem to run Cumulus on my Synolgy nas.
For now i can't find the problem.
My MXdiag file and dotnet below:

Code: Select all

2024-05-31 16:51:34.212  ========================== Cumulus MX starting ==========================
2024-05-31 16:51:34.258 Command line: /volume1/CumulusMX/CumulusMX.dll -port 8998 -lang nl 
2024-05-31 16:51:34.258 Cumulus MX v.4.0.1 build 4023
2024-05-31 16:51:34.281 Platform       : Linux
2024-05-31 16:51:34.282 OS Description : Linux 3.2.101 #42962 SMP Fri Mar 24 00:28:03 CST 2023
2024-05-31 16:51:34.282 Current culture: Nederlands [nl]
2024-05-31 16:51:34.283 Running as a 32 bit process
2024-05-31 16:51:34.284 Running under userid: root
2024-05-31 16:51:34.293 Checking required folders
2024-05-31 16:51:35.334 Reading Cumulus.ini file
2024-05-31 16:51:35.700 AvgSpdMins=10 AvgSpdTime=00:10:00
2024-05-31 16:51:35.830 Cumulus start date Parsed: 2022-01-22
2024-05-31 16:51:36.819 Reading Cumulus.ini file completed
2024-05-31 16:51:36.921 Creating lock file /tmp/cumulusmx-8998.lock
2024-05-31 16:51:37.001 Stop second instance: No other running instances of Cumulus found
2024-05-31 16:51:37.002 Directory separator=[/] Decimal separator=[,] List separator=[;]
2024-05-31 16:51:37.002 Date separator=[-] Time separator=[:]
2024-05-31 16:51:37.002 Standard time zone name:   Central European Standard Time
2024-05-31 16:51:37.002 Daylight saving time name: Central European Summer Time
2024-05-31 16:51:37.003 Daylight saving time? True
2024-05-31 16:51:37.003 Locale date/time format: 31-05-2024 16:51:37
2024-05-31 16:51:37.284 Creating start-up backup...
2024-05-31 16:51:37.285 BackupData: Creating backup 20240531165137.zip
2024-05-31 16:51:39.802 Created backup file 20240531165137.zip
2024-05-31 16:51:39.803 No start-up delay - disabled
2024-05-31 16:51:39.804 No start-up PING
2024-05-31 16:51:39.804 Data path = data/
2024-05-31 16:51:39.928 !!! Unhandled Exception !!!
System.TypeInitializationException: The type initializer for 'SQLite.SQLiteConnection' threw an exception.
 ---> System.DllNotFoundException: Unable to load shared library 'e_sqlite3' or one of its dependencies. In order to help diagnose loading problems, consider using a tool like strace. If you're using glibc, consider setting the LD_DEBUG environment variable: 
/volume1/CumulusMX/runtimes/linux-arm/native/e_sqlite3.so: cannot open shared object file: No such file or directory
/volume1/@appstore/dotnet8-runtime/share/dotnet/shared/Microsoft.NETCore.App/8.0.4/e_sqlite3.so: cannot open shared object file: No such file or directory
/volume1/CumulusMX/e_sqlite3.so: cannot open shared object file: No such file or directory
/lib/libc.so.6: version `GLIBC_2.28' not found (required by /volume1/CumulusMX/runtimes/linux-arm/native/libe_sqlite3.so)
/volume1/@appstore/dotnet8-runtime/share/dotnet/shared/Microsoft.NETCore.App/8.0.4/libe_sqlite3.so: cannot open shared object file: No such file or directory
/volume1/CumulusMX/libe_sqlite3.so: cannot open shared object file: No such file or directory
/volume1/CumulusMX/runtimes/linux-arm/native/e_sqlite3: cannot open shared object file: No such file or directory
/volume1/@appstore/dotnet8-runtime/share/dotnet/shared/Microsoft.NETCore.App/8.0.4/e_sqlite3: cannot open shared object file: No such file or directory
/volume1/CumulusMX/e_sqlite3: cannot open shared object file: No such file or directory
/volume1/CumulusMX/runtimes/linux-arm/native/libe_sqlite3: cannot open shared object file: No such file or directory
/volume1/@appstore/dotnet8-runtime/share/dotnet/shared/Microsoft.NETCore.App/8.0.4/libe_sqlite3: cannot open shared object file: No such file or directory
/volume1/CumulusMX/libe_sqlite3: cannot open shared object file: No such file or directory

   at SQLitePCL.SQLite3Provider_e_sqlite3.NativeMethods.sqlite3_libversion_number()
   at SQLitePCL.SQLite3Provider_e_sqlite3.SQLitePCL.ISQLite3Provider.sqlite3_libversion_number()
   at SQLitePCL.raw.SetProvider(ISQLite3Provider imp)
   at SQLitePCL.Batteries_V2.Init()
   at SQLite.SQLiteConnection..cctor()
   --- End of inner exception stack trace ---
   at SQLite.SQLiteConnection..ctor(SQLiteConnectionString connectionString)
   at CumulusMX.Cumulus.Initialise(Int32 HTTPport, Boolean DebugEnabled, String startParms)
   at CumulusMX.Program.RunAsAConsole(Int32 port, Boolean debug)
   at CumulusMX.Program.Main(String[] args)
   at CumulusMX.Program.<Main>(String[] args)
2024-05-31 16:53:16.850 Ctrl + C pressed
2024-05-31 16:53:16.869 Cumulus closing
2024-05-31 16:53:16.871 Stopping timers
2024-05-31 16:53:16.901 Stopping extra sensors...
2024-05-31 16:53:16.901 Extra sensors stopped
2024-05-31 16:53:16.902 Releasing lock file...
2024-05-31 16:53:16.902 Station shutdown complete
2024-05-31 16:53:17.409 Cumulus has shutdown
2024-05-31 16:53:20.611 Cumulus terminating
2024-05-31 16:53:20.611 Cumulus closing
2024-05-31 16:53:20.611 Stopping timers
2024-05-31 16:53:20.612 Stopping extra sensors...
2024-05-31 16:53:20.612 Extra sensors stopped
2024-05-31 16:53:20.612 Releasing lock file...
2024-05-31 16:53:20.612 Station shutdown complete

Code: Select all

Host:
  Version:      8.0.4
  Architecture: arm
  Commit:       2d7eea2529
  RID:          linux-arm

.NET SDKs installed:
  No SDKs were found.

.NET runtimes installed:
  Microsoft.AspNetCore.App 8.0.4 [/volume1/@appstore/dotnet8-runtime/share/dotnet/shared/Microsoft.AspNetCore.App]
  Microsoft.NETCore.App 8.0.4 [/volume1/@appstore/dotnet8-runtime/share/dotnet/shared/Microsoft.NETCore.App]

Other architectures found:
  None

Environment variables:
  Not set

global.json file:
  Not found

Learn more:
  https://aka.ms/dotnet/info

Download .NET:
  https://aka.ms/dotnet/download

Re: V4 Synology NAS

Posted: Fri 31 May 2024 8:24 pm
by water01
The difference I see here is that my .NET 8 is running on X64, linux-X64 and yours is running linux-arm.

Also did the Migratedata3to4 run correctly as if not that would infer that there is a problem with .NET8 on arm processors.

If it did run correctly make sure you have copied the ENTIRE cumulusmx contents to the directory as SQLite is part of the components on the directory and runtimes.

If that all seems correct I would edit Cumulus.ini and set Logging=1 and DataLogging=1 (in the [Station] block) and restart it to see if that gives us more information in MXDiags file, which could you post here.

Re: V4 Synology NAS

Posted: Sat 01 Jun 2024 10:03 am
by pdw112
Migratedata: all data correct.

All files from the zip file copied to the new cumulusmx folder on my nas.
Logging and datalogging changed to 1.
See my mxdiag below:

Code: Select all

2024-06-01 11:41:58.900  ========================== Cumulus MX starting ==========================
2024-06-01 11:41:58.903 Command line: /volume1/CumulusMX/CumulusMX.dll 
2024-06-01 11:41:58.903 Cumulus MX v.4.0.1 build 4023
2024-06-01 11:41:58.907 Platform       : Linux
2024-06-01 11:41:58.908 OS Description : Linux 3.2.101 #42962 SMP Fri Mar 24 00:28:03 CST 2023
2024-06-01 11:41:58.908 Current culture: Invariant Language (Invariant Country) []
2024-06-01 11:41:58.908 Running as a 32 bit process
2024-06-01 11:41:58.919 Running under userid: root
2024-06-01 11:41:58.923 Checking required folders
2024-06-01 11:42:00.889 Reading Cumulus.ini file
2024-06-01 11:42:01.594 AvgSpdMins=10 AvgSpdTime=00:10:00
2024-06-01 11:42:01.845 Cumulus start date Parsed: 2022-01-22
2024-06-01 11:42:03.316 Reading Cumulus.ini file completed
2024-06-01 11:42:03.400 Creating lock file /tmp/cumulusmx-8998.lock
2024-06-01 11:42:03.533 Stop second instance: No other running instances of Cumulus found
2024-06-01 11:42:03.533 Directory separator=[/] Decimal separator=[.] List separator=[,]
2024-06-01 11:42:03.534 Date separator=[/] Time separator=[:]
2024-06-01 11:42:03.534 Standard time zone name:   Central European Standard Time
2024-06-01 11:42:03.534 Daylight saving time name: Central European Summer Time
2024-06-01 11:42:03.534 Daylight saving time? True
2024-06-01 11:42:03.544 Locale date/time format: 06/01/2024 11:42:03
2024-06-01 11:42:03.860 Creating start-up backup...
2024-06-01 11:42:03.871 BackupData: Creating backup 20240601114203.zip
2024-06-01 11:42:07.290 Archiving the database
2024-06-01 11:42:09.060 Completed archive of the database
2024-06-01 11:42:09.440 Created backup file 20240601114203.zip
2024-06-01 11:42:09.456 No start-up delay - disabled
2024-06-01 11:42:09.457 No start-up PING
2024-06-01 11:42:09.458 Data path = data/
2024-06-01 11:42:10.007 !!! Unhandled Exception !!!
System.TypeInitializationException: The type initializer for 'SQLite.SQLiteConnection' threw an exception.
 ---> System.DllNotFoundException: Unable to load shared library 'e_sqlite3' or one of its dependencies. In order to help diagnose loading problems, consider using a tool like strace. If you're using glibc, consider setting the LD_DEBUG environment variable: 
/volume1/CumulusMX/runtimes/linux-arm/native/e_sqlite3.so: cannot open shared object file: No such file or directory
/volume1/@appstore/dotnet8-runtime/share/dotnet/shared/Microsoft.NETCore.App/8.0.4/e_sqlite3.so: cannot open shared object file: No such file or directory
/volume1/CumulusMX/e_sqlite3.so: cannot open shared object file: No such file or directory
/lib/libc.so.6: version `GLIBC_2.28' not found (required by /volume1/CumulusMX/runtimes/linux-arm/native/libe_sqlite3.so)
/volume1/@appstore/dotnet8-runtime/share/dotnet/shared/Microsoft.NETCore.App/8.0.4/libe_sqlite3.so: cannot open shared object file: No such file or directory
/volume1/CumulusMX/libe_sqlite3.so: cannot open shared object file: No such file or directory
/volume1/CumulusMX/runtimes/linux-arm/native/e_sqlite3: cannot open shared object file: No such file or directory
/volume1/@appstore/dotnet8-runtime/share/dotnet/shared/Microsoft.NETCore.App/8.0.4/e_sqlite3: cannot open shared object file: No such file or directory
/volume1/CumulusMX/e_sqlite3: cannot open shared object file: No such file or directory
/volume1/CumulusMX/runtimes/linux-arm/native/libe_sqlite3: cannot open shared object file: No such file or directory
/volume1/@appstore/dotnet8-runtime/share/dotnet/shared/Microsoft.NETCore.App/8.0.4/libe_sqlite3: cannot open shared object file: No such file or directory
/volume1/CumulusMX/libe_sqlite3: cannot open shared object file: No such file or directory

   at SQLitePCL.SQLite3Provider_e_sqlite3.NativeMethods.sqlite3_libversion_number()
   at SQLitePCL.SQLite3Provider_e_sqlite3.SQLitePCL.ISQLite3Provider.sqlite3_libversion_number()
   at SQLitePCL.raw.SetProvider(ISQLite3Provider imp)
   at SQLitePCL.Batteries_V2.Init()
   at SQLite.SQLiteConnection..cctor()
   --- End of inner exception stack trace ---
   at SQLite.SQLiteConnection..ctor(SQLiteConnectionString connectionString)
   at CumulusMX.Cumulus.Initialise(Int32 HTTPport, Boolean DebugEnabled, String startParms)
   at CumulusMX.Program.RunAsAConsole(Int32 port, Boolean debug)
   at CumulusMX.Program.Main(String[] args)
   at CumulusMX.Program.<Main>(String[] args)
2024-06-01 11:42:11.500 Cumulus terminating
2024-06-01 11:42:11.507 Cumulus closing
2024-06-01 11:42:11.508 Stopping timers
2024-06-01 11:42:11.547 Stopping extra sensors...
2024-06-01 11:42:11.547 Extra sensors stopped
2024-06-01 11:42:11.548 Releasing lock file...
2024-06-01 11:42:11.548 Station shutdown complete

Re: V4 Synology NAS

Posted: Sun 02 Jun 2024 7:00 pm
by mcrossley
I think this is key bot from that error message:

Code: Select all

lib/libc.so.6: version `GLIBC_2.28' not found (required by /volume1/CumulusMX/runtimes/linux-arm/native/libe_sqlite3.so)
You probably have an older version of libc installed - 2.27 maybe? I don't know how or if the version on Synology can be updated. It probably needs a DSM update?