EAS Adminstration

eas Problemlösungen

eas Problemlösungen

eas Index defekt (File does not exist)

Wenn dieser Fehler auftritt, hilft bisher nur der Neuaufbau des Index

image.png

Otris Exception Output
Type:     N5boost10wrapexceptIN5otris6search17SearcherExceptionEEE
File:     ../../../../Core/src/otris/eas/clucene/LuceneSearcher.cpp at line 210
Function: void otris::clucene::LuceneSearcher::initialize() 
Info:     Objectname="/var/lib/eas/store1/index"
Info:     Message="File does not exist"
Info:     ErrorCode="1"

Der Neuaufbau kann durch folgenden Befehl gestartet werden:

docker compose exec eas eas -c /etc/eas/store1.ini --rebuild-index -v --force-reset-index


eas cli

eas

Main tool for creating and maintaing a store.

For a more detailed description see Systemdokumentation (German only).

Synopsis

Allowed options:
  -h [ --help ]                    Produce this help message
  -i [ --initialize ]              Initializes an archive
  --crawl                          Crawls the archive folder and rebuilds the
                                   registry
  --incremental                    add entries instead of rebuilding the
                                   registry during crawl
  --start-dir arg                  Crawls all subfolders of the given start
                                   directory
  --no-last-write-time             Do not use last write time as archive date
                                   time
  --rebuild-index                  Rebuilds the search index
  --update-index                   Updates the existing index
  --reindex                        Reindexes search index entries
  --condition arg                  Query to determine the entries to be reindex
  -r [ --restore ]                 Restores the registry and the search index
  --spool-cleanup                  Removed outdated files from the spool
                                   directory
  --temp-cleanup                   Removes archived temp files
  --delete-empty-dirs              Empty directories will be deleted when
                                   cleaning up
  -c [ --config-file ] arg         Use given config-file
  -v [ --verbose ]                 Be verbose
  -d [ --debug ]                   Produces debugging messages
  --log-level arg                  Produces specified log message
  --decrypt arg                    Decrypts the given file
  --encrypt arg                    Encrypts the given file
  --generate-key arg               Generates a key of the given length for
                                   encryption of files
  --output arg                     Path for encryption and decryption output
  --verify-report                  Verifies the whole archive and generate a
                                   report with failed records
  --verify                         Verifies the whole archive
  --threads arg                    Numbers of used threads
  --max-documents arg              Maximum of documents (records and
                                   attachments) to be processed
  --migrate-index                  Clears/fills the index (recommended to call
                                   after changing the indexing mode
  --no-records                     No records will be indexed during index
                                   update
  --no-attachments                 No attachments will be indexed during index
                                   update
  --reset-index                    Resets the search index
  --force-reset-index              Forces a search index reset
  --set-index-status arg           Resets the index status of selected
                                   documents in the store
  --unlock-index                   Removes a remaining write lock on the index
  --version                        Prints the version number(s)
  --with-audit-trail               Minutes activity in the audit trail
  --audit-trail-path arg           Use the given file for writing the audit
                                   trail
  --template-ini arg               Creating the ini from a template
  --template-logging-conf arg      Creating the logging server conf from a
                                   template
  --template-values arg            Path to the file with the values used in the
                                   templates
  --template-value arg             A value used in a template
  --time-period-begin arg          Begin of a period of time specified
                                   according to ISO 8601
  --time-period-end arg            End of a period of time specified according
                                   to ISO 8601
  --logging-conf arg               Path to Loggingserver config file
  --init-counters-cache            Initialize counters cache in the registry
  --update-counters-cache          Updates the counters cache in the registry
  --drop-counters-cache            Remove the counters cache from the registry
  --optimize-index                 Consolidates and optimize the search index
  --max-batch-size arg             Number of objects a thread should index
  --max-merge-segment-size arg     Maximum size of segments that can be merged
  --max-segments arg               Maximum number of segments after
                                   optimization
  --migrate-registry arg           Path to a Sqlite registry to be migrated to
                                   SQL Server
  -x [ --exclusive-index-access ]  index is opened exlusively
  --index-batch-size arg           Size of indexing batches
  --registry-batch-size arg        Size of registry batches
  --only-newest-version            Reindex only the newest version
  --new-update-index               Use the new index mechanism
  --stop-at-time arg               Stops index updating at the given time, if
                                   it is not finished

Example

Create store

# eas -c /path/to/store.ini -i -v

Full restore

# eas -c /path/to/store.ini --restore -v

See also Restore

Rebuilding and updating the index

# eas -c /path/to/store.ini --rebuild-index -v
# eas -c /path/to/store.ini --update-index -v

See also Rebuild index

Verify store

# eas -c /path/to/store.ini --verify -v

See also Verification

Optimize index

Reduce the index to one segment file:

# eas -c /path/to/store.ini --optimize-index --max-segment 1 -v

Spool cleanup

Delete outdated files in the spool directory

# eas -c /path/to/store.ini --spool-cleanup -v

Migrate registry from SQLite to MS SQL Server

# eas -c /path/to/store.ini --migrate-registry -v

Additional log messages

Add --log-level or --debug to get additional message for the various commands. For instance, for the --restore command:

# eas -c /path/to/store.ini --restore --log-level error
# eas -c /path/to/store.ini --restore --log-level warn
# eas -c /path/to/store.ini --restore --log-level info
# eas -c /path/to/store.ini --restore --log-level debug
# eas -c /path/to/store.ini --restore --debug

eas restoring an index

Maintaining the index can be done by using the EAS command line tool eas. For all details eas, see the corresponding manual. In this howto, recommonded settings and maintenance operations are explained.

Rebuilding the index can be invoked as follows:

$ eas -c /path/to/store.ini -v --rebuild-index

Attention: Use these options carefully, as the data in existing indexes will be deleted completely:

Bsp. Aufruf zum updaten des Index:

eas -c /etc/eas/store1.ini --update-index

 

eas restoring the registry

Maintaining the registry can be done by using the EAS command line tool eas. For all details eas, see the corresponding manual. In this howto, recommonded settings and maintenance operations are explained.

Rebuilding the index can be invoked as follows:

$ eas -c /path/to/store.ini -v --crawl

Attention: Use these options carefully, as the data in existing data in the registry will be deleted completely:

eas verifying a store

To ensure, that the files are not changed, a verification can be executed on a store. The verification checks,

For technical checks of a stores index and registry, see also the tool eas-check.

Executing the verification

The verification can be executed using the eas. In a case of a successful verification the output looks like this:

# eas -c /path/to/store.ini --verify -v
[  1] Starting verify ...
[  2] Verified 11 / 11 files (100.0 %)
[  3] Finished verify
[  3] Elapsed time 0.6 s
[  4] No invalid signatures detected

In case of a changed record, an exception will be thrown:

# eas -c /path/to/store.ini --verify -v
[  1] Starting verify ...
[  2] Verified 11 / 11 files (100.0 %)
Otris Exception Output
Type:     struct boost::wrapexcept<struct otris::store::SignatureException>
File:     D:\jenkins\workspace\EAS-Develop-Windows-Build-VC16\label\EAS-Windows-
Build-VC16\Core\src\otris\eas\store\Signatory.cpp at line 626
Function: void __cdecl otris::store::Signatory::SignatureXmlHandler::check(void)

IO:       Filename="dso:2020/12/8/14/4315b631-80c4-4b2a-b475-b56d2f4bb90f/4315b631-80c4-4b2a-b475-b56d2f4bb90f.xml"
Info:     Message="Checksum mismatch for a reference!"

Boost Diagnostic Information
D:\jenkins\workspace\EAS-Develop-Windows-Build-VC16\label\EAS-Windows-Build-VC16\Core\src\otris\eas\store\Signatory.cpp(626): Throw in function void __cdecl otris::store::Signatory::SignatureXmlHandler::check(void)
Dynamic exception type: struct boost::wrapexcept<struct otris::store::SignatureException>
std::exception::what: Unknown exception
[struct otris::tag_file_name * __ptr64] = dso:2020/12/8/14/4315b631-80c4-4b2a-b475-b56d2f4bb90f/4315b631-80c4-4b2a-b475-b56d2f4bb90f.xml
[struct otris::tag_message * __ptr64] = Checksum mismatch for a reference!

A report file can be also created. It will be written to the standard outpu as CSV file:

# eas -c /path/to/store.ini --verify-report > verify.csv

The CSV file has the following structure:

"d:\tmp\worm/store1/ARCHIVE\2020/12/8/14/4315b631-80c4-4b2a-b475-b56d2f4bb90f\4315b631-80c4-4b2a-b475-b56d2f4bb90f.xmldsig";"Checksum mismatch! A refered file was changed!";"dso:2020/12/8/14/4315b631-80c4-4b2a-b475-b56d2f4bb90f/4315b631-80c4-4b2a-b475-b56d2f4bb90f.xml"