-
Notifications
You must be signed in to change notification settings - Fork 252
/
clean.sh
executable file
·17 lines (17 loc) · 1.09 KB
/
clean.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
#!/usr/bin/env bash
ansible orarac02 -a "/u01/app/12.1.0.2/grid/crs/install/rootcrs.pl -deconfig -force" -u root
ansible orarac01 -a "/u01/app/12.1.0.2/grid/crs/install/rootcrs.pl -deconfig -force -lastnode" -u root
ansible orarac02 -a "/u01/app/12.1.0.1/grid/crs/install/rootcrs.pl -deconfig -force" -u root
ansible orarac01 -a "/u01/app/12.1.0.1/grid/crs/install/rootcrs.pl -deconfig -force -lastnode" -u root
ansible orarac01 -a "dd if=/dev/zero of=/dev/sdc bs=1M count=100" -u root
ansible orarac01 -a "dd if=/dev/zero of=/dev/sdd bs=1M count=100" -u root
ansible orarac01 -a "dd if=/dev/zero of=/dev/sde bs=1M count=100" -u root
#ansible orarac01 -a "dd if=/dev/zero of=/dev/sdf bs=1M count=100" -u root
#ansible orarac01 -a "dd if=/dev/zero of=/dev/sdg bs=1M count=100" -u root
#ansible orarac01 -a "dd if=/dev/zero of=/dev/sdh bs=1M count=100" -u root
ansible orarac -a "rm -rf /u01/app" -u root
ansible orarac -a "rm -rf /etc/oratab" -u root
ansible orarac -a "rm -rf /etc/oraInst.loc" -u root
ansible orarac -a "chown oracle:dba /u01" -u root
echo "Rebooting servers"
ansible orarac -a "reboot" -u root