cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Summary

Error "The INSERT statement conflicted with the FOREIGN KEY constraint" is present in the FlexNet Manager Admin log.

Symptoms

When reviewing the flexnet.log from the Admin module the following error message may be present for a specific vendor. There may also be no activity present on the Activity tab for the vendor highlighted in the below error message.

Error Message if a Microsoft SQL Server database is used:

<DateAndTime> INFO [usagedatacollector.usagecache] [Timer-16] Couldn't find a primary vendor for vendor name: MLM in secondaryVendor.properties

<DateAndTime>INFO [usagedatacollector.usagecache] [Timer-16] Couldn't find a primary vendor for vendor name: MLM in secondaryVendor.properties

<DateAndTime> ERROR [usagedatacollector.usagecache] [Timer-16] Error inserting batch.

java.sql.BatchUpdateException: The INSERT statement conflicted with the FOREIGN KEY constraint "FK4690FBF66BB42BEF". The conflict occurred in database "flexnet", table "dbo.MGR_VENDORDAEMON", column 'id'.

at com.microsoft.sqlserver.jdbc.SQLServerPreparedStatement.executeBatch(SQLServerPreparedStatement.java:1160)

at org.jboss.resource.adapter.jdbc.WrappedStatement.executeBatch(WrappedStatement.java:519)

at com.flexnet.manager.usagedatacollector.usagecache.RTCache.ExecuteInsertBatch(RTCache.java:861)

at com.flexnet.manager.usagedatacollector.usagecache.RTMGROldPoolsCache.UpdateLicensePool(RTMGROldPoolsCache.java:694)

at com.flexnet.manager.usagedatacollector.usagecache.RTMGROldPoolsCache.FlashCache(RTMGROldPoolsCache.java:756)

at com.flexnet.manager.usagedatacollector.usagecache.RTCache.ProcessEventQueue(RTCache.java:545)

at com.flexnet.manager.usagedatacollector.usagecache.RTCache.access$200(RTCache.java:53)

at com.flexnet.manager.usagedatacollector.usagecache.RTCache$3.run(RTCache.java:375)

at java.util.TimerThread.mainLoop(Timer.java:555)

at java.util.TimerThread.run(Timer.java:505)


Error Message if an Oracle database is used:

2015-12-10 15:31:15,473 ERROR [usagedatacollector.usagecache] [Timer-16] Error inserting batch.
java.sql.BatchUpdateException: ORA-02291: integrity constraint (FLEXNET.FK5D4DF4C13DA44485) violated - parent key not found

at oracle.jdbc.driver.DatabaseError.throwBatchUpdateException(DatabaseError.java:674)
at oracle.jdbc.driver.OraclePreparedStatement.executeBatch(OraclePreparedStatement.java:9394)
at oracle.jdbc.driver.OracleStatementWrapper.executeBatch(OracleStatementWrapper.java:211)
at org.jboss.resource.adapter.jdbc.WrappedStatement.executeBatch(WrappedStatement.java:519)
at com.flexnet.manager.usagedatacollector.usagecache.RTCache.ExecuteInsertBatch(RTCache.java:861)
at com.flexnet.manager.usagedatacollector.usagecache.RTMGROldPoolsCache.UpdateLiceseUserPool(RTMGROldPoolsCache.java:722)
at com.flexnet.manager.usagedatacollector.usagecache.RTMGROldPoolsCache.FlashCache(RTMGROldPoolsCache.java:771)
at com.flexnet.manager.usagedatacollector.usagecache.RTCache.ProcessEventQueue(RTCache.java:545)
at com.flexnet.manager.usagedatacollector.usagecache.RTCache.access$200(RTCache.java:53)
at com.flexnet.manager.usagedatacollector.usagecache.RTCache$3.run(RTCache.java:375)

(etc)


Cause

This error message can appear in two scenarios, these will be explained below:

Cause 1:

The license file for the vendor has not yet been parsed by FlexNet Manager, when the activity is received by FlexNet Manager the vendor name cannot be referenced and produces the error.

Cause 2:

A Common Vendor Daemon is present in the license file, this is where the vendor name on the VENDOR line is different to the vendor name on the INCREMENT line, there would also be an AUTH line contained within the FEATURE definition, an example of this is below:

VENDOR MyVendor

?INCREMENT CVDT flexera 1.0 permanent 1 AUTH={ flexnet=( SIGN="059E 53CA \

2B51 DC72 1117 FE97 EEA4 5869 8C40 FB8F BF63 6E40 FF82 0E7E \

D034 1C21 AB59 9561 B47B 35DA C328 96B2 0B72 79AE 48D6 EDBD \

6711 B97B EA74 325B") flexera=( SIGN="059E 53CA 2B51 DC72 1117 \

FE97 EEA4 5869 8C40 FB8F BF63 6E40 FF82 0E7E D034 1C21 AB59 \

9561 B47B 35DA C328 96B2 0B72 79AE 48D6 EDBD 6711 B97B EA74 \

325B") accflexera=( SIGN="00A7 CBAE 1590 B572 554D 2CA1 9C23 3413 \

B3DA 3339 269D C200 8238 6210 C679 019D 1F6C B0C3 7346 6FF1 \

0FCF FFB6 BED4 1168 975A 96A8 FD19 EF76 A4EF 19C5") }?


Resolution

Cause 1 Resolution:

To resolve the issue ensure the license file from the vendor daemon referenced in the error message is present on the License files tab, this can be accessed from the "Licenses", "License Files" tab. If the file is not present on the License Files tab perform a re-read of the license file from the "Configure and Manage License Server" page.



Cause 2 Resolution:

The vendor name on the increment line needs to be mapped to the vendor name on the VENDOR line in order for the activity to be associated with correct vendor, causing the error message.

The SecondaryVendor.properties can file can be mapped so the activity can be processed when received, this file is located in the following directory "<AdminInstallationDirectory>/release/manager/webapps/flexnet/WEB-INF/classes"

Secondaryvendorname=primaryvendorname

Taking the example from above:

flexera=MyVendor

Note: Once the file has been saved please run "flexnet site make' to apply the changes.


Additional Information

Additional information on the Common Vendor Daemon can be located in the following KB:

000007735 - Common Vendor Daemon (Mapping Secondary Vendors to FNM)


Related KB Articles

https://na23.salesforce.com/articles/en_US/HOWTO/Q209361?popup=false&navBack=H4sIAAAAAAAAAIuuVipWslLyzssvz0lNSU_1yM9NVdJRygaKFSSmp4ZkluSA-KVAvn58aaZ-NkyhPpCDosu-ODWxKDnD1gAEzM2NTbWVamMBn90aZV8AAAA#
Was this article helpful? Yes No
No ratings
Version history
Last update:
‎May 26, 2018 01:00 PM
Updated by: