I am working in Acumatica 24R2 Build 24.205.0015. Currently, I am trying to update my local instance to be more up to date with our live instance. I took a snapshot of my Local, using the “Exclude Wiki and Attachments” setting. However, the snapshot file was larger than what is natively supported in Acumatica (My file size if 1.21GB). As a result, I followed the instructions from this link allow me to import larger snapshot files.
Now, I am able to upload the snapshot into my local tenant, however I am unable to actually restore the snapshot to the instance. Every time I try, I run into the following error.
“An error occurred while importing data into the 'GLTran' table.”
With the error stated being “System.IO.IOException: Stream was too long.”. Below I will also post the trace log that occurs.
Since the snapshot method did not work, I tried the method recommended in this post:
Unfortunately, even this does not seem to work perfectly due a couple of reasons. There does not seem to be resolution in relation to the loss of data in Usr Fields. There is also a complication related to a customization created by my service provider when I use this method.
Do we have a way to reliably use and restore large snapshots? I can’t imagine Acumatica would support the creation of a large snapshot if it would never be able to actually preform a restore with it.
Here is the trace for the error that occurs when importing the snapshot.
System.IO.IOException: Stream was too long.
at System.IO.MemoryStream.Write(Byte[] buffer, Int32 offset, Int32 count)
at System.IO.Stream.InternalCopyTo(Stream destination, Int32 bufferSize)
at PX.DbServices.Points.ZipArchive.ZipTableAdapter..MoveNext()
at PX.DbServices.Points.ZipArchive.ZipTableAdapter.
.MoveNext()
at PX.BulkInsert.Provider.TransferTableTask.Executor.[1].MoveNext()
at PX.DbServices.Model.DataSet.PxDataRows.
.MoveNext()
at PX.DbServices.Points.MsSql.MsSqlTableAdapter.BulkCopy(IEnumerable`1 rows, Boolean mayLockTable, ExecutionContext context, Action`1 transferObserver)
System.Exception: Stream was too long. Table name: GLTran. File name: . Line number: 0. ---> System.IO.IOException: Stream was too long.
at System.IO.MemoryStream.Write(Byte[] buffer, Int32 offset, Int32 count)
at System.IO.Stream.InternalCopyTo(Stream destination, Int32 bufferSize)
at PX.DbServices.Points.ZipArchive.ZipTableAdapter..MoveNext()
at PX.DbServices.Points.ZipArchive.ZipTableAdapter.
.MoveNext()
at PX.BulkInsert.Provider.TransferTableTask.Executor.[1].MoveNext()
at PX.DbServices.Model.DataSet.PxDataRows.
.MoveNext()
at PX.DbServices.Points.MsSql.MsSqlTableAdapter.BulkCopy(IEnumerable`1 rows, Boolean mayLockTable, ExecutionContext context, Action`1 transferObserver)
--- End of inner exception stack trace ---
at PX.DbServices.Points.MsSql.MsSqlTableAdapter.BulkCopy(IEnumerable`1 rows, Boolean mayLockTable, ExecutionContext context, Action`1 transferObserver)
at PX.DbServices.Points.DbmsBase.DbmsTableAdapter.WriteRows(IEnumerable`1 rows, Boolean exclusiveWrite, Action`1 transferObserver)
at PX.BulkInsert.Provider.TransferTableTask.Executor.Start(DataTransferObserver observer)
at PX.BulkInsert.Provider.BatchTransferExecutorSync.RunSingleTask(TransferTableTask task)
PX.Data.PXException: An error occurred while importing data into the 'GLTran' table. ---> System.Exception: Stream was too long. Table name: GLTran. File name: . Line number: 0. ---> System.IO.IOException: Stream was too long.
at System.IO.MemoryStream.Write(Byte[] buffer, Int32 offset, Int32 count)
at System.IO.Stream.InternalCopyTo(Stream destination, Int32 bufferSize)
at PX.DbServices.Points.ZipArchive.ZipTableAdapter..MoveNext()
at PX.DbServices.Points.ZipArchive.ZipTableAdapter.
.MoveNext()
at PX.BulkInsert.Provider.TransferTableTask.Executor.[1].MoveNext()
at PX.DbServices.Model.DataSet.PxDataRows.
.MoveNext()
at PX.DbServices.Points.MsSql.MsSqlTableAdapter.BulkCopy(IEnumerable`1 rows, Boolean mayLockTable, ExecutionContext context, Action`1 transferObserver)
--- End of inner exception stack trace ---
at PX.DbServices.Points.MsSql.MsSqlTableAdapter.BulkCopy(IEnumerable`1 rows, Boolean mayLockTable, ExecutionContext context, Action`1 transferObserver)
at PX.DbServices.Points.DbmsBase.DbmsTableAdapter.WriteRows(IEnumerable`1 rows, Boolean exclusiveWrite, Action`1 transferObserver)
at PX.BulkInsert.Provider.TransferTableTask.Executor.Start(DataTransferObserver observer)
at PX.BulkInsert.Provider.BatchTransferExecutorSync.RunSingleTask(TransferTableTask task)
--- End of inner exception stack trace ---
at PX.Data.Update.DtObserver.AskHowToRecoverFromError(Exception ex)
at PX.BulkInsert.Provider.BatchTransferExecutorSync.RunSingleTask(TransferTableTask task)
at PX.BulkInsert.Provider.BatchTransferExecutorSync.fetchAndRunNextTask()
at PX.BulkInsert.Provider.BatchTransferExecutorSync.StartSync()
at PX.Data.Update.DtObserver.AskHowToRecoverFromError(Exception ex)
at PX.BulkInsert.Provider.BatchTransferExecutorSync.StartSync()
at PX.Data.Update.PXSnapshotUploader.UploadSnapshot(ZipArchiveWrapper zip, Point point, FileFormat readFormats, FileFormat writeFormats)
at PX.Data.Update.PXSnapshotUploader.<>c__DisplayClass6_0.<Start>b__0()
at PX.Data.Update.DatabaseLock.DatabaseOperation(PXDatabaseProvider provider, Action act, Boolean lockDB, Boolean disableFullText)
at PX.Data.Update.PXSnapshotUploader.Start()
at PX.Concurrency.CancellationIgnorantExtensions.RunWithCancellationViaThreadAbort(Action method, CancellationToken cancellationToken)
at PX.Concurrency.CancellationIgnorantExtensions.<>c__DisplayClass1_0.<ToCancellationViaThreadAbort>b__0(CancellationToken cancellationToken)
at PX.Concurrency.Internal.PXLongOperationPars.PopAndRunDelegate(CancellationToken cancellationToken)
at PX.Concurrency.Internal.RuntimeLongOperationManager.PerformOperation(PXLongOperationPars p)