[X3 v12p30] Cannot import a Sage X3 folder due to console error about SQL Server but space provided is ample.

SOLVED

Hi.

Sage X3: v12 Patch 30

Console version: CFG 2.54.0.5

SQL Server: 2019 Standard

When I import a relatively small folder (about 20 GB).

```

Storage is not online

Database filegroups check failed

Error while creating database schema: Please check file {path}

ERR_FILEGROUP_CREATION

```

Checking the file.tra shows empty.

From the SQL Server, there is ample of space provided:

D:\ is dedicated to log file.

L:\ is dedicated to SQL Server masterdata.

The recovery model is full.

The log file has been backed up and the log content is cleared daily so it should not be log issue.

The current filegroup list:

  

I am confused by the error generated by the console.

Additional notes: I cannot reduce the recovery model to simple and I cannot turn off the SQL Server instance.

Parents
  • 0

    Inside the console code, when this error happens, if the console is in debug mode we will log what is in the buffer. Can you set the console to debug mode, try again, and look into the global trace and provide those additional details here please? The console settings on the global tab is where you set the config.global.debug = true and config.adxadmin.debug to true. 

    I suppose, since you asked for YSILP4 to be created, and you are showing that it never was, then you could capture the SQL command with a profiler trace (or perhaps the debug configuration would get it too in many cases), then run that directly in SSMS and check the results. 

    Any chance this database is set to be a contained database? 

    Were you able to import without filegroups?

    Lastly, did you have a look at the SQL Error Logs at the time of the creation?

  • 0 in reply to Delamater

    Hi,

    The SQL Server instance is set to Microsoft default SQL Server installation settings except the required Sage X3 collation change to Latin1_General_BIN2.

    > By default, SQL Server instance is not set for contained databases. Unsure if it need to be switched to True but I have not changed the setting yet.

    Were you able to import without filegroups?

    > Yes; old method worked. YSILP4 was imported successfully this way.

    The console settings on the global tab is where you set the config.global.debug = true and config.adxadmin.debug to true.

    > Confusingly, YSILP5 folder import passed (see below) after I set those two settings on global tab at the end and adxadmin tab respectively.

    Lastly, did you have a look at the SQL Error Logs at the time of the creation?

    > I, uh, forgotten to look at it at that time. The SQL Server's server log at that time was lost (oldest found is 16th).

  • 0 in reply to chunheng

    It is not necessary to change to contained database. 

    The debug settings wouldn't fix this problem. If everything is suddenly working, perhaps the connection to the storage went offline and then came back online. You could check the Windows event viewer logs for the connection problem, perhaps some type of ISCSI error is mentioned (or however you are connecting )at, or around the time you had the issue. The SQL Server logs would have been ideal. 

Reply
  • 0 in reply to chunheng

    It is not necessary to change to contained database. 

    The debug settings wouldn't fix this problem. If everything is suddenly working, perhaps the connection to the storage went offline and then came back online. You could check the Windows event viewer logs for the connection problem, perhaps some type of ISCSI error is mentioned (or however you are connecting )at, or around the time you had the issue. The SQL Server logs would have been ideal. 

Children
  • 0 in reply to Delamater

    Hi Delamater,

    I am currently doing old way without filegroup to expediate now due to urgency. Managed to reproduce issue just now.

    Let's say current folder list (In order of creation/import):

    X3

    SEED (Filegroup)

    YSILP5 (Filegroup)

    YSILP6 (Filegroup)

    I completely delete YSILP6 and its filegroup.

    I waited 5 mins after receiving a completion run from the script.

    I confirmed from SQL database side the filegroup is only:

    SEED (Filegroup)

    YSILP5 (Filegroup)

    From Sage X3 console, I import YSILP99 as Filegroup:

    Console error.

    Error content is (paraphrased):

    Name Store Status

    SEED C:\SEED ONLINE

    YSILP5 C:\YSILP5 ONLINE

    YSILP99 C:\YSILP6 OFFLINE

    YSILP99 C:\YSILP99 ONLINE

    Was there an additional step I must take to complete the folder's filegroup cleanup?

    I have done a file shrink and file (IDX and DAT) remove and a filegroup removal.

  • +1 in reply to chunheng
    verified answer

    In SQL properties, I delete the files first, then go back into properties and delete the filegroups.

    After that backup the database, then backup the logfile and shrink it.

  • 0 in reply to Nick Ward

    I left the server alone for the day to complete its daily data and log backup (because FULL recovery model).

    Today tested an import with filegroup and it works without any complaints now.

    Approving Nick Ward as the answer since it was the backup log step I missed when dealing with SQL filegroups.

  • 0 in reply to Nick Ward

    Saved me a call to support, thank you