Advertisement
Guest User

Untitled

a guest
Aug 13th, 2017
406
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.78 KB | None | 0 0
  1. # Installing Percona XtraDB Cluster
  2.  
  3. This is a guide about installing Percona XtraDB Cluster on 3 Debian jessie servers.
  4.  
  5. ## Preparations
  6.  
  7. We need 3 Debian jessie machines, preferably on the same network:
  8.  
  9. * db01.example.com
  10. * db02.example.com
  11. * db03.example.com
  12.  
  13. ### Prepare /etc/hosts
  14.  
  15. On db01:
  16.  
  17. ```
  18. 127.0.1.1 db01.example.com db01
  19. 127.0.0.1 localhost
  20. 10.10.10.2 db02.example.com db02
  21. 10.10.10.3 db03.example.com db03
  22. ```
  23.  
  24. On db02:
  25.  
  26. ```
  27. 127.0.1.1 db02.example.com db02
  28. 127.0.0.1 localhost
  29. 10.10.10.1 db01.example.com db01
  30. 10.10.10.3 db03.example.com db03
  31. ```
  32.  
  33. On db03:
  34.  
  35. ```
  36. 127.0.1.1 db03.example.com db03
  37. 127.0.0.1 localhost
  38. 10.10.10.1 db01.example.com db01
  39. 10.10.10.2 db02.example.com db02
  40. ```
  41.  
  42. ### Setup the FW
  43.  
  44. On db01:
  45.  
  46. ```
  47. ufw allow from 10.10.10.2
  48. ufw allow from 10.10.10.3
  49. ```
  50.  
  51. On db02:
  52.  
  53. ```
  54. ufw allow from 10.10.10.1
  55. ufw allow from 10.10.10.3
  56. ```
  57.  
  58. On db03:
  59.  
  60. ```
  61. ufw allow from 10.10.10.1
  62. ufw allow from 10.10.10.2
  63. ```
  64.  
  65. ## Install Percona XtraDB Cluster
  66.  
  67.  
  68. ### Setup debian repositories
  69.  
  70. Run these commands on all nodes.
  71.  
  72. * Download the percona relese .deb:
  73.  
  74. ```
  75. wget https://repo.percona.com/apt/percona-release_0.1-4.$(lsb_release -sc)_all.deb
  76. ```
  77.  
  78. * Install the package:
  79.  
  80. ```
  81. dpkg -i percona-release_0.1-4.$(lsb_release -sc)_all.deb
  82.  
  83. * Update APT:
  84.  
  85. ```
  86. apt update
  87. ```
  88.  
  89. ### Install the package
  90.  
  91. ```
  92. apt -y install percona-xtradb-cluster-57
  93. ```
  94.  
  95. Enter and verify the *root* user password when prompted.
  96.  
  97. **Error: We get this in the logs:**
  98.  
  99. > 2017-08-13T07:54:38.438122Z 12 [Note] Access denied for user 'root'@'localhost' (using password: NO)
  100.  
  101. References
  102. ----------
  103. * https://www.percona.com/doc/percona-repo-config/apt-repo.html
  104. * https://www.percona.com/doc/percona-xtradb-cluster/LATEST/install/apt.html
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement