Thursday, November 19, 2009

Java; A quest with unattended installation

Some guidelines for unattended Java installation in an Win2008 HPC Cluster environment:

  • Deactivate UAC on all nodes; Otherwise the nodes will simple hang, and wait for the UAC acceptance that will never happen. You can omit this by doing the first Java installation by hand via RDesktop login. Afterwards all successive unattended installation will succeed. We have currently no clue why. Perhaps some kind of adaptive UAC?
    Best practice is to deactive UAC via a registry key:
    %windir%\system32\reg.exe ADD HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\System /v EnableLUA /t REG_DWORD /d 1 /f

  • Reboot the nodes, so that the registry change becomes effective.

  • All will run smoothly now, if the user installing java was logged in to the nodes at least once. This poses a problem with 20++ cluster nodes. however. The basic point is, that there is no User directory created yet and neither are all temp and AppData paths.
    Java kindly ignores any variable defined by the OS, e.g. TEMP or TMP. And gathers its own temp dirs which leads to C:\Users\Username\AppData\LocalLow\Temp and many more.
    So the installation fails once more, unless these directories are there.
    So you have to create them yourself:
    mkdir C:\Users\%USERNAME%\AppData\LocalLow\Temp\

  • After that the usual JRE unattended deployment should proceed

Note, that any login to the nodes to be installed and any prior to that, java installation can change all of the above experiences

No comments:

Post a Comment