Self-Hosted | Software Asset Management Content Library Import Remains in Progress After an On-Prem Database InterruptionIssue .kb-wrapper { max-width: 100%; font-family: Lato, sans-serif; font-size: 12pt; line-height: 1.7; color: #000000; } .kb-wrapper p { margin: 0 0 12px 0; } .kb-wrapper ul, .kb-wrapper ol { margin: 0 0 12px 24px; padding: 0; } .kb-wrapper li { margin: 0 0 6px 0; } .kb-wrapper a { color: #032D42; text-decoration: underline; } .kb-wrapper code { background: #e6f0f5; color: #032D42; border: 1px solid #b8cfd8; padding: 1px 4px; border-radius: 3px; font-family: Consolas, monospace; } A Software Asset Management content library import remains in progress after a database binary log capacity issue interrupts the import transaction. The database issue has been corrected, but the import cannot be canceled and its status does not change. Symptoms .kb-wrapper { max-width: 100%; font-family: Lato, sans-serif; font-size: 12pt; line-height: 1.7; color: #000000; } .kb-wrapper p { margin: 0 0 12px 0; } .kb-wrapper ul, .kb-wrapper ol { margin: 0 0 12px 24px; padding: 0; } .kb-wrapper li { margin: 0 0 6px 0; } .kb-wrapper a { color: #032D42; text-decoration: underline; } .kb-wrapper code { background: #e6f0f5; color: #032D42; border: 1px solid #b8cfd8; padding: 1px 4px; border-radius: 3px; font-family: Consolas, monospace; } The Software Asset Management content library import remains in progress for an extended period.The import job is no longer running.No corresponding transaction appears in the Active Node Transactions module.The Status fields on the Manage Software Library and related SAMP Import File records remain unchanged.The Status field might be read-only when the records are opened from a form. Facts .kb-wrapper { max-width: 100%; font-family: Lato, sans-serif; font-size: 12pt; line-height: 1.7; color: #000000; } .kb-wrapper p { margin: 0 0 12px 0; } .kb-wrapper ul, .kb-wrapper ol { margin: 0 0 12px 24px; padding: 0; } .kb-wrapper li { margin: 0 0 6px 0; } .kb-wrapper a { color: #032D42; text-decoration: underline; } .kb-wrapper code { background: #e6f0f5; color: #032D42; border: 1px solid #b8cfd8; padding: 1px 4px; border-radius: 3px; font-family: Consolas, monospace; } The affected product area is Software Asset Management.The Manage Software Library Import records are stored in the samp_manage_software_library table.The related import file records are stored in the samp_import_file table.No active job or database transaction remains to complete or cancel the import.No Business Rule on either table synchronizes the status of one record with the other.Write access is controlled by table-level ACLs. The user performing the update must have permission to update both tables.Use a background script only if the records cannot be updated from their list views. Release All Releases Cause .kb-wrapper { max-width: 100%; font-family: Lato, sans-serif; font-size: 12pt; line-height: 1.7; color: #000000; } .kb-wrapper p { margin: 0 0 12px 0; } .kb-wrapper ul, .kb-wrapper ol { margin: 0 0 12px 24px; padding: 0; } .kb-wrapper li { margin: 0 0 6px 0; } .kb-wrapper a { color: #032D42; text-decoration: underline; } .kb-wrapper code { background: #e6f0f5; color: #032D42; border: 1px solid #b8cfd8; padding: 1px 4px; border-radius: 3px; font-family: Consolas, monospace; } The database binary log reached capacity during the content library import transaction. The transaction stopped before the import and related import file records could be updated with a terminal status. After the underlying database issue was corrected, no active job or transaction remained to update these records. The status therefore continued to indicate that the import was in progress. Resolution .kb-wrapper { max-width: 100%; font-family: Lato, sans-serif; font-size: 12pt; line-height: 1.7; color: #000000; } .kb-wrapper p { margin: 0 0 12px 0; } .kb-wrapper ul, .kb-wrapper ol { margin: 0 0 12px 24px; padding: 0; } .kb-wrapper li { margin: 0 0 6px 0; } .kb-wrapper a { color: #032D42; text-decoration: underline; } .kb-wrapper code { background: #e6f0f5; color: #032D42; border: 1px solid #b8cfd8; padding: 1px 4px; border-radius: 3px; font-family: Consolas, monospace; } .kb-wrapper pre { margin: 0 0 16px 0; padding: 12px; overflow-x: auto; background: #e6f0f5; border: 1px solid #b8cfd8; border-radius: 3px; white-space: pre-wrap; } .kb-wrapper pre code { padding: 0; border: 0; background: transparent; } .kb-wrapper .kb-steps { list-style: none; margin-left: 0; counter-reset: kb-step; } .kb-wrapper .kb-steps > li { position: relative; min-height: 30px; margin: 0 0 16px 0; padding-left: 42px; counter-increment: kb-step; } .kb-wrapper .kb-steps > li::before { content: counter(kb-step); position: absolute; left: 0; top: 0; width: 28px; height: 28px; border-radius: 50%; background: #032D42; color: #63DF4E; font-weight: bold; line-height: 28px; text-align: center; } .kb-wrapper .kb-note { margin: 0 0 16px 0; padding: 12px; border-left: 4px solid #52B8FF; background: #e6f4ff; } .kb-wrapper .kb-warning { margin: 0 0 16px 0; padding: 12px; border-left: 4px solid #e6a817; background: #fff4e0; } Important: Use this procedure only after verifying that the import job is not running and that no associated transaction remains active. This procedure updates the status of orphaned import records; it does not stop an active import. Update the records from their list views Verify that the import job is not running.Verify that no corresponding transaction appears in the Active Node Transactions module.Open the list for the Manage Software Library table samp_manage_software_library.Add the Status field to the list if it is not already displayed.Set the affected Manage Software Library Import record's Status to Failed.Open the related SAMP Import File records in the samp_import_file table.Set the Status of each affected import file record to Failed.Refresh the records and verify that both the Manage Software Library Import record and all affected import file records display a status of Failed. Use background scripts when list editing is unavailable Warning: Background scripts directly update database records. Review and test the scripts in a non-production environment before running them in production. Confirm each Sys ID before execution. The scripts call setWorkflow(false), which suppresses workflow processing for the update. Run the following script once for the affected Manage Software Library Import record. Enter the record's Sys ID in manageSWLibraryImportSysID. var manageSWLibraryImportSysID = ""; // Enter the Manage Software Library Import record Sys ID updateMgSwLibraryStatus(manageSWLibraryImportSysID); function updateMgSwLibraryStatus(id) { var gr = new GlideRecord('samp_manage_software_library'); gr.addQuery('sys_id', id); gr.query(); while (gr.next()) { gr.setValue('status', 'failed'); gr.setWorkflow(false); gr.update(); } } Run the following script separately for each affected SAMP Import File record. Enter the record's Sys ID in sampImportFileSysID. var sampImportFileSysID = ""; // Enter the SAMP Import File record Sys ID updateSampImportFile(sampImportFileSysID); function updateSampImportFile(id) { var gr = new GlideRecord('samp_import_file'); gr.addQuery('sys_id', id); gr.query(); while (gr.next()) { gr.setValue('status', 'failed'); gr.setWorkflow(false); gr.update(); } } After running the scripts, open both records and verify that their Status fields are set to Failed. Related Links .kb-wrapper { max-width: 100%; font-family: Lato, sans-serif; font-size: 12pt; line-height: 1.7; color: #000000; } .kb-wrapper p { margin: 0 0 12px 0; } .kb-wrapper ul, .kb-wrapper ol { margin: 0 0 12px 24px; padding: 0; } .kb-wrapper li { margin: 0 0 6px 0; } .kb-wrapper a { color: #032D42; text-decoration: underline; } .kb-wrapper code { background: #e6f0f5; color: #032D42; border: 1px solid #b8cfd8; padding: 1px 4px; border-radius: 3px; font-family: Consolas, monospace; } Software Asset ManagementScripts - Background moduleKB0780755: Safety Tips for Writing Background Scripts