Migrating from Cumulus 1 to MX: Difference between revisions

From Cumulus Wiki
Jump to navigationJump to search
m
corrected cross reference that was linking to text that has moved to different page
m (corrected cross reference that was linking to text that has moved to different page)
 
When you successfully start MX, the engine is running, and it continues, until it is terminated by control C (or its equivalent in a Mac environment). (You can also run MX as a service, that has different ways to start and stop, discussed in the links given in previous section).
 
The separate [[MX Administrative Interface|admin interface]](unfortunately this is called various names in the support forum, including "user interface", "dashboard interface", and "admin interface") is provided by virtue of the engine acting as a web server. You can view the admin interface by typing the URL of the built-in web server into your browser, either on the same machine, or on a separate machine sharing the same local network.
 
If you install MX on Microsoft Windows, then a few extra one-off steps are needed to allow this web server functionality:
 
The default URL if the browser is on the same machine as MX is http://localhost:8998/. Newer releases of MX will tell you an IPv4 address to use, such as by typing "http://192.168.1.64:8998/".
 
Equally, if "localhost" is already in use for another web server (that you already run on your device), unless you can differentiate purely by port number you may need to use the correct IPv4 address as above, even on the same device.
 
For security reasons, the admin interface should not be accessible via the public internet.
If you want to continue using the same weather station, and you are not moving to a different home, you will want to maintain the data you collected using Cumulus 1 in your MX installation. This is what is meant by migration, and there is quite a bit to read, taking up most of the rest of this Wiki page. The Cumulus configuration files for Cumulus 1 and for MX share the same name, but their content is very different, so these are discussed at length in subsections below.
 
Obviously, you will want to copy ALL (''except weather diary which uses a different file'') the files in the [[#"data" folder]], from any old installation into the new installation, but migrating these is not always easy, here is a quick summary of the potential issues (all discussed further in various subsections later):
* '''When you first run MX, the [[#Start date|Start Date]] is recorded in the configuration file'''
** In the legacy software, this date is purely used as something to appear on one of the [[Customised_templates#The_Standard_Templates_for_Cumulus_1|sample web templates]]
** You can edit this [[Cumulus.ini#Data_Logging|'''StartDate=xxxxx''']] parameter, in the admin interface select ''Station Settings → Common Options → Advanced Options → Records Began date''
* Be aware your new installation has to use the same "locale" as the old installation, or MX will struggle as the locale affects how new lines are stored, and how MX expects old lines to have been stored the same way.
** The legacy software was fairly tolerant about date formats, and use of decimal commas
* If your old installation, is on a different operating system to the new installation, remember that Microsoft Windows uses different line terminators to all other operating systems, although MX should cope with mixed line terminators, any third party routines reading your data files will probably not accept a line terminator change. See [[MX on Linux]] page for more information on this.
* Cumulus MX is much more fussy than Cumulus 1 about every line in any data file using exactly the same locale formatting:
** Cumulus 1 is able to accept any character (other than the list separator, and space) being used to separate hour and minutes in time-stamps, MX expectsonly accepts a colon ":"
** [[Amending dayfile]] tells you about how MX is far more fussy about the content in [[dayfile.txt]]
** [[:Category:Ini Files|.ini files]] explains how time-stamps are formatted differently in the extreme tracking files, and how MX prefers decimal points to decimal commas
* If your old installation, is on a different operating system to the new installation, remember that Microsoft Windows uses different line terminators to all other operating systems, although MX should cope with mixed line terminators, any third party routines reading your data files will probably not accept a line terminator change. See [[MX on Linux]] page for more information on this.
 
==Simplest migration==
 
# Copy the configuration files ('''Cumulus.ini''' and the optional '''strings.ini''') from the directory with Cumulus.exe in it to the directory with CumulusMX.exe in it
# If you use the [[Weather Diary]], see that cross reference, because MX cannot read the old file, and there is no conversion utility.
# Copy all the [[:Category:Ini Files|extreme tracking files]] and the [[:Category:Files with Comma Separated Values|files with your your data]] in the old [[Data folder]] across to MX folder with same name
# IfCopy youall havethe [[:Category:Ini Files|extreme tracking files ending in .ini]] and the [[Reports:Category:Files folderwith Comma Separated Values|files with your data ending in .txt]], copyin themthe old [[Data folder]] across to the MX folder ofwith same name
# If you have files in the [[Reports folder]], copy them across to the MX folder of same name, see that cross reference for information about different defaults
 
==File names==
For all Unix-based operating systems (Linux, Raspberry Pi OS, and other variants), each line should end with just a Line Feed.
 
To change end of line characters, run each file through an editor designed for programmers. Various editors are available but "Notepad ++" is one that is popular on Windows, but can run on other operating systems. In its '''Edit''' menu, choose '''EOL conversion'''. On a Linux system like a Raspberry Pi computer, please see [[MX_on_LinuxPreparing_your_Linux_computer_for_MX#Changing_line_terminators|Changing line terminators]].
 
If you use PHP Hypertext Pre-processor (php) anywhere on your installation, normally that is written for "Line-feed" as line terminator and any "carriage return" in your files may mess up the content unless you code in a "trim" function to remove it. Hopefully, if you use PHP, you are technical enough to realise you may need to edit the code depending on which device it is being run on!
 
==Configuration file==
MX's [[Cumulus.ini]] has different content to the legacy [[Cumulus.ini_(Cumulus_1)|'''cumulus.ini''']]. From release 3.12.0,many more new settings were added, more settings were removed, and some parameters in the file were renamed. The first cross reference, in listing all the parameters, makes it clear which settings were introduced in the legacy software, and which MX release added new settings, this should help you to grasp how many new settings exist!
 
===Differences===
'''The [[MX_Administrative_Interface#Changing_Settings|settings pages]] in MX, work differently to the [[Cumulus_Screenshots#Configuration_Menu_Screens|settings screens]] in Cumulus 1. You need to click ''Save'' and (in many cases) stop and restart MX before changed settings take effect.'''
 
The original Cumulus MX beta by Steve Loft was partly written by machine code translation from his Cumulus 1 code, and therefore MX initially worked fairly similarly to the legacy software.
 
The development of MX since then, has replaced significant coding and it is safest to assume that MX works differently to the legacy software.
 
This does mean that some settings do have to be changed when moving from the legacy software to MX:
* Some settings actually have a different parameter name, e.g. '''Port=n''' is replaced by '''Comport=tttttttt''', these differences are explained later
* Some settings work in a different way e.g. the real-time interval in the legacy software is the number of seconds after real-time actions end to when they starts again, so two real-time cycles cannot overlap. For Cumulus MX, a real-time interval kicks off a cycle after the specified number of seconds and therefore you probably need to increase the time in the setting to ensure all actions in one cycle finish before the next attempt starts
 
Consequently, if you are migrating from the legacy software to MX now, it is best to rename your old '''cumulus.ini'' file so it is is not seen by MX. Let MX create a new configuration file with just the parameters it needs using the various [MX_Administrative_Interface#Changing_Settings|settings pages in the admin interface]]. That will ensure you don't get muddled by parameters used for Cumulus 1 (but not for MX); and you do have all the parameters you do need, set correctly.
 
 
===How to make new Settings take effect===
 
'''The [[MX_Administrative_Interface#Changing_Settings|settings pages]] in Cumulus 1 and MX, work differently to the [[Cumulus_Screenshots#Configuration_Menu_Screens|settings screens]] in Cumulus 1:
* for Cumulus 1 you choose to save changes by clicking OK,
* for MX changes are only saved when you click a '''Save''' button if one is provided.
* The alarms page works slightly differently, with an "Update alarms" button.
* If there is no Save button anywhere on the screen (as in Extra Web Files) then the setting is saved to configuration file when you move to next field/line, and acted on when you next restart MX.
 
Be aware that you do have to restart MX after changing certain settings:
Be aware that you should restart MX after changing many settings. This is because many settings are only written to configuration file, not yet to internal code, and such settings are only read from configuration file when MX starts. The developer is changing the code, so that in more cases edits on the settings pages do update the settings used by the code, as well as the file, but at time of writing there is no list of which settings work like that, and which require a restart.
* You certainly need to restart after any changes that relate to weather station input reading
* You may need to restart after changes that relate to processing of outputs
* At time of writing there is no list of which settings require a restart
* Early releases of MX tended to write new settings to configuration file, but not change how the internal code behaved
* Such settings only took effect on restart, when MX reads the configuration file
* As MX is rewritten for later releases, the handling of settings is changing, and more and more take effect immediately
 
===Start date===
 
A typical parameter value for other serial connecting devices might be "/dev/ttyUSB3" where the final digit will change depending on the new connection. You can search for posts on the support forum that talk about how to find out what connection is being used, depending on what hardware you are using.
 
===Fine Offset Read Avoid Setting===
 
The "read-avoid" timer setting for traditional Fine Offset Stations, was intended to reduce the lock-up problem.
 
This type of weather station consists of some remote sensors that transmit a short burst of readings every 40 seconds (those models with solar sensors do a second transmission every 60 seconds).
 
The legacy Cumulus 1 software would read data from these weather stations every 30 seconds, i.e. slightly more frequently than the updates, so sometimes it would read the same data twice. The way the "read-avoid" was implemented in the legacy software was that the software attempted to see which subsequent reads were same, and which were different, as the latter indicated a transmission had taken place. Thereafter, a (configurable) delay of a few seconds would ensure thereafter the 30 second interval reads would never clash with the update following transmission.
 
MX reads the same station type every 10 seconds, with extra processing once a minute, both timings are fixed, based on computer time. Therefore if read-avoid is enabled, then some of the fixed 10 second interval actions will be skipped. The current advice is not to enable the read avoid as the result can be that almost all reads are skipped.
 
===RG11 Rain gauge===
If you install MX on another operating system, then the file system is case sensitive, in this case MX will only recognise "strings.ini".
 
If you have not created a [[Strings.ini|strings.ini]] file in your (leagacylegacy) Cumulus top level folder, then you have no file to move to your MX installation, and you should skip the rest of this sub-section.
 
The contents of the [[Samplestring.ini|samplestring.ini]] file you get in your MX release distribution varies depending on the release you have downloaded.
=Library software=
 
Any non-technical person can skip this final sub-section!
 
MX uses a number of library software utilities like Highstock, jQuery, boot -strap, and others, see [[MX_Basic_info#Library_software_for_your_web_server]]. Be aware that MX determines the versions of these it seeks, and they may not match the versions needed for anything on your web server that is not supplied in the MX release distribution. A browser tries to reuse components that are already loaded, so there is a possibility of the wrong version being loaded.
5,838

edits

Navigation menu