JavaScript is required to for searching.
Skip Navigation Links
Exit Print View
Oracle Solaris Cluster Data Service for Samba Guide
search filter icon
search icon

Document Information

Preface

1.  Installing and Configuring HA for Samba

HA for Samba Overview

Overview of Installing and Configuring HA for Samba

Planning the HA for Samba Installation and Configuration

Configuration Restrictions

Restriction for the supported configurations of Samba

Restriction for the Location of Samba files

Restriction for the Samba smb.conf files

Restriction for multiple Samba instances that require winbind

Configuration Requirements

Determine which Solaris Zone Samba will run use

Dependencies Between HA for Samba Components

Required parameters for the Samba smb.conf file

Installing and Configuring Samba

How to Install and Configure Samba

How to Check Samba is installed with Solaris 9 or 10

How to Install and Configure Samba downloaded from http://www.samba.org

How to Prepare Samba for HA for Samba

Verifying the Installation and Configuration of Samba

How to Verify the Installation and Configuration of Samba

Installing the HA for Samba Packages

How to Install the HA for Samba Packages

Registering and Configuring HA for Samba

How to Register and Configure HA for Samba

How to Register and Configure HA for Samba in a failover resource group

How to Register and Configure HA for Samba in a failover resource group with winbind in a scalable resource group

How to Register and Configure HA for Samba in an HA Container

Verifying the HA for Samba Installation and Configuration

How to Verify the HA for Samba Installation and Configuration

Upgrading HA for Samba

How to Migrate Existing Resources to a New Version of HA for Samba

Understanding the HA for Samba Fault Monitor

Resource Properties

Probing Algorithm and Functionality

Operations of the winbind probe

Operations of the Samba probe

Debug HA for Samba

How to turn on debug for HA for Samba

A.  Deployment Example: Installing Samba packaged with Solaris 10

B.  Deployment Example: Installing Samba from http://www.samba.org

C.  Deployment Example: Installing Samba in an HA Container

Index

Registering and Configuring HA for Samba

This section contains the procedures you need to configure HA for Samba.

Some procedures within this section require you to use certain Oracle Solaris Cluster commands. Refer to the relevant Oracle Solaris Cluster command man page for more information about these command and their parameters.

How to Register and Configure HA for Samba

Determine if a single or multiple Samba instances will be deployed.

Refer to Restriction for multiple Samba instances that require winbind to determine how to deploy a single or multiple Samba instances with or without winbind.

Once you have determined how Samba will be deployed, you can chose one or more of the steps below.

  1. Create a failover resource group for Samba.

    Use How to Register and Configure HA for Samba in a failover resource group for Example 1-3 and Example 1-4.

  2. Create a scalable resource group for winbind.

    Use How to Register and Configure HA for Samba in a failover resource group with winbind in a scalable resource group for Example 1-5.

  3. Create a failover resource group for an HA container for Samba.

    Use How to Register and Configure HA for Samba in an HA Container for Example 1-6.

How to Register and Configure HA for Samba in a failover resource group

This procedure assumes that you installed the data service packages during your initial Oracle Solaris Cluster installation.

If you did not install the HA for Samba packages as part of your initial Oracle Solaris Cluster installation, go to How to Install the HA for Samba Packages.


Note - Perform this procedure on one node of the cluster only.


  1. On a cluster member, become superuser or assume a role that provides solaris.cluster.modify RBAC authorization.
  2. Register the following resource types.
    # clresourcetype register SUNW.HAStoragePlus
    # clresourcetype register SUNW.gds
  3. Create a failover resource group for Samba.

    Note - Refer to Restriction for multiple Samba instances that require winbind for more information on the nodelist entry.


    # clresourcegroup create -n nodelist samba-resource-group
  4. Create a resource for the Samba Logical Hostname.
    # clreslogicalhostname create -g samba-resource-group \
    > -h samba-logical-hostname \
    > samba-logical-hostname-resource
  5. Create a resource for the Samba Disk Storage.
    1. If a ZFS highly available local file system is being used
      # clresource create -g samba-resource-group  \
      > -t SUNW.HAStoragePlus  \
      > -p Zpools=samba-zspool \
      > samba-hastorage-resource
    2. If a cluster file system or any other non-ZFS highly available local file system is being used
      # clresource create -g samba-resource-group  \
      > -t SUNW.HAStoragePlus  \
      > -p FilesystemMountPoints=samba-filesystem-mountpoint \
      > samba-hastorage-resource
  6. Bring online the failover resource group for Samba that now includes the HA Storage and Logical Hostname resources.
    # clresourcegroup online -M samba-resource-group
  7. If winbind is required, create and register a winbind resource.

    If Samba was dynamically linked and is being used as an Active Directory Server member you must configure the LDPATH variable to point to the Samba lib directory.

    Edit the samba_config file and follow the comments within that file. Ensure that SERVICES="winbindd" is specified. After you have edited samba_config, you must register the resource.

    # cd /opt/SUNWscsmb/util
    # vi samba_config
    # ./samba_register

    The following deployment example has been taken from Appendix B, Deployment Example: Installing Samba from http://www.samba.org.

    Vigor5# cat > /var/tmp/winbind_config <<-EOF #+++ Resource Specific Parameters +++ RS=winbind RG=samba-rg RS_LH=samba-lh RS_HAS=sambaZFS-has SERVICES="winbindd" #+++ Common Parameters +++ BINDIR=/opt/samba/bin SBINDIR=/opt/samba/sbin CFGDIR=/local/samba/smb1 LDPATH=/opt/samba/lib FMUSER=homer #+++ SMBD & NMBD Specific Parameters (See Note 1) +++ SAMBA_LOGDIR= SAMBA_FMPASS= SAMBA_FMDOMAIN= #+++ WINBIND Specific Parameters (See Note 2) +++ WINBIND_DISCACHE=FALSE WINBIND_SINGLEMODE=FALSE #+++ Zone Specific Parameters (See Note 3) +++ RS_ZONE= LHOST= PROJECT=default TIMEOUT=30 EOF
    Vigor5# /opt/SUNWscsmb/util/samba_register -f /var/tmp/winbind_config
  8. If winbind is required enable the resource.
    # clresource enable winbind-resource
  9. Create and register a Samba resource.

    If Samba was dynamically linked and is being used as an Active Directory Server member you must configure the LDPATH variable to point to the Samba lib directory.

    Edit the samba_config file and follow the comments within that file. Ensure that SERVICES="smbd" or SERVICES="smbd,nmbd" is specified. After you have edited samba_config, you must register the resource.

    # cd /opt/SUNWscsmb/util
    # vi samba_config
    # ./samba_register

    The following deployment example has been taken from Appendix B, Deployment Example: Installing Samba from http://www.samba.org.

    Vigor5# cat > /var/tmp/samba_config <<-EOF #+++ Resource Specific Parameters +++ RS=samba RG=samba-rg RS_LH=samba-lh RS_HAS=sambaZFS-has SERVICES="smbd" #+++ Common Parameters +++ BINDIR=/opt/samba/bin SBINDIR=/opt/samba/sbin CFGDIR=/local/samba/smb1 LDPATH=/opt/samba/lib FMUSER=homer #+++ SMBD & NMBD Specific Parameters (See Note 1) +++ SAMBA_LOGDIR=/local/samba/smb1/logs SAMBA_FMPASS=smb4#ads SAMBA_FMDOMAIN= #+++ WINBIND Specific Parameters (See Note 2) +++ WINBIND_DISCACHE= WINBIND_SINGLEMODE= #+++ Zone Specific Parameters (See Note 3) +++ RS_ZONE= LHOST= PROJECT=default TIMEOUT=30 EOF
    Vigor5# /opt/SUNWscsmb/util/samba_register -f /var/tmp/samba_config
  10. If winbind is used, ensure Samba is dependent on winbind.
    # clresource set -p Resource_dependencies=winbind-resource{local_node} samba-resource
  11. Enable the Samba resource.
    # clresource enable samba-resource

Next Steps

See Verifying the HA for Samba Installation and Configuration

How to Register and Configure HA for Samba in a failover resource group with winbind in a scalable resource group

This procedure assumes that you installed the data service packages during your initial Oracle Solaris Cluster installation.

If you did not install the HA for Samba packages as part of your initial Oracle Solaris Cluster installation, go to How to Install the HA for Samba Packages.


Note - Perform this procedure on one node of the cluster only.


  1. On a cluster member, become superuser or assume a role that provides solaris.cluster.modify RBAC authorization.
  2. Register the following resource types.
    # clresourcetype register SUNW.HAStoragePlus
    # clresourcetype register SUNW.gds
  3. Create a failover resource group for the winbind shared network address.

    Note - Refer to Restriction for multiple Samba instances that require winbind for more information on the nodelist entry.


    # clresourcegroup create -n nodelist winbind-failover-resource-group
  4. Create a resource for the winbind Logical Hostname.
    # clressharedaddress create -g winbind-failover-resource-group \
    > -h winbind-logical-hostname \
    > winbind-logical-hostname-resource
  5. Create a scalable resource group for the scalable winbind resource.

    Note - Refer to Restriction for multiple Samba instances that require winbind for more information on the nodelist entry.


    # clresourcegroup create -n nodelist -S \
    > -p Maximum_primaries=maximum-number-active-primaries \
    > -p Desired_primaries=desired-number-active-primaries \
    > winbind-scalable-resource-group
  6. Create a resource for the winbind Disk Storage.

    For a scalable HA Storage resource you must use a cluster file system.

    # clresource create -g winbind-scalable-resource-group  \
    > -t SUNW.HAStoragePlus \
    > -p FilesystemMountPoints=winbind-filesystem-mount-point \
    > -x AffinityOn=FALSE \
    > winbind-ha-storage-resource
  7. Enable the failover and scalable resource groups for winbind that now includes the HA Storage and Logical Hostname resources.
    # clresourcegroup online -M winbind-failover-resource-group
    # clresourcegroup online -M winbind-scalable-resource-group
  8. Create and register a winbind resource.

    If Samba was dynamically linked and is being used as an Active Directory Server member you must configure the LDPATH variable to point to the Samba lib directory.

    Edit the samba_config file and follow the comments within that file. Ensure that SERVICES="winbindd" is specified. After you have edited samba_config, you must register the resource.

    # cd /opt/SUNWscsmb/util
    # vi samba_config
    # ./samba_register

    The following modified deployment example has been taken from Appendix B, Deployment Example: Installing Samba from http://www.samba.org, which shows a winbind-scalable-resource-group and winbind-ha-storage-resource. The winbind configuration directory is also located in a cluster file system, /global/samba/winbind.

    Vigor5# cat > /var/tmp/winbind_config <<-EOF #+++ Resource Specific Parameters +++ RS=winbind RG=winbindS-rg RS_LH=winbind-lh RS_HAS=winbindS-has SERVICES="winbindd" #+++ Common Parameters +++ BINDIR=/opt/samba/bin SBINDIR=/opt/samba/sbin CFGDIR=/global/samba/winbind LDPATH=/opt/samba/lib FMUSER=homer #+++ SMBD & NMBD Specific Parameters (See Note 1) +++ SAMBA_LOGDIR= SAMBA_FMPASS= SAMBA_FMDOMAIN= #+++ WINBIND Specific Parameters (See Note 2) +++ WINBIND_DISCACHE=FALSE WINBIND_SINGLEMODE=FALSE #+++ Zone Specific Parameters (See Note 3) +++ RS_ZONE= LHOST= PROJECT=default TIMEOUT=30 EOF
    Vigor5# /opt/SUNWscsmb/util/samba_register -f /var/tmp/winbind_config
  9. Enable the winbind resource.
    # clresource enable winbind-resource
  10. Create and register a Samba resource in a failover resource group.

    Follow steps 3, 4, 5, 6, 9, 10 and 11 in How to Register and Configure HA for Samba in a failover resource group.

Next Steps

See Verifying the HA for Samba Installation and Configuration

How to Register and Configure HA for Samba in an HA Container

This procedure assumes that you installed the data service packages during your initial Oracle Solaris Cluster installation.

If you did not install the HA for Samba packages as part of your initial Oracle Solaris Cluster installation, go to How to Install the HA for Samba Packages.


Note - Perform this procedure on one node of the cluster only.


  1. Create a failover resource group for Samba.

    Follow steps 1, 2, 3, 4, 5 and 6 in How to Register and Configure HA for Samba in a failover resource group.

  2. Register the HA container in the failover resource group for Samba.

    Refer to Oracle Solaris Cluster Data Service for Solaris Containers Guide for complete information about HA containers.

    Edit the sczbt_config file and follow the comments within that file. Ensure that you specify the samba-resource-group for the RG= parameter within sczbt_config.

    After you have edited sczbt_config, you must register the resource.

    # cd /opt/SUNWsczone/sczbt/util
    # vi sczbt_config
    # ./sczbt_register

    The following deployment example has been taken from Appendix C, Deployment Example: Installing Samba in an HA Container.

    Vigor5# cat > /var/tmp/sczbt_config <<-EOF RS=sambaFOZ RG=samba-rg PARAMETERDIR=/zones SC_NETWORK=true SC_LH=samba-lh FAILOVER=true HAS_RS=sambaSVM-has,sambaZFS-has Zonename=failover Zonebootopt= Milestone=multi-user-server Mounts=/local EOF
    Vigor5#
    Vigor5# /opt/SUNWsczone/sczbt/util/sczbt_register -f /var/tmp/sczbt_config
  3. Enable the HA container resource.
    # clresource enable samba-failover-zone-resource
  4. If winbind is required, create and register a winbind resource.

    If Samba was dynamically linked and is being used as an Active Directory Server member you must configure the LDPATH variable to point to the Samba lib directory.

    Edit the samba_config file and follow the comments within that file. Ensure that SERVICES="winbindd" and the RS_ZONE variable specifies the Oracle Solaris Cluster resource for the HA container. After you have edited samba_config, you must register the resource.

    # cd /opt/SUNWscsmb/util
    # vi samba_config
    # ./samba_register
  5. If winbind is required, enable the winbind resource.
    # clresource enable winbind-resource
  6. Create and register a Samba resource.

    If Samba was dynamically linked and is being used as an Active Directory Server member you must configure the LDPATH variable to point to the Samba lib directory.

    Edit the samba_config file and follow the comments within that file. Ensure that SERVICES="smbd" or SERVICES="smbd,nmbd" and the RS_ZONE variable specifies the Oracle Solaris Cluster resource for the HA container. After you have edited samba_config, you must register the resource.

    # cd /opt/SUNWscsmb/util
    # vi samba_config
    # ./samba_register

    The following deployment example has been taken from Appendix C, Deployment Example: Installing Samba in an HA Container.

    Vigor5# cat > /var/tmp/samba_config <<-EOF #+++ Resource Specific Parameters +++ RS=samba RG=samba-rg RS_LH=samba-lh RS_HAS=sambaZFS-has SERVICES="smbd,nmbd" #+++ Common Parameters +++ BINDIR=/usr/sfw/bin SBINDIR=/usr/sfw/sbin CFGDIR=/local/samba/smb1 LDPATH=/usr/sfw/lib FMUSER=homer #+++ SMBD & NMBD Specific Parameters (See Note 1) +++ SAMBA_LOGDIR=/local/samba/smb1/logs SAMBA_FMPASS=samba SAMBA_FMDOMAIN= #+++ WINBIND Specific Parameters (See Note 2) +++ WINBIND_DISCACHE=FALSE WINBIND_SINGLEMODE=FALSE #+++ Zone Specific Parameters (See Note 3) +++ RS_ZONE=sambaFOZ LHOST=192.168.1.132 PROJECT=default TIMEOUT=30 EOF
    Vigor5#
    Vigor5# /opt/SUNWscsmb/util/samba_register -f /var/tmp/samba_config
  7. If winbind is used, ensure Samba is dependent on winbind.
    # clresource set -p Resource_dependencies=winbind-resource{local_node} samba-resource
  8. Enable the Samba resource.
    # clresource enable samba-resource

Next Steps

See Verifying the HA for Samba Installation and Configuration