summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMartin Schwenke <martin@meltin.net>2014-06-24 12:10:18 +1000
committerMartin Schwenke <martin@meltin.net>2014-07-02 14:17:17 +1000
commita6d6b351b98eee1b42a78d6bad911b9c15221308 (patch)
treec5a36f40a7eb8a85880ad67f4be9b10fe752a563
parent29a18b9d0a1628ab75ba9a28ed49f3a7be8a691f (diff)
downloadautocluster-a6d6b351b98eee1b42a78d6bad911b9c15221308.tar.gz
autocluster-a6d6b351b98eee1b42a78d6bad911b9c15221308.tar.xz
autocluster-a6d6b351b98eee1b42a78d6bad911b9c15221308.zip
New configuration variables CLUSTERFS_TYPE, CLUSTERFS_DEFAULT_MOUNTPOINT
* CLUSTERFS_DEFAULT_MOUNTPOINT replaces GPFS_DEFAULT_MOUNTPOINT * Tweak various scripts and configuration files to allow cluster filesystem type to be configured * Also tweak chroot-related options to not have GPFS-specific values Signed-off-by: Martin Schwenke <martin@meltin.net>
-rw-r--r--base/all/root/scripts/cluster_configure/example.conf10
-rw-r--r--base/all/root/scripts/cluster_configure/templates/rhel/00.ctdb/1.2.4#/files/etc/sysconfig/ctdb2
-rw-r--r--base/all/root/scripts/cluster_configure/templates/rhel/50.samba/3.4#/files/etc/samba/smb.conf2
-rw-r--r--base/all/root/scripts/gpfs-nas.conf12
-rwxr-xr-xbase/all/root/scripts/setup_gpfs.sh2
-rw-r--r--config.d/00base.defconf6
-rw-r--r--config.d/40gpfs.defconf2
7 files changed, 20 insertions, 16 deletions
diff --git a/base/all/root/scripts/cluster_configure/example.conf b/base/all/root/scripts/cluster_configure/example.conf
index 782ff36..3bb461e 100644
--- a/base/all/root/scripts/cluster_configure/example.conf
+++ b/base/all/root/scripts/cluster_configure/example.conf
@@ -1,17 +1,17 @@
[DEFAULT]
cluster = foobar
domain = foobar.local
-chroot_parent = /var/lib/gpfs-nas-chroot
+chroot_parent = /var/lib/nas-chroot
scp_chroot = %(chroot_parent)s/scp
-gpfs_default_mountpoint = /gpfs-nas/gpfs0
+clusterfs_default_mountpoint = /clusterfs
[filesystem:0]
type = gpfs
-mountpoint = %(gpfs_default_mountpoint)s
+mountpoint = %(clusterfs_default_mountpoint)s
[share:data]
-directory = %(gpfs_default_mountpoint)s/data
-filesystem = %(gpfs_default_mountpoint)s
+directory = %(clusterfs_default_mountpoint)s/data
+filesystem = %(clusterfs_default_mountpoint)s
permissions = 0777
comment = An example share
diff --git a/base/all/root/scripts/cluster_configure/templates/rhel/00.ctdb/1.2.4#/files/etc/sysconfig/ctdb b/base/all/root/scripts/cluster_configure/templates/rhel/00.ctdb/1.2.4#/files/etc/sysconfig/ctdb
index 4a20819..6287f4d 100644
--- a/base/all/root/scripts/cluster_configure/templates/rhel/00.ctdb/1.2.4#/files/etc/sysconfig/ctdb
+++ b/base/all/root/scripts/cluster_configure/templates/rhel/00.ctdb/1.2.4#/files/etc/sysconfig/ctdb
@@ -1,6 +1,6 @@
# Core
CTDB_PUBLIC_ADDRESSES=/etc/ctdb/public_addresses
-CTDB_RECOVERY_LOCK=@@GPFS_DEFAULT_MOUNTPOINT@@/.ctdb/recovery.lock
+CTDB_RECOVERY_LOCK=@@CLUSTERFS_DEFAULT_MOUNTPOINT@@/.ctdb/recovery.lock
# Services managed
CTDB_MANAGES_SAMBA=yes
diff --git a/base/all/root/scripts/cluster_configure/templates/rhel/50.samba/3.4#/files/etc/samba/smb.conf b/base/all/root/scripts/cluster_configure/templates/rhel/50.samba/3.4#/files/etc/samba/smb.conf
index dc57bfc..86fc21d 100644
--- a/base/all/root/scripts/cluster_configure/templates/rhel/50.samba/3.4#/files/etc/samba/smb.conf
+++ b/base/all/root/scripts/cluster_configure/templates/rhel/50.samba/3.4#/files/etc/samba/smb.conf
@@ -2,7 +2,7 @@
# enable clustering
clustering=yes
ctdb:registry.tdb=yes
- private dir=!!gpfs_default_mountpoint!!/.ctdb/
+ private dir=!!clusterfs_default_mountpoint!!/.ctdb/
ctdbd socket = !!|ctdb_socket()!!
security = !!|"ADS" if self.config.get("package:samba", "auth_method") == "winbind" else "USER"!!
diff --git a/base/all/root/scripts/gpfs-nas.conf b/base/all/root/scripts/gpfs-nas.conf
index 987aeaf..812e74c 100644
--- a/base/all/root/scripts/gpfs-nas.conf
+++ b/base/all/root/scripts/gpfs-nas.conf
@@ -3,18 +3,18 @@ cluster = @@CLUSTER@@
domain = @@DOMAIN@@
workgroup = @@WORKGROUP@@
kdc = @@KDC_NAME@@
-chroot_parent = /var/lib/gpfs-nas-chroot
+chroot_parent = /var/lib/nas-chroot
scp_chroot = %(chroot_parent)s/scp
-gpfs_default_mountpoint = @@GPFS_DEFAULT_MOUNTPOINT@@
+clusterfs_default_mountpoint = @@CLUSTERFS_DEFAULT_MOUNTPOINT@@
auth_method = @@AUTH_METHOD@@
[filesystem:0]
-type = gpfs
-mountpoint = %(gpfs_default_mountpoint)s
+type = @@CLUSTERFS_TYPE@@
+mountpoint = %(clusterfs_default_mountpoint)s
[share:data]
-directory = %(gpfs_default_mountpoint)s/data
-filesystem = %(gpfs_default_mountpoint)s
+directory = %(clusterfs_default_mountpoint)s/data
+filesystem = %(clusterfs_default_mountpoint)s
permissions = 0777
comment = An example share
diff --git a/base/all/root/scripts/setup_gpfs.sh b/base/all/root/scripts/setup_gpfs.sh
index 920fe38..ff79d12 100755
--- a/base/all/root/scripts/setup_gpfs.sh
+++ b/base/all/root/scripts/setup_gpfs.sh
@@ -39,7 +39,7 @@ EOF
gpfs_num_nsds="@@GPFS_DEFAULT_NSDS@@"
cluster_name="@@CLUSTER@@"
-mountpoint="@@GPFS_DEFAULT_MOUNTPOINT@@"
+mountpoint="@@CLUSTERFS_DEFAULT_MOUNTPOINT@@"
opts="gpfs-num-nsds:,cluster-name:,mountpoint:"
getopt_output=$(getopt -n autocluster -o h -l "$opts" -- "$@")
diff --git a/config.d/00base.defconf b/config.d/00base.defconf
index a2b6b55..19d5db0 100644
--- a/config.d/00base.defconf
+++ b/config.d/00base.defconf
@@ -7,6 +7,12 @@
defconf CLUSTER_TYPE "samba" \
"samba|ad|build" "Type of cluster, for configuration stage"
+defconf CLUSTERFS_TYPE "gpfs" \
+ "<gpfs|?>" "type of cluster filesystem to use"
+
+defconf CLUSTERFS_DEFAULT_MOUNTPOINT "/clusterfs" \
+ "<directory>" "mountpoint for default cluster filesystem"
+
defconf NODES "sofs_front:0-3 rhel_base:4" \
"<nodes>" "list of node types to create, with associated IP offsets"
diff --git a/config.d/40gpfs.defconf b/config.d/40gpfs.defconf
index e817c28..5153df3 100644
--- a/config.d/40gpfs.defconf
+++ b/config.d/40gpfs.defconf
@@ -6,5 +6,3 @@ defconf GPFS_BASE_VERSION "3.2.0-0" \
defconf GPFS_DEFAULT_NSDS "" \
"<n>" "number of NSDs used by default GPFS filesystem, empty => all"
-defconf GPFS_DEFAULT_MOUNTPOINT "/gpfs" \
- "<directory>" "mountpoint for default GPFS filesystem"