Error while registering crawler by RegisterThisCrawler.bat

Has anyone encountered following error message when you execute the 'RegisterThisCrawler.bat'?

Finished initializing ProjectConfiguration for 'InfoShareBuilders'.
MACHINEXXXX::InfoShareBuilders pid[6224] threadId[1]
MACHINEXXXX::InfoShareBuilders::DatabaseTypeName[sqlserver2016]
MACHINEXXXX::InfoShareBuilders::Database[prod-db.intra.global.com][ISHCMDB][isource]
Initializing CatalogSettings...
Initializing CatalogStructure...
Finished initializing the CrawlerConfiguration for 'InfoShareBuilders'.
-------------------------------------------------------------------------------
Registering a Crawler for 'TrisoftInfoShareIndex' on 'MACHINEXXXX'
Adding the Crawler with hostname 'MACHINEXXXX' and catalogname 'TrisoftInfoShareIndex' failed with an error.
System.Transactions.TransactionAbortedException: The transaction has aborted. ---> System.TimeoutException: Transaction Timeout
--- End of inner exception stack trace ---
at System.Transactions.TransactionStateAborted.BeginCommit(InternalTransaction tx, Boolean asyncCommit, AsyncCallback asyncCallback, Object asyncState)
at System.Transactions.CommittableTransaction.Commit()
at System.Transactions.TransactionScope.InternalDispose()
at System.Transactions.TransactionScope.Dispose()
at Trisoft.InfoShare.Crawler.RegisteredCrawlersDataSqlServer.Add(String hostName, String catalogName)
at Trisoft.InfoShare.Crawler.RegisteredCrawlers.RegisterCrawler()
Crawler.RegisterCrawler => RegisteredCrawlers..ctor => RegisteredCrawlers.RegisterCrawler
Registering the Crawler for 'InfoShareBuilders' failed with an error.
System.Transactions.TransactionAbortedException: The transaction has aborted. ---> System.TimeoutException: Transaction Timeout
--- End of inner exception stack trace ---
at System.Transactions.TransactionStateAborted.BeginCommit(InternalTransaction tx, Boolean asyncCommit, AsyncCallback asyncCallback, Object asyncState)
at System.Transactions.CommittableTransaction.Commit()
at System.Transactions.TransactionScope.InternalDispose()
at System.Transactions.TransactionScope.Dispose()
at Trisoft.InfoShare.Crawler.RegisteredCrawlersDataSqlServer.Add(String hostName, String catalogName)
at Trisoft.InfoShare.Crawler.RegisteredCrawlers.RegisterCrawler()
at Trisoft.InfoShare.Crawler.RegisteredCrawlers..ctor(RegisterMode registerMode)
at Crawler.Crawler.RegisterCrawler()
Program.Main => Crawler.Process => Crawler.RegisterCrawler
# ErrorLevel was 0
# Relocating to starting position
# Script finished
Press any key to continue . . .

It seems that cause of issue is related to the database. Because, the issue occurred after I restored a database from a backup file.

When I restored the database, I overwrote the existing database. I'd like to make sure whether a new database should be created or it can be overwritten to an existing database when restoring database from the backup file.

Thanks,

Naoki

Parents Reply Children
  • Hi Dave-san,

    Yes, you are right. I think following page is better to understand about timeout/maxTimeout settings.

    http://kreelbits.blogspot.com/2013/09/systemtransactionstransactionscope.html

    Actually, I did following things to deal with this issue:

    (1) Modified "C:\Windows\Microsoft.NET\Framework\v4.0.30319\Config\machine.config"

    As described in the above page, set allowExeDefinition="MachineToApplication" on the system.transaction section group in the machine.config.

    <sectionGroup name="system.transactions" type="System.Transactions.Configuration.TransactionsSectionGroup, System.Transactions, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089, Custom=null">
    <section name="defaultSettings" type="System.Transactions.Configuration.DefaultSettingsSection, System.Transactions, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089, Custom=null" />
    <section name="machineSettings" type="System.Transactions.Configuration.MachineSettingsSection, System.Transactions, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089, Custom=null" allowDefinition="MachineOnly" allowExeDefinition="MachineToApplication"/>
    </sectionGroup>

    (2) Modified "C:\InfoShare\App\Crawler\Bin\Crawler.exe.config"

    Extended the maxTimeout to 1 hour and timeout to 30 minutes as below:

    <?xml version="1.0"?>
    <configuration>
    <system.transactions>
    <!-- The default transaction time-out should be smaller or equal than the maximum transaction time-out which is normally 10 minutes -->
    <defaultSettings timeout="00:30:00"/>
    <!--
    The maxTimeOut is set by the machine settings and is default 10 minutes. The maxTimeOut can normally only be set on the machine.config.
    In order to set the maxTimeOut in your application config, the attribute "allowExeDefinition" in the machine.config must be replaced from 'MachineOnly' to 'MachineToApplication' (see mantis 3058)
    -->
    <machineSettings maxTimeout="01:00:00"/>
    </system.transactions>

    (3) Executed 'UnregisterAllCrawlers.bat' as administrator

    (4) Executed 'RegisterThisCrawler.bat' as administrator

    Thank you for your assistance.

    Best regards,

    Naoki