
ID 442461.03 14WE KEEP THINGS MOVING
The Motion Controller MC6 ...
3
Manual MC6
Measures are described below that can be taken with systems from STOBER
to increase the security of the file system and data in them for the event of a
power failure.
First shut down the system, then turn it off
If the MC6 is shut off while the software is writing a file to the Solid State Drive
(SSD) or CFast storage media, the file will be damaged in most cases.
Control software generally describes these storage media independently in
intervals of a few seconds. Because of this, the probability of causing damage
due to shutdown when the software is running is very high. However various
measures have been taken to minimize the occurrence of these conditions.
EWF Manager
The standard measure for protecting an application in an NTFS-based
Windows file system is the Enhanced Write Filter (EWF), which is included with
delivery of the embedded versions of Windows operating systems.
When EWF is activated, the operating system stores the data for the file
system in main memory during the boot process, thereby preventing the data
storage media from being written to directly.
Therefore if the voltage supply fails, only the data in main memory is affected.
In contrast, damage to the file system on the data storage media is prevented.
The EWF protects the entire partition, but at the same time prevents data from
being stored persistently on it. It does appear that data is being saved.
However, the data is located in main memory after the process is complete, not
on the storage medium! To write the data on the storage medium, the EWF
must first be deactivated and the system restarted. This means that it is
impossible to save data while the PLC is running without losing the protection
of the file system that is desired.
However, parts of the CODESYS runtime environment that are not variable
(software, licenses, configurations) can be protected by the EWF filter.
Several partitions have been set up on the MC6 for this purpose. One of them
contains the operating system and the non-variable elements of the CODESYS
runtime environment. This partition is protected by the EWF. Other partitions
are enabled for writing and are then used to store the boot project and if
necessary data that is generated by the PLC application.
This procedure can be used to ensure that the partition with the operating
system and CODESYS environment remains undamaged. It also makes it
possible to store variable data as well.
File system check
The CODESYS runtime environment on the MC6 is not started by the
conventional autostart mechanism of the operating system. Instead a batch
script is used for starting. The last command of this script initiates the start of
the runtime environment.
This is not a measure that contributes directly to improving the security of the
file system. However, it does make it possible to run checks before the start of
the runtime environment, so that possible damage to the file system can be
detected and countermeasures can be introduced.
Before the CODESYS runtime environment starts, the consistency of the file
system is checked automatically after a system starts up. This is done in
ReadOnly mode, which makes it possible to reduce the time required for the
check to a minimum.
If the file system is damaged, a repair is initiated automatically. The system
must leave ReadOnly mode to do this, but the required measure takes only a
few seconds. It is only started in the event that damage has occurred and
further contributes to increasing data security by automatically eliminating
minor defects.