Select Page

Preparing Windows for an Oracle Database

Oracle Database on a Windows System?
This is not really working!

I hear this statement often from customers as well as from experienced consultants. For sure in the early Windows server version, there were more than one pitfalls. But I think with Windows server version 12R2 and onward there is no reason not to run an Oracle database on a Windows system. But like on a *nix system you have to prepare your Windows platform for a stable running Oracle database. This post will show you how you can prepare your Windows in a fast way for a save operating.

Windows preparation

Before you start with an Oracle database installation there are few preparation tasks. And yes… it is a Windows system and after those changes you need a reboot which should not be a problem. Otherwise you should think anyway if you will do this changes on a running system.

All tasks must be run under the administrator context of windows!

Deactivate Last Access Time

On a database system there is no reason to collect the last access time on a file. This is only an overload for the operating system. Also, the information itself is of no concern to a database administrator.

Deactivate Last Access Time (DOS Mode)
fsutil behavior set disablelastaccess 1
Deactivate Last Access Time (PowerShell Mode)
New-ItemProperty -Path 'HKLM:/SYSTEM/CurrentControlSet/Control/FileSystem' -Name 'NtfsDisableLastAccessUpdate' -PropertyType DWORD -Value 2147483651 -Force

Deactivate IPv6

Is there no need for an IPv6 configuration you can deactivate this IP stack completly.

Deactivate IPv6 stack (PowerShell Mode)
New-ItemProperty -Path 'HKLM:/SYSTEM/CurrentControlSet/Services/Tcpip6/Parameters' -Name 'DisabledComponents' -PropertyType DWORD -Value 255 -Force

Deactivating IPv6 only over the ethernet properties deactivate the IPv6 stack not in a way that windows not try to connect for localhost not over the IPv6 address ::1.

Update TCP/IP Wait Timeout and Max User Ports

If there is a high session load expected on the database system, minimize the TCP/IP Wait Timeout that the system not run out of free sockets

Upate TCP/IP Wait Timeout (PowerShell Mode)
New-ItemProperty -Path 'HKLM:/SYSTEM/CurrentControlSet/Services/Tcpip/Parameters' -Name 'TcpTimedWaitDelay' -PropertyType DWORD -Value 30 -Force
New-ItemProperty -Path 'HKLM:/SYSTEM/CurrentControlSet/Services/Tcpip/Parameters' -Name 'MaxUserPort' -PropertyType DWORD -Value 65534 -Force

Line 1 will update your TCP/IP timeout wheras line 2  will update how many ports can be used from the system.

Optimize File System Caching

By default the Windows operating system will manage around 60% of the memory for filesystem caching. There is no reason if you run an Oracle database on Windows, that the operating system manage that much filesystem cache because the database has his own caching in form of the SGA. After a longer search about File System Caching and how you can update this value I have found the script SetSystemFileCache.ps1 which was written by Andrew Jones.

After you have download the script you should update the variable $MaxPercent to around 10%. Don’t set the value that low that Windows have less then 800M for filesystem caching. The script must be executed after each server reboot, so best joice is to add an additional task into the Windows scheduler.

Windows User

For seperation of duty it is helpful if you create for the installation and the runtime two seperate windows accounts. The installation user needs local administration rights whereas the runtime user is a user or a ‘Domain User’. The runtime user has no administration rights. Take care, that logon passwords for those two users are not expiring.


This few tasks are helpfully for the later operating of  an Oracle database on a Windows server. The past has shown that Windows systems run without issues from one Oracle patch windows to the next, which is around three month. For sure you have to clarify how the customer handles the Windows updates during this time, but mostly customers have there already timeline planed and are aware that a short downtime is needed for the reboot. Like on *nix systems if you don’t buy an option for online kernel patching.