[MediaWiki-commits] [Gerrit] helium backup director/storage server - change (operations/puppet)

2013-08-16 Thread Akosiaris (Code Review)
Akosiaris has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/79334


Change subject: helium backup director/storage server
..

helium backup director/storage server

Change-Id: I6db35aa15cb800b4dc917a60099baacff486e7a3
---
M manifests/role/backup.pp
M manifests/site.pp
2 files changed, 40 insertions(+), 4 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/34/79334/1

diff --git a/manifests/role/backup.pp b/manifests/role/backup.pp
index b881de4..4b1f39b 100644
--- a/manifests/role/backup.pp
+++ b/manifests/role/backup.pp
@@ -1,7 +1,7 @@
 # A set of roles for the backup director, storage and client as they are
 # configured in WMF
 
-$director = FILLMEIN
+$director = helium.eqiad.wmnet
 
 class role::backup::director {
 system_role { role::backup::director: description = Primary Backup 
server }
@@ -92,16 +92,50 @@
 class role::backup::storage() {
 system_role { role::backup::storage: description = Storage backup 
server }
 
+include nfs::netapp::common
+
 class { 'bacula::storage':
 director= $director,
 sd_max_concur_jobs  = 5,
 sqlvariant  = 'mysql',
 }
 
-bacula::storage::device { 'FileStorage':
+file { [ '/srv/bacula-sd1',
+ '/srv/bacula-sd2' ]:
+ensure  = directory,
+owner   = bacula,
+group   = bacula,
+mode= '0660',
+require = Class['bacula::storage'],
+}
+
+mount { /srv/bacula-sd1 :
+ensure  = mounted,
+device  = ${nfs::netapp::common::device}:/vol/bacula-sd1,
+fstype  = nfs,
+options = ${nfs::netapp::common::options},rw,
+require = File['/srv/bacula-sd1'],
+}
+
+mount { /srv/bacula-sd2 :
+ensure  = mounted,
+device  = ${nfs::netapp::common::device}:/vol/bacula-sd2,
+fstype  = nfs,
+options = ${nfs::netapp::common::options},rw,
+require = File['/srv/bacula-sd2'],
+}
+
+bacula::storage::device { 'FileStorage2':
 device_type = 'File',
 media_type  = 'File',
-archive_device  = '/srv/backups',
+archive_device  = '/srv/bacula-sd2',
+max_concur_jobs = 2,
+}
+
+bacula::storage::device { 'FileStorage1':
+device_type = 'File',
+media_type  = 'File',
+archive_device  = '/srv/bacula-sd1',
 max_concur_jobs = 2,
 }
 }
diff --git a/manifests/site.pp b/manifests/site.pp
index a0487ff..d01311a 100644
--- a/manifests/site.pp
+++ b/manifests/site.pp
@@ -1037,7 +1037,9 @@
 
 node helium.eqiad.wmnet {
 include standard,
-role::poolcounter
+role::poolcounter,
+   role::backup::director,
+   role::backup::storage
 }
 
 node holmium.wikimedia.org {

-- 
To view, visit https://gerrit.wikimedia.org/r/79334
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I6db35aa15cb800b4dc917a60099baacff486e7a3
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Akosiaris akosia...@wikimedia.org

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] helium backup director/storage server - change (operations/puppet)

2013-08-16 Thread Akosiaris (Code Review)
Akosiaris has submitted this change and it was merged.

Change subject: helium backup director/storage server
..


helium backup director/storage server

Change-Id: I6db35aa15cb800b4dc917a60099baacff486e7a3
---
M manifests/role/backup.pp
M manifests/site.pp
2 files changed, 61 insertions(+), 12 deletions(-)

Approvals:
  Akosiaris: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/manifests/role/backup.pp b/manifests/role/backup.pp
index b881de4..f032d8e 100644
--- a/manifests/role/backup.pp
+++ b/manifests/role/backup.pp
@@ -1,10 +1,13 @@
 # A set of roles for the backup director, storage and client as they are
 # configured in WMF
 
-$director = FILLMEIN
+class role::backup::config {
+$director = 'helium.eqiad.wmnet'
+$database = 'db1001.eqiad.wmnet'
+}
 
 class role::backup::director {
-system_role { role::backup::director: description = Primary Backup 
server }
+system_role { 'role::backup::director': description = 'Backup server' }
 
 class { 'bacula::director':
 sqlvariant  = 'mysql',
@@ -12,9 +15,9 @@
 }
 
 # One pool for all
-bacula::director::pool { 'WMF':
+bacula::director::pool { 'production':
 max_vols = 30,
-storage  = 'WMFFiles',
+storage  = 'FileStorage1',
 volume_retention = '180 days',
 }
 
@@ -24,7 +27,15 @@
 $days = ['Sat', 'Sun', 'Mon', 'Tue', 'Wed', 'Thu', 'Fri']
 
 backup::schedule { $days:
-pool= 'WMF',
+pool= 'production',
+}
+
+bacula::director::catalog { 'production':
+dbname  = 'bacula',
+dbuser  = 'bacula',
+dbhost  = $bacula::config::database,
+dbport  = '3306',
+dbpassword  = $passwords::bacula::database
 }
 
 # This has been taken straight from old files/backup/disklist-*
@@ -83,25 +94,61 @@
 includes = [ '/var/vmail' ]
 }
 
-# The console should be on the director 
+# The console should be on the director
 bacula::console { 'bconsole':
 director   = $::fqdn,
 }
 }
 
 class role::backup::storage() {
-system_role { role::backup::storage: description = Storage backup 
server }
+system_role { 'role::backup::storage': description = 'Backup Storage' }
+
+include nfs::netapp::common
 
 class { 'bacula::storage':
-director= $director,
+director= $role::backup::config::director,
 sd_max_concur_jobs  = 5,
 sqlvariant  = 'mysql',
 }
-
-bacula::storage::device { 'FileStorage':
+
+# We have two storage devices to overcome any limitations from backend
+# infrastructure (e.g. Netapp used to have only  16T volumes)
+file { ['/srv/bacula-sd1',
+'/srv/bacula-sd2' ]:
+ensure  = directory,
+owner   = 'bacula',
+group   = 'bacula',
+mode= '0660',
+require = Class['bacula::storage'],
+}
+
+mount { '/srv/bacula-sd1' :
+ensure  = mounted,
+device  = ${nfs::netapp::common::device}:/vol/bacula-sd1,
+fstype  = 'nfs',
+options = ${nfs::netapp::common::options},rw,
+require = File['/srv/bacula-sd1'],
+}
+
+mount { '/srv/bacula-sd2' :
+ensure  = mounted,
+device  = ${nfs::netapp::common::device}:/vol/bacula-sd2,
+fstype  = 'nfs',
+options = ${nfs::netapp::common::options},rw,
+require = File['/srv/bacula-sd2'],
+}
+
+bacula::storage::device { 'FileStorage1':
 device_type = 'File',
 media_type  = 'File',
-archive_device  = '/srv/backups',
+archive_device  = '/srv/bacula-sd1',
+max_concur_jobs = 2,
+}
+
+bacula::storage::device { 'FileStorage2':
+device_type = 'File',
+media_type  = 'File',
+archive_device  = '/srv/bacula-sd2',
 max_concur_jobs = 2,
 }
 }
diff --git a/manifests/site.pp b/manifests/site.pp
index a0487ff..aa82d79 100644
--- a/manifests/site.pp
+++ b/manifests/site.pp
@@ -1037,7 +1037,9 @@
 
 node helium.eqiad.wmnet {
 include standard,
-role::poolcounter
+role::poolcounter,
+role::backup::director,
+role::backup::storage
 }
 
 node holmium.wikimedia.org {

-- 
To view, visit https://gerrit.wikimedia.org/r/79334
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I6db35aa15cb800b4dc917a60099baacff486e7a3
Gerrit-PatchSet: 3
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Akosiaris akosia...@wikimedia.org
Gerrit-Reviewer: Akosiaris akosia...@wikimedia.org
Gerrit-Reviewer: jenkins-bot

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits