Database Full, how to free up space?


Outsystems tells me my database is full, how to free up some space?

Also can I create a schedule to delete data every month or week?

and if I use my own database, will this make me have more than 2gb?

Hello Faris,

You're probably using your Personal Environment, that's why you have only 2 GB (approximately) on your database.

Regarding to your questions:

1) Outsystems tells me my database is full, how to free up some space?
The only way to free up some space is precisely to delete some records or tables. For example, try to delete some old tables that you don't use anymore and some old records that you don't need.

2) Also can I create a schedule to delete data every month or week?
Of course. You can create a Timer and schedule it to run when you want. In this Timer, you should call an action in which you should define your logic. For example, you could implement a logic where you verify if a record is older than X days and (if so) delete it.

3) And if I use my own database, will this make me have more than 2gb?
If your use your own server database, the size will be the free space of your machine. You will have much more space than just 2 GB.


Kind regards,

Rui Barradas

It says that I'm using more than 2gb on system data


Rui Barradas wrote:

Hello Faris,

You're probably using your Personal Environment, that's why you have only 2 GB (approximately) on your database.

Regarding to your questions:

1) Outsystems tells me my database is full, how to free up some space?
The only way to free up some space is precisely to delete some records or tables. For example, try to delete some old tables that you don't use anymore and some old records that you don't need.

2) Also can I create a schedule to delete data every month or week?
Of course. You can create a Timer and schedule it to run when you want. In this Timer, you should call an action in which you should define your logic. For example, you could implement a logic where you verify if a record is older than X days and (if so) delete it.

3) And if I use my own database, will this make me have more than 2gb?
If your use your own server database, the size will be the free space of your machine. You will have much more space than just 2 GB.


Kind regards,

Rui Barradas


Glad to hear about the more space I can get! thanks


About the deleting records and tables, how to do this?

it tells me here that I have no version to delete


Hi.

There should be some email warnings before the server is full. Sometimes I get daily emails warning me about getting close to the limit and I'm a couple of hundred MB away.

To delete unused data you can install DBCleaner (not now because you don't have space to install it).

Right now your options are:

-if they exist, use the Back Offices you made to delete data.

-write to Support so they can install DBCleaner for you and you can clear data.


Hello again Faris,

Yes, when you use your Personal Environment, you only have 2 GB of available space. OutSystems usually allows a little bit more space just to be flexible.

As you can see, your problem is not the Application Data (related to the data that is in your database), but the System Data (related to application versions and resources). Are you using resources in your applications?


Kind regards,

Rui Barradas

Hi Faris,

Most of the space is occupied with System data, which is metadata and logging data.

If you use https://www.outsystems.com/forge/component-overview/5018/db-cleaner-on-steroids instead of DBCleaner you can configure automatic cleanups for all different types of logs and emails, allowing you to keep logging for a shorter time period that than OutSystems default does. This also helps to keep the amount of logged data occupied in your database to the bare minimum.

Another benefit of DBCleaner on steroids is that it is more actively maintained than DBCleaner.

Regards,

Daniel

Nuno Reis wrote:

Hi.

There should be some email warnings before the server is full. Sometimes I get daily emails warning me about getting close to the limit and I'm a couple of hundred MB away.

To delete unused data you can install DBCleaner (not now because you don't have space to install it).

Right now your options are:

-if they exist, use the Back Offices you made to delete data.

-write to Support so they can install DBCleaner for you and you can clear data.


I actually have DBcleaner just installed it yesterday but don't how to use it


Daniël Kuhlmann wrote:

Hi Faris,

Most of the space is occupied with System data, which is metadata and logging data.

If you use https://www.outsystems.com/forge/component-overview/5018/db-cleaner-on-steroids instead of DBCleaner you can configure automatic cleanups for all different types of logs and emails, allowing you to keep logging for a shorter time period that than OutSystems default does. This also helps to keep the amount of logged data occupied in your database to the bare minimum.

Another benefit of DBCleaner on steroids is that it is more actively maintained than DBCleaner.

Regards,

Daniel

OK just installed it, how to clean up my space in it?


Rui Barradas wrote:

Hello again Faris,

Yes, when you use your Personal Environment, you only have 2 GB of available space. OutSystems usually allows a little bit more space just to be flexible.

As you can see, your problem is not the Application Data (related to the data that is in your database), but the System Data (related to application versions and resources). Are you using resources in your applications?


Kind regards,

Rui Barradas

What do you mean by resources?


Answering all:

  • To use DBCleaner ot DBCLeaner on Steroids, you open it on the browser and read what it says. It allows you to delete all sort of content based on filters you can adjust.


  • Resources are files you place here. It also saves the Excels you bootstrap. Resources usually take a lot of space because, when poorly implemented, you can have copies of the same useless info in all the module versions.



Hi Faris,

First think about applications you build or downloaded from the forge that you no longer need. Go to service Studio open the application and press the delete button. Although the application and its data after delete no longer is available it isn't yet permanently removed from the database.

In DBcleaner and DBcleaner on Steroids you can remove deleted applications, modules and tables permenantly from the database.

Just try to understand the screens and the buttons, they are pretty self explainable.

One final comment, the cleanup actions you perform are not directly noticable in the amount of free space. Be patience it takes so time for the cleanup to finish (on the background) and for OutSystems to calculate the new available/used database space.

Regards,

Daniel

Faris Abdullah Almozini wrote:

What do you mean by resources?

Files in your Resource Folder.


If you don't have them, your problem should be related to metadata and logging data like Daniël said (most likely the metadata itself). Everytime you publish a module (with differences), a new version of that module is stored in the database and an entire new data is created to support that version. As you can see in the previous image, you have 265 versions just for a single module, which is quite a lot. This means that you've deployed 265 different versions that module. Make sure you reduce your publications to the bare minimum.

Right now, your best option is to use DB Cleaner on Steroids component.


Kind regards,

Rui Barradas

Nuno Reis wrote:

Answering all:

  • To use DBCleaner ot DBCLeaner on Steroids, you open it on the browser and read what it says. It allows you to delete all sort of content based on filters you can adjust.


  • Resources are files you place here. It also saves the Excels you bootstrap. Resources usually take a lot of space because, when poorly implemented, you can have copies of the same useless info in all the module versions.




Thanks freed up some unused ones but it wasn't much

Daniël Kuhlmann wrote:

Hi Faris,

First think about applications you build or downloaded from the forge that you no longer need. Go to service Studio open the application and press the delete button. Although the application and its data after delete no longer is available it isn't yet permanently removed from the database.

In DBcleaner and DBcleaner on Steroids you can remove deleted applications, modules and tables permenantly from the database.

Just try to understand the screens and the buttons, they are pretty self explainable.

One final comment, the cleanup actions you perform are not directly noticable in the amount of free space. Be patience it takes so time for the cleanup to finish (on the background) and for OutSystems to calculate the new available/used database space.

Regards,

Daniel

Oh so I won't see the result now! I was wondering why it hasn't changed, I deleted old apps I found many, but I have it says I'm using almost 2gb one ossys Espace, how to free them?


Rui Barradas wrote:

Faris Abdullah Almozini wrote:

What do you mean by resources?

Files in your Resource Folder.


If you don't have them, your problem should be related to metadata and logging data like Daniël said (most likely the metadata itself). Everytime you publish a module (with differences), a new version of that module is stored in the database and an entire new data is created to support that version. As you can see in the previous image, you have 265 versions just for a single module, which is quite a lot. This means that you've deployed 265 different versions that module. Make sure you reduce your publications to the bare minimum.

Right now, your best option is to use DB Cleaner on Steroids component.


Kind regards,

Rui Barradas


Yeah I did use it but 265 modules is too much, how can I clear that up?

You've been here for over a month. You can set DBCleaner to delete things older than two weeks for instance.

Nuno Reis wrote:

You've been here for over a month. You can set DBCleaner to delete things older than two weeks for instance.

Will this delete my active app data or just the unused apps and versions


Data is not on this tab.

This will delete old (not in use) version of your modules. If you set the minimum, you may end with only the latest version of each. But there will be always one of each at least.

There is another place to delete data from deleted modules.

Nuno Reis wrote:

Data is not on this tab.

This will delete old (not in use) version of your modules. If you set the minimum, you may end with only the latest version of each. But there will be always one of each at least.

There is another place to delete data from deleted modules.

Thanks, just did the timer, I will wait an hour for the changes to come through, hopefully my space will be much reduced


Any changes?

Nuno Reis wrote:

Any changes?

No changes, I think this is the problem:

There are no Module versions to be deleted.

258 Module versions are excluded from this list because they are used in tagged versions of applications or solutions.


I don't know how to delete the tagged modules

Hello Faris,

Let me clear one thing for you.

Everytime you publish a module (with differences), a new version of that module is stored in the database and an entire new data is created to support that version. That's why you have 265 versions just for a single module, which is quite a lot. This means that you've deployed 265 different versions that module. The entire data for each version is now stored in the database. This is the way OutSystems works in order to keep the repository of the versions.

Our suggestion is that you delete some old versions of the modules that you won't use anymore.


With DBCleaner or DBCleaner on Steroids, you are able to see the eSpace (module) version list, correct? You should be able to delete those old versions and maintain the recent ones.


Kind regards,

Rui Barradas

Rui Barradas wrote:

Hello Faris,

Let me clear one thing for you.

Everytime you publish a module (with differences), a new version of that module is stored in the database and an entire new data is created to support that version. That's why you have 265 versions just for a single module, which is quite a lot. This means that you've deployed 265 different versions that module. The entire data for each version is now stored in the database. This is the way OutSystems works in order to keep the repository of the versions.

Our suggestion is that you delete some old versions of the modules that you won't use anymore.


With DBCleaner or DBCleaner on Steroids, you are able to see the eSpace (module) version list, correct? You should be able to delete those old versions and maintain the recent ones.


Kind regards,

Rui Barradas

like I mentioned above, I keep having this error when trying to delete old modules:

258 Module versions are excluded from this list because they are used in tagged versions of applications or solutions.



Hi Faris,

I would like to recommend you to use the DB Cleaner on Steroids

  1. Open the "DB Cleaner On Steroids" app
  2. Select the eSpaces tab
  3. On the Filters section, put "-1" on the "Choose a timeline" input (This will show you all the current versions instead of a specific weekly timeline) (Image below)
  4. Click "Delete" on the application that is taking up the most space or "Delete All" to clear everything. (Keep in mind, this will not delete your application but instead will leave only the current version and delete older ones)





On an extra note, "DB Cleaner On Steroids" has a feature that might be useful to you. (Image below)
If you go to "DB Cleaner On Steroids" module over on Service Center, there are 2 Site Properties you can change.
OldApplicationVersions and OldSolutionVersions are both set to 10.
You can change them both to 0. This will make it so that only the current version is stored and older versions will be cleaned.

Keep in mind, this will be useful in terms of database space savings but won't let you go back to previous versions.


Hope it helps you.

@Daniel Martins,

Faris opened various posts to get his database size reduced, last week I reached out to him already and fixed the issue. His database size is was reduced from 88 to 27% using DB Cleaner on Steriods.

Regards,

Daniel