Please be aware that the content in SAP SQL Anywhere Forum will be migrated to the SAP Community in June and this forum will be retired.

By default, every Windows install I've worked with has a paging file.

On a server that is dedicated to running SQL Anywhere database, I'm thinking we really don't need this file. The last thing we want is for Windows to think it knows more than the SQL Anywere engine in determining what should be temporarily written out to disk.

Has anyone tested this?

asked 14 May '10, 14:21

Ron%20Hiner's gravatar image

Ron Hiner
880202427
accept rate: 9%

no love for this question? Or does everybody run SQL Anywhere on OS X??

(17 May '10, 22:09) Ron Hiner

You might post this question on the general newsgroup (sybase.public.sqlanywhere.general) - I guess the relevant iAnywhere experts are (still?) more involved there...

(19 May '10, 07:48) Volker Barth

I wouldn't worry about the paging file. Running without one could lead to instability if you end up doing something that needs more memory than is available in your system. Perhaps, for example, you decide to run a web browser on that machine or a diagnostic tool such as ProcMon.

Windows isn't all that bad about using the swap space wisely. In fact, SQLAnywhere actually makes its dynamic cache sizing decisions based on what the Windows memory manager is doing. Whenever we evaluate whether to change the cache size, we consider that the amount of memory available to us in the system is "OS_free_memory + database_server_process_working_set_size". In other words, it is "memory that nobody is using + memory that the OS in all its wisdom and knowledge of everything that is going on in the entire system feels that the database server needs/deserves right now". It's actually a very simple yet powerful way for the database server to adapt to what is going on in the system as a whole.

Windows won't swap things to disk just because it can. It will do so because something else in the system needs memory and then, well, it's probably a good thing to swap. If you watch the working set (using perfmon, NOT task manager), you might notice that Windows will trim the server's working set size periodically. It will do so aggressively whenever you minimize the server's window for example. This behaviour is not problematic because those pages show up as "free" (ie the sum of "avail+working_set" stays the same) but, more importantly, they are not truly freed. The OS leaves the contents in memory but essentially protects the pages (marking them in the page tables as "not present") so that the process will get what is called a "soft fault" when it attempts to access them. Soft faults are inexpensive and essentially amount to a mechanism by which the OS can detect that you are still using that memory. If a sudden demand for memory arises in the system, the OS will first choose pages that are completely unused and then choose pages that have not been referenced "recently" (ie since they were trimmed from a working set).

-john.

permanent link

answered 27 May '10, 19:12

John%20Smirnios's gravatar image

John Smirnios
12.0k396166
accept rate: 37%

Great answer John! Thank you

(30 May '10, 18:22) Ron Hiner
Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:

×275
×49

question asked: 14 May '10, 14:21

question was seen: 2,444 times

last updated: 27 May '10, 19:12