Pages

Installing VMware vCenter Server 8 (VCSA 8.0)

Introduction

VMware vCenter Server 8 is the centralized management platform for VMware vSphere environments. It allows administrators to manage multiple ESXi hosts, virtual machines, networking, storage, and security from a single interface. In this blog post, we’ll walk through a practical, step-by-step installation of vCenter Server Appliance (VCSA) 8.0.2, based on the attached installation notes.

This guide is suitable for system administrators, virtualization engineers, and anyone planning to deploy or upgrade to vCenter 8 in a lab or production environment.


Prerequisites:

Before starting the installation, ensure the following prerequisites are met:

  • A supported ESXi host already installed and reachable
  • DNS configured (forward and reverse lookup recommended)
  • Static IP address for the vCenter Server Appliance
  • Root credentials for the ESXi host
  • A workstation with Windows OS to run the installer
  • vCenter Server ISO image

Visit the Broadcom Support Portal Downloads site: https://support.broadcom.com/group/ecx/downloads and sign in 

Select VMware vSphere from the list of the products or use the search to narrow down the products first

From Window11 or Server Mount the vCenter Server 8 ISO :VMware-VCSA-all-8.0.2-XXXXXXXX.iso

After mounting the ISO, navigate to the Windows installer directory:

G:\vcsa-ui-installer\win32\installer

Double-click installer.exe to launch the vCenter Server Appliance installer.

vCenter Server Installation – Stage 1 (Deploy Appliance)

Launch Installer

  • Click Install on the welcome screen

 

Click Next

Review and accept the End User License Agreement (EULA) then Next


Select Deployment Target

  • Enter ESXi host IP or FQDN : 192.168.10.91
  • Provide ESXi root username and password
  • Click Next

 

Accept the SSL certificate warning then Next


Stating Validation


Set Appliance Name and Root Password

  • Provide a unique VM name: INDDCPVCS01 for vCenter Server
  • Set a strong root password for the appliance

 

Stating the Validation


Select Deployment Size

Choose a deployment size based on your environment:

  • Tiny
  • Small
  • Medium
  • Large

For lab environments, Tiny is usually sufficient. Then Click Next

 

Select Datastore

  • Choose the datastore STG-ESX01-DCM where VCSA will be deployed
  • Optionally enable Thin Disk Mode

 

Configure Network Settings

  • Network: VM Network / Port Group
  • IP Version: IPv4
  • IP Assignment: Static
  • Provide IP address : 192.168.10.93
  • Subnet mask: 255.255.255.0 0r 24 
  • Gateway:192.168.10.1
  • DNS Server IP :192.168.10.100

Click Next.

 

Finish to start Stage 1 deployment

vCenter Server Installation – Stage 2 (Configure Appliance)

Once Stage 1 continue .

 

You can see ESXI host deployment stating

Deployment in progress installation the rpm packages

Automatically Power on the vcenter server in esxi host

click Continue to begin Stage 2.

Click Next

Appliance Configuration

  • Synchronize time with ESXi host or NTP servers
  • Enable SSH if required (recommended for admin access)

 

SSO Configuration

  • Create a new SSO domain (for fresh installation)
  • Example:
    • SSO Domain: ppcmng.com
    • SSO Password: Strong and secure

Click Next


CEIP (Customer Experience Improvement Program)

  • Join or opt out as per organizational policy
  • Click Next

Click Finish and wait for the configuration to complete.

Click OK

Stage 2 in progress

Accessing vCenter Server 8

After successful installation:

  • Access vSphere Client: https://inddcpvcs01.ppc.com>/ui

Lunch vCenter Client

Login using:

  • Username: administrator@ppcmng.com
  • Password: SSO password

 

 Assigned the License vCenter server


Post-Installation Best Practices

  • Take a backup of vCenter Server Appliance
  • Configure NTP properly
  • Replace self-signed certificates if required
  • Apply latest patches and updates
  • Create datacenters, clusters, and add ESXi hosts

Conclusion

Installing vCenter Server 8 (VCSA 8.0.2) is a straightforward process when prerequisites are properly prepared. With centralized management, enhanced security, and improved performance, vCenter 8 is a powerful platform for managing modern virtualized environments.

If you’re planning a production deployment, always follow VMware best practices and validate compatibility before proceeding.

VMware CLI All In One

============================================================================================================
                                       VMware ESXi CLI Command List
============================================================================================================
Host Information & System Status
============================================================================================================
esxcli system version get                      --> Show ESXi version and build number
vmware -v                                      --> Show ESXi version (short)
esxcli system hostname get                     --> Display the hostname
esxcli system uptime get                        --> Check host uptime
esxcli hardware cpu list                        --> Show CPU info
esxcli hardware memory get                      --> Show memory info
esxcli hardware platform get                    --> Show hardware platform details
esxcli software profile get                     --> Show installed ESXi software profile
esxcli system maintenanceMode get               --> Check if host is in maintenance mode
esxcli system settings advanced list            --> List advanced system settings
============================================================================================================
Networking
============================================================================================================
esxcli network nic list                         --> List all physical NICs
esxcli network nic get -n vmnicX                --> Details about a specific NIC
esxcli network vswitch standard list            --> List vSwitches
esxcli network vswitch standard portgroup list  --> List port groups
esxcli network ip interface list                --> Show VMkernel interfaces
esxcli network ip route ipv4 list               --> Show IPv4 routes
esxcli network ip route ipv6 list               --> Show IPv6 routes
esxcli network firewall get                      --> Show firewall status
esxcli network firewall set --enabled true/false --> Enable/disable firewall
esxcli network ip dns server list               --> Show DNS servers
esxcli network ip dns search list               --> Show DNS search domains
============================================================================================================
Storage Management
============================================================================================================
esxcli storage core device list                 --> List all storage devices
esxcli storage filesystem list                  --> List datastores
esxcli storage core adapter list                --> Show storage adapters (HBA)
esxcli storage core device stats get -d <device> --> Show storage stats
esxcli storage nmp device list                  --> Show multipathing info
esxcli storage nmp path list                    --> Show all storage paths
esxcli storage nmp device set --device <device> --psp <policy> --> Set path selection policy
esxcli storage core device set --state off/on   --> Disable/Enable a storage device
esxcli storage core path list                   --> Show path status of devices
esxcli storage core claimrule list              --> Show storage claim rules
============================================================================================================
Virtual Machines (VMs)
============================================================================================================
vim-cmd vmsvc/getallvms                         --> List all VMs
vim-cmd vmsvc/power.getstate <VMID>            --> Get VM power state
vim-cmd vmsvc/power.on <VMID>                  --> Power on VM
vim-cmd vmsvc/power.off <VMID>                 --> Power off VM
vim-cmd vmsvc/power.reset <VMID>               --> Reset VM
vim-cmd vmsvc/snapshot.create <VMID> <name> <desc> --> Create snapshot
vim-cmd vmsvc/snapshot.remove <VMID> <snapshotID> --> Remove snapshot
vim-cmd vmsvc/reload <VMID>                    --> Reload VM configuration
vim-cmd vmsvc/unregister <VMID>                --> Unregister VM from host
vim-cmd vmsvc/message <VMID> "<message>"       --> Send message to VM guest OS
============================================================================================================
Services Management
============================================================================================================
esxcli system services list                     --> List all services
esxcli system services start -s <service>      --> Start a service
esxcli system services stop -s <service>       --> Stop a service
esxcli system services restart -s <service>    --> Restart a service
services.sh restart                             --> Restart all management agents (legacy)
chkconfig --list                                --> List service runlevels and status
============================================================================================================
Security & Users
============================================================================================================
esxcli system account list                      --> List ESXi users
esxcli system account add -i <user> -p <pass>  --> Add user
esxcli system account remove -i <user>         --> Remove user
esxcli system permission list                   --> Show permissions
esxcli system permission set --id <user> --role <role> --> Assign role to user
esxcli system account lock -i <user>           --> Lock user account
esxcli system account unlock -i <user>         --> Unlock user account
============================================================================================================
Logs & Monitoring
============================================================================================================
esxcli system syslog config get                 --> Show syslog configuration
esxcli system syslog reload                     --> Reload syslog
tail -f /var/log/hostd.log                      --> Monitor hostd logs in real-time
tail -f /var/log/vmkernel.log                   --> Monitor VMkernel logs
esxcli system coredump network get              --> Show coredump network settings
esxcli system coredump network set --enable true/false --> Enable/disable coredump network
esxcli hardware ipmi sdr list                   --> Show hardware sensor data (IPMI)
esxcli hardware ipmi sel list                   --> Show hardware event log
============================================================================================================
Host Maintenance & Performance
============================================================================================================
esxcli system maintenanceMode get               --> Check maintenance mode status
esxcli system maintenanceMode set --enable true/false --> Enter/Exit maintenance mode
esxcli hardware cpu global get                  --> Show CPU performance info
esxcli hardware memory get                       --> Show memory usage stats
esxtop                                          --> Real-time performance monitoring


============================================================================================================
                                       VMware ESXi System Configuration Files
============================================================================================================
Host Configuration
============================================================================================================
/etc/hosts                         --> Hostname and IP mapping file
/etc/hostname                      --> ESXi hostname configuration
/etc/resolv.conf                    --> DNS servers and search domains
/etc/syslog.conf                     --> Syslog configuration (legacy)
/etc/vmware/esx.conf                --> Main ESXi host configuration file
/etc/vmware/hostd/hostd.xml         --> Host Management daemon (hostd) configuration
/etc/vmware/hostd/authorization.xml --> Hostd permissions and roles
/etc/vmware/vpx/                   --> vCenter agent configuration files (vpxa)
============================================================================================================
Networking Configuration
============================================================================================================
/etc/vmware/esx.conf                --> Includes vSwitches and VMkernel interfaces
/etc/vmware/esx/portgroups          --> Portgroup definitions
/etc/vmware/esx/vmkernel/interfaces --> VMkernel interface configurations
/etc/vmware/esx/networks.xml        --> Network adapters and VLAN configuration
/etc/network/interfaces             --> Legacy ESXi network interface info
============================================================================================================
Storage Configuration
============================================================================================================
/etc/vmware/esx.conf                --> Includes datastore and HBA configuration
/etc/vmware/storage/core.xml         --> Storage core settings
/etc/vmware/vmfs/                   --> VMFS datastore metadata and UUIDs
/etc/vmware/scsi/                   --> SCSI adapter settings
============================================================================================================
Virtual Machines Configuration
============================================================================================================
/vmfs/volumes/<datastore>/<VM_Name>/<VM_Name>.vmx   --> VM configuration file
/vmfs/volumes/<datastore>/<VM_Name>/<VM_Name>.nvram --> VM BIOS/firmware settings
/vmfs/volumes/<datastore>/<VM_Name>/<VM_Name>.vmdk  --> VM virtual disk descriptor
/vmfs/volumes/<datastore>/<VM_Name>/<VM_Name>.vmxf  --> VM team/folder configuration
/vmfs/volumes/<datastore>/<VM_Name>/<VM_Name>.vmss  --> VM suspend state file
============================================================================================================
Services & Management Configuration
============================================================================================================
/etc/vmware/hostd/                    --> Hostd daemon configs
/etc/vmware/hostd/proxy.xml            --> Hostd proxy settings
/etc/vmware/hostd/vim.xml              --> Hostd VM inventory configuration
/etc/vmware/vpxa/vpxa.cfg              --> vCenter agent configuration file
/etc/vmware/vpxa/logging.conf          --> vCenter agent logging configuration
============================================================================================================
Security & Users
============================================================================================================
/etc/passwd                            --> Local ESXi user accounts
/etc/shadow                            --> Password hashes for ESXi users
/etc/pam.d/                             --> PAM authentication configuration
/etc/vmware/hostd/authorization.xml    --> User permissions and roles
============================================================================================================
Logs & Monitoring
============================================================================================================
/var/log/hostd.log                     --> Host management daemon logs
/var/log/vmkernel.log                  --> VMkernel logs
/var/log/vpxa.log                       --> vCenter agent logs
/var/log/vmkwarning.log                 --> Kernel warnings
/var/log/syslog.log                      --> System logs
/var/run/log                            --> Temporary runtime logs
============================================================================================================
Advanced / Backup-Ready
============================================================================================================
/etc/vmware/esx.conf                     --> Single most important config file for backup
/etc/vmware/hostd/                       --> Backup hostd configs for host management restore
/etc/vmware/vpxa/                         --> Backup vCenter agent configs for vCenter connectivity
/etc/network/                             --> Backup network settings
/etc/ssh/                                 --> Backup SSH configuration if enabled


============================================================================================================
                                       vCenter CLI Cheat Sheet
============================================================================================================
Login & Basic Info
============================================================================================================
ssh root@<vcenter_ip> ---> Login to VCSA shell
hostnamectl ---> Show vCenter hostname and system info
uptime ---> Show vCenter uptime
vpxd -v ---> Display vCenter Server version
vami-cli info ---> Show VCSA system information
appliance-version ---> Show appliance version and build
============================================================================================================
vCenter Services
============================================================================================================
service-control --list ---> List all vCenter services
service-control --start <service_name> ---> Start a vCenter service
service-control --stop <service_name> ---> Stop a vCenter service
service-control --restart <service_name> ---> Restart a vCenter service
service-control --status <service_name> ---> Show status of a service
service-control --all status ---> Show status of all services
============================================================================================================
Networking
============================================================================================================
ip addr show ---> List all network interfaces
ip route show ---> Show network routing table
appliance firewall status ---> Show firewall status
appliance firewall enable <service> ---> Enable firewall for service
appliance firewall disable <service> ---> Disable firewall for service
esxcli network ip dns server list ---> Show DNS servers
esxcli network ip dns search list ---> Show DNS search domains
============================================================================================================
Backup & Restore
============================================================================================================
vami-cli backup list ---> List existing vCenter backups
vami-cli backup create --description "<desc>" --mode file --destination <path> ---> Create backup
vami-cli restore --mode file --source <backup_file> ---> Restore from backup
vami-cli system restore point list ---> List restore points
============================================================================================================
Host / Cluster Management via govc
============================================================================================================
govc host.info ---> List all ESXi hosts in vCenter
govc host.uptime -host <hostname> ---> Show host uptime
govc host.maintenance -enter -host <hostname> ---> Put host in maintenance mode
govc host.maintenance -exit -host <hostname> ---> Exit host from maintenance mode
govc cluster.info /<datacenter>/host/<cluster_name> ---> Show cluster info
govc cluster.addhost -cluster /<datacenter>/host/<cluster_name> <host_ip> ---> Add host to cluster
govc cluster.removehost -cluster /<datacenter>/host/<cluster_name> <host_ip> ---> Remove host from cluster
govc cluster.das.info /<datacenter>/host/<cluster_name> ---> Show HA/DRS settings
============================================================================================================
VM Management via govc
============================================================================================================
govc ls /<datacenter>/vm ---> List all VMs
govc vm.info -json <vm_name> ---> Show VM info
govc vm.power -on <vm_name> ---> Power on VM
govc vm.power -off <vm_name> ---> Power off VM
govc vm.power -reset <vm_name> ---> Reset VM
govc vm.markastemplate <vm_name> ---> Mark VM as template
govc snapshot.create <vm_name> <snapshot_name> ---> Create snapshot
govc snapshot.remove <vm_name> <snapshot_name> ---> Remove snapshot
govc snapshot.revert <vm_name> <snapshot_name> ---> Revert VM to snapshot
govc vm.rename <vm_name> <new_name> ---> Rename a VM
govc vm.clone -vm <vm_name> <new_vm_name> ---> Clone a VM
============================================================================================================
VM Management via PowerCLI
============================================================================================================
Connect-VIServer -Server <vcenter_ip> -User <user> -Password <pass> ---> Connect to vCenter
Get-VM ---> List all VMs
Start-VM -VM <vm_name> ---> Power on VM
Stop-VM -VM <vm_name> ---> Power off VM
Restart-VM -VM <vm_name> ---> Reset VM
New-Snapshot -VM <vm_name> -Name <snapshot_name> ---> Create snapshot
Remove-Snapshot -VM <vm_name> -VM <vm_name> -Name <snapshot_name> ---> Remove snapshot
Set-VM -VM <vm_name> -MemoryGB <size> ---> Change VM memory
Set-VM -VM <vm_name> -NumCPU <count> ---> Change VM CPU
Rename-VM -VM <vm_name> -NewName <new_name> ---> Rename VM
Export-VM -VM <vm_name> -Destination <path> ---> Export VM to OVF/OVA
============================================================================================================
Datastore Management
============================================================================================================
govc datastore.info /<datacenter>/datastore/<datastore_name> ---> Show datastore info
govc datastore.ls -json ---> List all datastores
govc datastore.mkdir /<datacenter>/datastore/<datastore_name>/<folder> ---> Create folder in datastore
govc datastore.rm /<datacenter>/datastore/<datastore_name>/<folder> ---> Remove folder from datastore
govc datastore.upload <local_file> /<datacenter>/datastore/<datastore_name>/<file> ---> Upload file to datastore
govc datastore.download /<datacenter>/datastore/<datastore_name>/<file> <local_file> ---> Download file
============================================================================================================
Users & Permissions
============================================================================================================
govc role.ls ---> List all roles
govc permissions.ls ---> List all permissions
govc permissions.set -principal <user> -role <role> -entity /<datacenter>/vm/<vm_name> ---> Assign role to user
govc permissions.remove -principal <user> -entity /<datacenter>/vm/<vm_name> ---> Remove permission
============================================================================================================
Logs & Monitoring
============================================================================================================
journalctl -u vpxd.service ---> Show vCenter logs
tail -f /var/log/vmware/vpxd/vpxd.log ---> Monitor vCenter log in real-time
appliance-monitoring summary ---> Show VCSA appliance health
appliance-monitoring network ---> Show network monitoring info
============================================================================================================
Advanced / Maintenance
============================================================================================================
vpxd_servicecfg_init ---> Re-initialize vCenter services (advanced)
appliance-shell ---> Enter appliance shell mode
vami-cli services list ---> List VCSA appliance services
vami-cli services restart <service> ---> Restart a specific appliance service
appliance-control --shutdown ---> Shutdown VCSA
appliance-control --reboot ---> Reboot VCSA


============================================================================================================
                                       vCenter System Configuration Files
============================================================================================================
Host & Basic System Configuration
============================================================================================================
/etc/hostname ---> VCSA hostname configuration
/etc/hosts ---> Static IP and hostname mappings
/etc/resolv.conf ---> DNS servers and search domains
/etc/locale.conf ---> Locale and language settings
/etc/vmware/identity/sso.cfg ---> Single Sign-On (SSO) configuration
/etc/vmware/vmdir/config ---> VMware Directory Service (vmdir) config
/etc/vmware/applmgmt/appliance.cfg ---> Appliance management settings
/etc/vmware/applmgmt/applmgmt.cfg ---> Appliance management network config
============================================================================================================
Networking Configuration
============================================================================================================
/etc/network/interfaces ---> Network interfaces and IP configuration
/etc/sysconfig/network-scripts/ifcfg-<interface> ---> Legacy interface config (RHEL-based)
/etc/vmware/network/config ---> VCSA appliance network config
/etc/vmware/network/firewall.xml ---> Firewall rules configuration
/etc/vmware/vami/firewall.conf ---> VAMI firewall settings
============================================================================================================
vCenter Services Configuration
============================================================================================================
/etc/vmware/vpxd/vpxd.cfg ---> Main vCenter Server (vpxd) configuration
/etc/vmware/vpxd/license.cfg ---> vCenter license info
/etc/vmware/vpxd/vpxd-profiler.xml ---> Service profiling configuration
/etc/vmware/vpxd/logging.properties ---> Logging configuration for vCenter services
/etc/vmware/applmgmt/appliance-services.conf ---> Appliance service management configuration
============================================================================================================
Database Configuration
============================================================================================================
/etc/vmware/vpostgres/pg_hba.conf ---> PostgreSQL access control configuration
/etc/vmware/vpostgres/postgresql.conf ---> PostgreSQL database settings
/etc/vmware/vpostgres/data/ ---> PostgreSQL database files for vCenter
/etc/vmware/vpostgres/data/pg_ident.conf ---> User mapping for database authentication
============================================================================================================
Users & Permissions
============================================================================================================
/etc/passwd ---> Local users on VCSA appliance
/etc/shadow ---> Password hashes for VCSA users
/etc/sudoers ---> Sudo privileges for VCSA users
/etc/vmware/identity/roles.xml ---> SSO user roles and permissions
/etc/vmware/identity/users.xml ---> SSO user configuration
============================================================================================================
Logging Configuration & Logs
============================================================================================================
/var/log/vmware/vpxd/vpxd.log ---> Main vCenter Server log
/var/log/vmware/vpxd/vpxd-profiler.log ---> vCenter profiling log
/var/log/vmware/applmgmt/applmgmt.log ---> Appliance management log
/var/log/messages ---> System-level logs
/var/log/vmware/vpostgres/postgresql.log ---> vCenter PostgreSQL logs
/var/log/vmware/sso/ ---> SSO service logs
7. Backup & Restore Configuration
/etc/vmware/vami/backup.conf ---> VCSA backup configuration
/etc/vmware/vami/restore.conf ---> VCSA restore configuration
/var/lib/vami/backup/ ---> VCSA backup storage location
============================================================================================================
Advanced / Miscellaneous
============================================================================================================
/etc/vmware/applmgmt/ssl/certs/ ---> SSL certificate files for appliance
/etc/vmware/ssl/ ---> vCenter SSL certificate store
/etc/vmware/applmgmt/ceip.conf ---> VMware Customer Experience Improvement Program (CEIP) settings
/etc/vmware/applmgmt/health.xml ---> Appliance health monitoring configuration
/etc/vmware/applmgmt/network.xml ---> Appliance network monitoring configuration

Oracle 19c Pacemaker Cluster

RHEL/CentOS 8 | iSCSI Shared Storage | Automated Oracle Failover

Building bulletproof Oracle HA doesn't need expensive hardware. Pacemaker + Corosync on Linux gives you production-grade failover for ~$0. This guide walks through a 2-node cluster with iSCSI, LVM, VIP, and full Oracle stack.

Your cluster:
indrxlora01  192.168.10.91  ← Node 1
indrxlora02  192.168.10.92  ← Node 2  
oradb-vip    192.168.10.93  ← Oracle VIP (floats between nodes)
storage      192.168.10.20  ← iSCSI server

1. iSCSI Shared Storage
On Storage Server (192.168.10.20)
sudo dnf install -y targetcli lvm2
sudo vgcreate datavg /dev/sdb
sudo lvcreate -L 50G -n oradisk01 datavg
sudo lvcreate -L 50G -n oradisk02 datavg

# Expose via iSCSI
sudo targetcli
/backstores/block create ora_LUN01 /dev/datavg/oradisk01
/backstores/block create ora_LUN02 /dev/datavg/oradisk02
/iscsi create iqn.2026-02.ppc.com:oraservers
/iscsi/iqn.2026-02.ppc.com:oraservers/tpg1/luns create /backstores/block/ora_LUN01
/iscsi/iqn.2026-02.ppc.com:oraservers/tpg1/luns create /backstores/block/ora_LUN02
/iscsi/iqn.2026-02.ppc.com:oraservers/tpg1/acls create iqn.2026-02.ppc.com:indrxlora01
/iscsi/iqn.2026-02.ppc.com:oraservers/tpg1/acls create iqn.2026-02.ppc.com:indrxlora02
saveconfig

On Both Cluster Nodes
sudo dnf install -y iscsi-initiator-utils
echo "InitiatorName=iqn.2026-02.ppc.com:indrxlora01" | sudo tee /etc/iscsi/initiatorname.iscsi
sudo systemctl enable --now iscsid
sudo iscsiadm --mode discoverydb --type sendtargets --portal 192.168.10.20 --discover
sudo iscsiadm -m node --login
lsblk  # See /dev/sdb appear!

Pro tip: Node1 uses indrxlora01 IQN, Node2 uses indrxlora02.

2. Pacemaker Cluster Setup
On BOTH nodes:
sudo dnf install -y pcs pacemaker corosync
sudo systemctl enable --now pcsd
echo "secure_password" | sudo passwd --stdin hacluster

On Node1 only:
# Authenticate nodes
sudo pcs cluster auth indrxlora01 indrxlora02 -u hacluster -p secure_password

# Create cluster
sudo pcs cluster setup --start --name oracleha indrxlora01 indrxlora02

# Enable & start
sudo pcs cluster enable --all
sudo pcs property set stonith-enabled=false  # LAB ONLY
sudo pcs status

You should see: Cluster name: oracleha, 2 nodes online.

3. LVM for HA Storage
On BOTH nodes - Edit /etc/lvm/lvm.conf:
sudo sed -i "s/# activation {/activation {/" /etc/lvm/lvm.conf
sudo sed -i "s/# *auto_activation_volume_list/auto_activation_volume_list/" /etc/lvm/lvm.conf
echo 'auto_activation_volume_list = [ "@pacemaker" ]' | sudo tee -a /etc/lvm/lvm.conf
echo 'use_lvmetad = 1' | sudo tee -a /etc/lvm/lvm.conf  
echo 'use_lvmlockd = 1' | sudo tee -a /etc/lvm/lvm.conf

# Filter ONLY shared storage
sudo sed -i 's/# *filter =.*$/filter = [ "a|\\/dev\\/sdb|", "r|.*|" ]/' /etc/lvm/lvm.conf

Create HA VG/LV (Node1):
sudo vgcreate vg01 /dev/sdb --addtag pacemaker
sudo lvcreate -L 15G -n lvol01 vg01 --addtag pacemaker
sudo mkfs.xfs /dev/vg01/lvol01
sudo mkdir /u01
sudo vgchange -an vg01  # Pacemaker activates this

Create LVM resource:
sudo pcs resource create vg01 LVM volgrpname=vg01 exclusive=true \
  op monitor interval=30s timeout=60s

4. VIP + Filesystem
# Virtual IP (Oracle client connects here)
sudo pcs resource create oradb-vip IPaddr2 ip=192.168.10.93 cidr_netmask=24 nic=eth0 \
  op monitor interval=10s

# Oracle filesystem  
sudo pcs resource create u01-filesys Filesystem device="/dev/vg01/lvol01" directory="/u01" \
  fstype="xfs" op monitor interval=20s

# Group them (failover together)
sudo pcs resource group add oracleha oradb-vip vg01 u01-filesys

5. Oracle Resources (Listener + Database)
Database prep (both nodes, as oracle user):
sqlplus / as sysdba
CREATE USER cocfmon IDENTIFIED BY "secure_password";
GRANT CONNECT, RESOURCE TO cocfmon;
GRANT SELECT ANY TRANSACTION TO cocfmon;
ALTER PLUGGABLE DATABASE ALL OPEN;
ALTER PLUGGABLE DATABASE ALL SAVE STATE;

Pacemaker Oracle resources:
# Listener
sudo pcs resource create listener_orcl oralsnr sid="orcl" listener="LISTENER_ORCL" \
  --group oracleha

# Database (600s timeout = handles PDB startup)
sudo pcs resource create orcl oracle autostart=true sid="orcl" \
  monuser="cocfmon" monpassword="secure_password" \
  start_timeout=600 stop_timeout=300 \
  op monitor interval=30s timeout=90s \
  --group oracleha

6. Startup Order
# Colocation
sudo pcs constraint colocation add oracleha members=INFINITY

# Order (VIP first → storage → filesystem → listener → DB)
sudo pcs constraint order oradb-vip then vg01
sudo pcs constraint order vg01 then u01-filesys  
sudo pcs constraint order u01-filesys then listener_orcl
sudo pcs constraint order listener_orcl then orcl

Flow: VIP → LVM → FS → Listener → Database

7. Test Failover
# Move to Node2
sudo pcs resource move oracleha indrxlora02

# Simulate Node1 failure
sudo pcs cluster standby indrxlora01

# Bring Node1 back
sudo pcs node unstandby indrxlora01

# Cleanup stuck resources
sudo pcs resource cleanup oracleha

Watch it work:
sudo pcs status
tail -f /var/log/pacemaker/pacemaker.log

VIP 192.168.10.93 should ping continuously during failover.

8. Quick Health Dashboard
# One-liner status
sudo pcs status | grep -E "(oradb|orcl|FAILED)"

# Test Oracle monitoring
su - oracle -c "sqlplus cocfmon/secure_password@192.168.10.93/orcl as sysdba 'select 1 from dual;'"

9. Troubleshooting
ProblemFix
VG won't activatevgchange --addtag pacemaker vg01
iSCSI failsiscsiadm -m session -P 3 + check targetcli ACLs
DB monitor failsVerify cocfmon user + password
2-node quorumsudo pcs property set no-quorum-policy=ignore
Resources stucksudo pcs resource cleanup oracleha

10. Production Checklist
  • STONITH enabled (fencing)
  • Multipath iSCSI (not single path)
  • qdevice for quorum
  • Passwordless SSH between nodes
  • Firewall: 3121/tcp, 5404-5412/udp, 3260/tcp
  • /u01 in /etc/fstab excluded
  • Weekly failover test scheduled
Final Validation
# Client connectivity test
sqlplus scott/tiger@192.168.10.93/orcl  # Should always work

# Failover time
time sudo pcs cluster standby indrxlora01 && sleep 60 && sudo pcs node unstandby indrxlora01