Chapter 6: VCs configuration method (I)

Source: Internet
Author: User
Chapter 6: VCs configuration method (I)Objectives:
Overview of Configuration Methods
Control VCs access
Online Configuration
Offline Configuration
Start and Stop VCs Overview of Configuration Methods
Online configuration: VCs does not need to be stopped (4 methods)
-Cluster Manager Java graphical user interface
-Cluster Manager Web graphical user interface
-VCs command-line interface
-Command batch files
Note: The configuration file you modified is in the middle of the memory, so when you complete the modification, you need to write it into the main. cf file of the disk.
Offline configuration: VCs must be stopped (2 methods)
-Manually modify the configuration file
-Use the VCs simulator to modify the configuration file
Note: after the modification is complete, restart VCs and create a new configuration in the memory. Effects on the Cluster
No matter which method you choose to configure VCs to manage an application service, you must plan the on-premises time of the application.
If you configure your first service group, you can keep VCs online or not.
If you already have a service group in the cluster, you also need to use the online configuration method, so those services are protected when you make changes. Control authorized access to VCs: User Account
1. Cluster Administrator)
Full privileges)
2. Cluster Operator)
All cluster and Service Group operations at the original level
(All cluster, service group, and resource-level operations)
3. Cluster guests (cluster guest)
Only read access is allowed. A new user is created as a cluster Guest account by default.
(Read-only access; new users created as cluster guest accouts by default)
4. Group Administrator)
All service group operations for a specified service group, except for deleting the Service Group
(All Service Group operations for a specified service group, cannot deleting service groups)
5. Group Operator)
Bring the service portfolio resources online and bring them offline, temporarily solidified or non-solidified service groups.
(Bring service groups and resources online and take them offline; temportarily freeze or unfreeze service groups)
For example, if you have an authorized DBA who wants to bring the Database Service Group offline or switch it to another system, you can set a VCs groupoperator account for this service group. This DBA can perform operations on the service group, but it cannot affect the cluster configuration or other service groups. Create a cluster User Account
Add a user account:
1. Enable cluster configuration
# Haconf-makerw
2. Use the Hauser command to add a new account
# Hauser-add Username
Change permissions
Use the haclus (cluster level) and hagrp (group level) commands
# Haclus-Modify Administrators | Operator-Add User
# Hagrp-Modify group Administrators | Operator-Add User
Modify user account
Show account information
# Hauser-Display
Change the password of an account
# Hauser-update user_name
Delete a user account
# Hauser-delete user_name Command for controlling VCs Access Permissions
As a preset, only the Unix root account can use the VCs ha command to manage VCs.
When you log on to Unix as a non-root account, every time you log on to the VCs command line, you are prompted to enter the name and password of A VCs account,
To make it easier for non-root users to manage VCs, you can set the attribute of cluster: allownativecliusers value to 1. When set, VCs maps the Unix user name to the same VCs account name to verify whether the user is valid and has the appropriate permission level to perform the operation.
Note: You must create each VCs account name to match the Unix user name and grant the appropriate permission level. Online Configuration
Benefits:
1. the VCs engine is up and running. In the configuration, if the existing high availability Service Group
2. This method provides syntax check to help protect you from making configuration errors.
3. As its configuration, the process is matched step by step for testing each target, simple configuration error troubleshooting when you add resources
4. You do not need to log on to the UNIX system as root, and use GUI and CLI to modify the configuration of VCs.
Concerns:
1. Online configuration is time-consuming for large-scale modifications
2. The online process is duplicated and you have to add service combo resources at the same time How does VCs modify the online cluster configuration?
Cluster Manager Configuration requests are displayed as Ha commands in the flowchart, but they are executed as IOCTLs
The had Process Communication configuration is changed to the nodes in all clusters of had. Each had process modifies the configuration in memory.
When the command saves the information received from the cluster manager, had communicates to all cluster systems. The had process of each system writes the configuration in memory to the main. cf file on its local disk.
The command line interface of VCs is an alternative online Configuration tool. When you run the HA command, had responds the same way. Open the cluster configuration)
You must enable cluster configuration to add service combo resources, make modifications, and perform some operations.
When you enable cluster configuration, create one in the configuration directory (/etc/vrtsvcs/CONF/config. stale file on the system in each cluster. this file indicates that the configuration is opened and the configuration does not match in the memory. The configuration is on the disk in the main. cf file Saving the cluster configuration)
When you save the cluster configuration, on all running Cluster Systems, VCs copies the configuration in the memory to the/etc/vrtsvcs/CONF/config/Main. cf file. The. Stale file is left in the configuration directory because the configuration is still opened.
If you save the cluster configuration after each modification, you can view the main. cf file to see how the modifications in the memory are reflected in the main. cf file. Disable cluster configuration (Closing the cluster configuration)
When the system administrator saves and disables the configuration, VCs writes the configuration in the memory to the main. cf file and deletes the. Stale file on all running Cluster Systems. How does VCs protect cluster configuration (how VCs protects the cluster configuration)
The. Stale file provides a protection mechanism for online configuration. When the. Stale file appears, you cannot stop VCs if no overriding the warning configuration is enabled.
If you ignore the warning and stop VCs, when the configuration is turned on, the disk main. the configuration in CF may not be the same as the configuration in the memory. When this happens, VCs considers the configuration invalid because the system administrator may have modified the configuration in the memory and did not write the configuration to the disk and disabled the configuration.
Although not often, a stale configuration can also lead to crashing of all systems in the cluster when the configuration is turned on.
To understand how the protection mechanism works, you must first understand the general VCs startup process. Offline Configuration
In most environments, You can simplify cluster execution or configure jobs by modifying the VCs configuration file immediately. This method requires that you stop and restart VCs in order to create new configurations in the memory.
Benefits:
1. Provide a very quick way to make major changes or get an initial configuration and run it.
2. Provide preparation for configuring a large number of similar clusters
Note: When you choose to execute the offline configuration, you must log on to the cluster system as the root user and convert from: http://hi.baidu.com/nitar/blog/item/42f0faf1dac9becf7831aaa8.html

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.