Changes for page Datenbankmanagement

Last modified by Sabrina V. on 2026/10/06 06:31

From version 1.1
edited by jklein
on 2024/08/13 08:28
Change comment: Imported from XAR
To version 9.1
edited by Sabrina V.
on 2026/10/06 06:31
Change comment: There is no comment for this version

Summary

Details

Page properties
Author
... ... @@ -1,1 +1,1 @@
1 -XWiki.jklein
1 +XWiki.SV
Content
... ... @@ -9,7 +9,7 @@
9 9  
10 10  Even if the database is working properly, there are bound to be problems over time, such as indexes becoming fragmented, logs taking up a lot of space, or the database itself simply becoming too large. The result is often a drop in performance, longer load times when retrieving data, or unpredictable behaviour of the database. In short, the database system no longer works as it should, or cannot be started at all until more space is created.
11 11  
12 -To counteract this, you should always take the time to maintain your existing database system. Below are some recommendations and hints on how to maintain your ACMP database and some useful countermeasures you can take.
12 +To counteract this, you should always take the time to maintain your existing database system. Below are some recommendations and hints on how to maintain your acmp database and some useful countermeasures you can take.
13 13  
14 14  {{aagon.infobox}}
15 15  The following examples are based on working with Microsoft SQL Server Management Studio. We recommend that you install the application that allows you to connect to a server to perform database maintenance. The Studio does not need to be installed on the server running the SQL Server instance!
... ... @@ -22,22 +22,21 @@
22 22  The purpose of reducing the size is therefore to free up space in the database. Either the database or the files it contains can be shrunk.
23 23  
24 24  {{aagon.warnungsbox}}
25 -It is essential that you make a database backup before you reduce the size of the database or individual files. If you have not yet made a backup, you must do so urgently. You alone are responsible for ensuring that the database can be restored in the event of an error. Read here how to create an [[ACMP backup >>doc:.Vollständiges ACMP Backup durchführen.WebHome]] and how to [[restore>>doc:.Vollständiges ACMP Backup einspielen.WebHome]] it.
25 +It is essential that you make a database backup before you reduce the size of the database or individual files. If you have not yet made a backup, you must do so urgently. You alone are responsible for ensuring that the database can be restored in the event of an error. Read here how to create an [[acmp backup >>doc:.Vollständiges ACMP Backup durchführen.WebHome]]and how to [[restore>>doc:.Vollständiges ACMP Backup einspielen.WebHome]] it.
26 26  {{/aagon.warnungsbox}}
27 27  
28 28  == Shrink database ==
29 29  
30 30  {{aagon.infobox}}
31 -When shrinking a database, make sure that applications such as ACMP or others are not accessing the database. If this is not the case, the shrink will not be optimal, will be very slow or will not be performed at all. So make sure that the relevant services do not access the ACMP database. Use the Activity Monitor to check for possible processes and stop them.
31 +When shrinking a database, make sure that applications such as acmp or others are not accessing the database. If this is not the case, the shrink will not be optimal, will be very slow or will not be performed at all. So make sure that the relevant services do not access the acmp database. Use the Activity Monitor to check for possible processes and stop them.
32 32  {{/aagon.infobox}}
33 33  
34 -The size of a database is reduced by reducing the size of the database files. This applies to the areas of the database files that are completely free (see also [[Defragmenting the Indexes>>doc:||anchor="HIndizesDefragmentierung"]]). If you only want to reduce the size of individual database files, use the [[//Reduce files//>>doc:||anchor="HDatenbankverkleinern"]] option.
34 +The size of a database is reduced by reducing the size of the database files. This applies to the areas of the database files that are completely free (see also [[Defragmenting the Indexes>>doc:||anchor="HIndexesDefragmentation"]]). If you only want to reduce the size of individual database files, use the [[//Reduce files//>>doc:||anchor="HReducingthesizeoffiles"]] option.
35 35  
36 36  After you have closed all relevant applications, processes and sessions, go to the Microsoft SQL Server Management Studio left-hand navigation and select the database you want to shrink. Right-click to open the context menu and click //Tasks// > //Contract// > //Database//.
37 37  
38 38  {{figure}}
39 -(% style="text-align:center" %)
40 -[[image:66_Datenbank_Datenbank verkleinern_690.png]]
39 +[[image:66_Datenbank_Datenbank verkleinern_690.png||data-cmp-info="10" data-xwiki-image-style-alignment="center"]]
41 41  
42 42  {{figureCaption}}
43 43  Shrink database
... ... @@ -62,14 +62,13 @@
62 62  If you do not want to reduce the size of an entire database directly, but only selected database files and/or groups of files, you can make such changes separately. This can be useful if, for example, you can identify which of your database files are very large and you want to reduce their size. In this case, the size of the database will be reduced by reducing the size of individual files or groups of files.
63 63  
64 64  {{aagon.infobox}}
65 -Please note that this procedure does not free up any allocated database space. To do this, you must include all the database files, which can be done using the [[Shrink database>>doc:||anchor="HDatenbankverkleinern"]] option.
64 +Please note that this procedure does not free up any allocated database space. To do this, you must include all the database files, which can be done using the [[Shrink database>>doc:||anchor="HShrinkdatabase"]] option.
66 66  {{/aagon.infobox}}
67 67  
68 68  In Microsoft SQL Server Management Studio, open the database in which you want to shrink files. Right-click to open the context menu and select //Tasks// > //Shrink// > //Files//.
69 69  
70 70  {{figure}}
71 -(% style="text-align:center" %)
72 -[[image:66_Datenbank_Datei verkleinern_690.png]]
70 +[[image:66_Datenbank_Datei verkleinern_690.png||data-cmp-info="10" data-xwiki-image-style-alignment="center"]]
73 73  
74 74  {{figureCaption}}
75 75  Reducing the size of files
... ... @@ -76,7 +76,7 @@
76 76  {{/figureCaption}}
77 77  {{/figure}}
78 78  
79 -In the //Database// row you can check that you have selected the correct database. In this case you should see the name of the ACMP database. In the pictures above this is called "ACMP". You can now select the type under the //Database Files and File Groups// heading.
77 +In the //Database// row you can check that you have selected the correct database. In this case you should see the name of the acmp database. In the pictures above this is called "acmp". You can now select the type under the //Database Files and File Groups// heading.
80 80  
81 81  {{aagon.infobox}}
82 82  Depending on the file type selected, the user interface may vary slightly as not all fields are always available.
... ... @@ -110,17 +110,16 @@
110 110  Make sure that your user account has the appropriate rights to perform a defragmentation.
111 111  {{/aagon.warnungsbox}}
112 112  
113 -Click //Connect// and the Management Studio will open in the background. Navigate to the Object Explorer on the left hand side of the menu bar and open the ACMP database.
111 +Click //Connect// and the Management Studio will open in the background. Navigate to the Object Explorer on the left hand side of the menu bar and open the acmp database.
114 114  
115 115  {{aagon.infobox}}
116 116  Make sure you select the correct database from the drop down box to avoid making changes to the wrong database.
117 117  {{/aagon.infobox}}
118 118  
119 -Executions Right click on the ACMP Database and select //New Query// from the context menu that opens.
117 +Executions Right click on the acmp Database and select //New Query// from the context menu that opens.
120 120  
121 121  {{figure}}
122 -(% style="text-align:center" %)
123 -[[image:66_Datenbank_Aufruf einer neuen Abfrage_478.png]]
120 +[[image:66_Datenbank_Aufruf einer neuen Abfrage_478.png||data-cmp-info="10" data-xwiki-image-style-alignment="center"]]
124 124  
125 125  {{figureCaption}}
126 126  Insert new query
... ... @@ -135,8 +135,7 @@
135 135  ##EXEC ap_index_defrag 0,0##
136 136  
137 137  {{figure}}
138 -(% style="text-align:center" %)
139 -[[image:66_Datenbank_Ausführung einer neuen Abfrage_837.png]]
135 +[[image:66_Datenbank_Ausführung einer neuen Abfrage_837.png||data-cmp-info="10" data-xwiki-image-style-alignment="center"]]
140 140  
141 141  {{figureCaption}}
142 142  Execute query SQL script in query
... ... @@ -144,20 +144,20 @@
144 144  {{/figure}}
145 145  
146 146  {{aagon.infobox}}
147 -Make sure that you have selected the correct entry from the available databases (here: ACMP), so that you can run the query on the correct database.
143 +Make sure that you have selected the correct entry from the available databases (here: acmp), so that you can run the query on the correct database.
148 148  {{/aagon.infobox}}
149 149  
150 150  Then click on //Executions//. Two tabs (Results and Messages) will open at the bottom of the Editor, displaying messages after each execution (whether successful or not). Close Microsoft SQL Server Management Studio when you are finished.
151 151  
152 -The command rebuilds the indexes of the ACMP database and also performs a reduction of the database..
148 +The command rebuilds the indexes of the acmp database and also performs a reduction of the database..
153 153  
154 154  {{aagon.warnungsbox}}
155 155  Running the above SQL script in combination with [[backup>>doc:.Vollständiges ACMP Backup durchführen.WebHome]] should be done regularly (e.g. once a month) to avoid possible database problems.
156 156  {{/aagon.warnungsbox}}
157 157  
158 -= ACMP database too large due to log files =
154 += acmp database too large due to log files =
159 159  
160 -The ACMP database can also fill up quickly and become too large because of the log files.
156 +The acmp database can also fill up quickly and become too large because of the log files.
161 161  
162 162  The log files are important for two reasons:
163 163  
... ... @@ -167,20 +167,19 @@
167 167  
168 168  The log files are located under //MSSQL\Data//. However, the database and the log file should each be on a separate disk, which not only separates them but also improves performance. The files are saved as MDF or LDF files, where the MDF files contain the actual data and are therefore often larger than the LDF file. The LDF file is a support file that stores information about the transaction logs. Check both the location and the size of the files.
169 169  
170 -If you have not set any or incomplete settings for the log files, you can change these in the properties of the ACMP Database. To do this, first exit the ACMP server service.
166 +If you have not set any or incomplete settings for the log files, you can change these in the properties of the acmp Database. To do this, first exit the acmp server service.
171 171  
172 -Then open the Microsoft SQL Server Management Studio, log in using the login information and then select the ACMP Database in the navigation on the left. Execute a right-click on the ACMP Database and click on Properties in the context menu that opens. The database properties for the database open. Select the Options menu item. In the second position in the view is the entry Recovery Model. The [[Recovery Model>>https://learn.microsoft.com/de-de/previous-versions/sql/sql-server-2008-r2/ms189275(v=sql.105)?redirectedfrom=MSDN) ]] is an option with which you can define how a los is handled:
168 +Then open the Microsoft SQL Server Management Studio, log in using the login information and then select the acmp Database in the navigation on the left. Execute a right-click on the acmp Database and click on Properties in the context menu that opens. The database properties for the database open. Select the Options menu item. The first column in the view is the sort order. Select the //Latin1_General_CI_AS// collation that we recommend (see also the graphic below). This collation is used for both Unicode and non-Unicode. In the second position//, //define a //Recovery Model//. The [[Recovery Model>>https://learn.microsoft.com/de-de/previous-versions/sql/sql-server-2008-r2/ms189275(v=sql.105)?redirectedfrom=MSDN) ]] is an option with which you can define how a los is handled:
173 173  
174 174  |(% style="width:136px" %)**Recovery Model**|**Explanation**
175 175  |(% style="width:136px" %)Full|All database changes are logged. There are no time or size restrictions. Storage and backup requirements are significantly increased.
176 176  |(% style="width:136px" %)Bulk logged|As with the full recovery model, a log backup is created, but this model uses slightly less storage and keeps the backup smaller. It can be used, for example, for an import with a large number of records.
177 -|(% style="width:136px" %)Simple|The log memory is automatically freed as this model can only write to files up to a certain size. The oldest data is deleted when the size is reached. This model is often used for the ACMP database.
173 +|(% style="width:136px" %)Simple|The log memory is automatically freed as this model can only write to files up to a certain size. The oldest data is deleted when the size is reached. This model is often used for the acmp database.
178 178  
179 179  If "Full" or "Bulk logged" is set in the drop-down field, change the entry to "Simple".
180 180  
181 181  {{figure}}
182 -(% style="text-align:center" %)
183 -[[image:66_Datenbank_Datenbankeigenschaften_698.png]]
178 +[[image:66_Datenbank_Datenbankeigenschaften_698.png||data-cmp-info="10" data-xwiki-image-style-alignment="center"]]
184 184  
185 185  {{figureCaption}}
186 186  Customize recovery model
... ... @@ -189,4 +189,4 @@
189 189  
190 190  Then click //OK// and the window will close.
191 191  
192 -Then reduce the size of your database. To do this, follow the steps in the section [[Shrinking the database>>https://learn.microsoft.com/de-de/previous-versions/sql/sql-server-2008-r2/ms189275(v=sql.105)?redirectedfrom=MSDN) ||anchor="HDatenbankverkleinern"]]. 
187 +Then reduce the size of your database. To do this, follow the steps in the section [[Shrinking the database>>https://learn.microsoft.com/de-de/previous-versions/sql/sql-server-2008-r2/ms189275(v=sql.105)?redirectedfrom=MSDN) ]]. 
© Aagon GmbH 2026
Besuchen Sie unsere aagon-Community