daily pastebin goal
83%
SHARE
TWEET

IM2.0 Install - InstallDR2

sweenig Apr 25th, 2014 77 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. echo "Launching adminTools to create the database..."
  2. /opt/vertica/bin/adminTools
  3. echo "Setup the cron jobs..."
  4. echo '20 2 * * * /opt/vertica/bin/vsql -U dradmin -w qosisking -c "select analyze_histogram('',5)" > /tmp/drDailyAnalyzeStatistics.out
  5. 30 * * * * /opt/CA/IMDataRepository/bin/drAnalyzeTimestamps.sh -U dradmin -P qosisking > /tmp/drAnalyzeTimestamps.out
  6. 20 3 * * * /opt/vertica/bin/vsql -U dradmin -w qosisking -c "select audit('',10,90)" > /tmp/drAudit.out' > /home/dradmin/cron.DR #setup the cron jobs
  7. crontab /home/dradmin/cron.DR
  8. echo "Modifying the logrotate config file..."
  9. cp /opt/vertica/config/logrotate/da_dr /opt/vertica/config/logrotate/da_dr.old
  10. cat /opt/vertica/config/logrotate/da_dr | sed -e 's/weekly/daily/' > /opt/vertica/config/logrotate/da_dr1
  11. rm /opt/vertica/config/logrotate/da_dr
  12. cat /opt/vertica/config/logrotate/da_dr1 | sed -e 's/rotate 52/rotate 3/' > /opt/vertica/config/logrotate/da_dr2
  13. rm /opt/vertica/config/logrotate/da_dr1
  14. cat /opt/vertica/config/logrotate/da_dr2 | sed -e 's/# and keep for 52 weeks/# and keep for 3 weeks/' > /opt/vertica/config/logrotate/da_dr3
  15. rm /opt/vertica/config/logrotate/da_dr2
  16. cat /opt/vertica/config/logrotate/da_dr3 | sed -e 's/size 10M/#size 10M/' > /opt/vertica/config/logrotate/da_dr4
  17. rm /opt/vertica/config/logrotate/da_dr3
  18. mv /opt/vertica/config/logrotate/da_dr4 /opt/vertica/config/logrotate/da_dr
  19. echo "Launching adminTools to restart the database..."
  20. /opt/vertica/bin/adminTools
  21. cp /opt/vertica/config/users/dradmin/installed.dat /opt/vertica/config/users/dradmin/dbinfo.dat
  22. echo "Setting keys and SSH..."
  23. ssh-keygen -N "" -t rsa -f ~/.ssh/id_rsa
  24. cp ~/.ssh/id_rsa.pub ~/.ssh/authorized_keys2
  25. chmod 644 ~/.ssh/authorized_keys2
  26. ssh localhost ls
  27. echo "Launching adminTools to set recovery to always..."
  28. /opt/vertica/bin/adminTools
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top