Resize ASE database in NPL 7.52 SP 04

By default, NPL is shipped with database size ~25GB, and ~2GB free storage but what if this space will end? Today I will show you a fast solution for resizing the database in NPL 7.52 SP 04. Why for this particular version? In older versions, the only thing you have to do is simply execute disk resize and alter the database, but this particular is affected by a small issue.

Issue explanation

This tutorial can cause issue on your database, which can be solved by 'reorg rebuild’ command. Please see side effect section

If you just resize this database you probably get in any case a message:

This is probably caused by known ASE limitations. More information is available here. And in notes:

If you download and execute a script attached to 2822555, you will see a similar error:

Basically, between rows 1614592 and 1835008 is a hole, which causes our problem. To avoid this we have to patch it.

Prepare system

Lets login to the sybnpl, and increase 'max memory’ parameter first:

Note about memory configuration is available here.

Now let’s allow updates on system tables

Patch the hole

If the database is not resized yet, we can perform now this operation. In my case, I increase DB space at 5 GB up to ~30 GB

Now it’s time to the most important line

After all, it is also a good idea to run

Now your DB should be properly resized.

Side effects

It is possible that someday you get a dump like:

If you check your sm21, there should be a message error with the table name, like:

If you get an error like this, you should run reorg on the table mentioned in the message, i.e.

Sprawdź też

sac tutorial