High Availability Administration Guide Release 4.0
Total Page:16
File Type:pdf, Size:1020Kb
GlassFish Server Open Source Edition High Availability Administration Guide Release 4.0 May 2013 This book describes thehigh-availability features in GlassFish Server, including converged load balancing, HTTP load balancing, clusters, session persistence and failover. Note: The main thrust of the GlassFish Server Open Source Edition 4.0 release is to provide an application server for developers to explore and begin exploiting the new and updated technologies in the Java EE 7 platform. Thus, the clustering, standalone instance and high availability features of GlassFish Server were not a focus of this release. These features are included in the release, but they may not function properly with some of the new features added in support of the Java EE 7 platform. GlassFish Server Open Source Edition High Availability Administration Guide, Release 4.0 Copyright © 2013, Oracle and/or its affiliates. All rights reserved. This software and related documentation are provided under a license agreement containing restrictions on use and disclosure and are protected by intellectual property laws. Except as expressly permitted in your license agreement or allowed by law, you may not use, copy, reproduce, translate, broadcast, modify, license, transmit, distribute, exhibit, perform, publish, or display any part, in any form, or by any means. Reverse engineering, disassembly, or decompilation of this software, unless required by law for interoperability, is prohibited. The information contained herein is subject to change without notice and is not warranted to be error-free. If you find any errors, please report them to us in writing. If this is software or related documentation that is delivered to the U.S. Government or anyone licensing it on behalf of the U.S. Government, the following notice is applicable: U.S. GOVERNMENT RIGHTS Programs, software, databases, and related documentation and technical data delivered to U.S. Government customers are "commercial computer software" or "commercial technical data" pursuant to the applicable Federal Acquisition Regulation and agency-specific supplemental regulations. As such, the use, duplication, disclosure, modification, and adaptation shall be subject to the restrictions and license terms set forth in the applicable Government contract, and, to the extent applicable by the terms of the Government contract, the additional rights set forth in FAR 52.227-19, Commercial Computer Software License (December 2007). Oracle America, Inc., 500 Oracle Parkway, Redwood City, CA 94065. This software or hardware is developed for general use in a variety of information management applications. It is not developed or intended for use in any inherently dangerous applications, including applications that may create a risk of personal injury. If you use this software or hardware in dangerous applications, then you shall be responsible to take all appropriate fail-safe, backup, redundancy, and other measures to ensure its safe use. Oracle Corporation and its affiliates disclaim any liability for any damages caused by use of this software or hardware in dangerous applications. Oracle and Java are registered trademarks of Oracle and/or its affiliates. Other names may be trademarks of their respective owners. Intel and Intel Xeon are trademarks or registered trademarks of Intel Corporation. All SPARC trademarks are used under license and are trademarks or registered trademarks of SPARC International, Inc. AMD, Opteron, the AMD logo, and the AMD Opteron logo are trademarks or registered trademarks of Advanced Micro Devices. UNIX is a registered trademark of The Open Group. This software or hardware and documentation may provide access to or information on content, products, and services from third parties. Oracle Corporation and its affiliates are not responsible for and expressly disclaim all warranties of any kind with respect to third-party content, products, and services. Oracle Corporation and its affiliates will not be responsible for any loss, costs, or damages incurred due to your access to or use of third-party content, products, or services. Contents Preface ................................................................................................................................................................. xi 1 High Availability in GlassFish Server Overview of High Availability .............................................................................................................. 1-1 Load Balancing With the Apache mod_jk or mod_proxy_ajp Module ....................................... 1-1 High Availability Session Persistence............................................................................................. 1-1 High Availability Java Message Service ......................................................................................... 1-2 RMI-IIOP Load Balancing and Failover.......................................................................................... 1-2 How GlassFish Server Provides High Availability ........................................................................... 1-3 Storage for Session State Data .......................................................................................................... 1-3 Highly Available Clusters................................................................................................................. 1-3 Recovering from Failures........................................................................................................................ 1-5 Recovering the Domain Administration Server ............................................................................ 1-5 Recovering GlassFish Server Instances........................................................................................... 1-5 Recovering the HTTP Load Balancer and Web Server................................................................. 1-5 Recovering Message Queue.............................................................................................................. 1-6 More Information..................................................................................................................................... 1-7 2 Enabling Centralized Administration of GlassFish Server Instances About Centralized Administration of GlassFish Server Instances ................................................ 2-1 Determining Whether to Enable Centralized Administration .................................................... 2-2 Considerations for Using DCOM for Centralized Administration ............................................ 2-2 Considerations for Using SSH for Centralized Administration.................................................. 2-3 Setting Up DCOM and Testing the DCOM Set Up........................................................................... 2-4 Windows Operating System Settings.............................................................................................. 2-4 To Enable the Windows User to Run Scripts on a Remote Host ................................................ 2-4 To Set Up Password Authentication for the Windows User ....................................................... 2-6 To Test the Connection Over DCOM to a Remote Host .............................................................. 2-7 Setting Up Cygwin SSH on Windows ................................................................................................. 2-8 To Download and Install Cygwin .................................................................................................. 2-9 To Set the Path for Windows and for the Cygwin Shell............................................................... 2-9 To Set the Home Directory for the Cygwin SSH User............................................................... 2-10 To Configure and Start the Cygwin SSH Server Daemon sshd ............................................... 2-10 Setting Up the MKS Toolkit on Windows........................................................................................ 2-11 To Install the MKS Toolkit............................................................................................................. 2-11 iii To Set the Path for Windows and for the MKS Toolkit Shell ................................................... 2-12 To Set the Home Directory for the MKS Toolkit SSH User ...................................................... 2-12 To Configure and Start the MKS Toolkit SSH Server Daemon sshd....................................... 2-14 Setting Up SSH on UNIX and Linux Systems................................................................................. 2-14 To Set Up SSH on Oracle Solaris Systems ................................................................................... 2-15 To Set Up SSH on MacOS Systems............................................................................................... 2-15 To Set Up SSH on Linux systems.................................................................................................. 2-16 Testing the SSH Setup on a Host........................................................................................................ 2-16 To Test the SSH Setup on a Host .................................................................................................. 2-17 Setting Up SSH User Authentication ................................................................................................ 2-17 To Set Up Public Key Authentication Without Encryption.....................................................