### Example: Start Geo-Replication Source: https://docs.gluster.org/en/v3/Administrator%20Guide/Geo%20Replication Examples demonstrating how to start a geo-replication session with and without specifying a user for the slave host. ```bash gluster volume geo-replication gv1 snode1::gv2 start ``` ```bash gluster volume geo-replication gv1 geoaccount@snode1::gv2 start ``` -------------------------------- ### Install GlusterFS Source: https://docs.gluster.org/en/latest/Administrator-Guide/Gluster-On-ZFS Installs GlusterFS server and client packages, starts the GlusterFS daemon, and enables it to start on boot. ```bash wget -P /etc/yum.repos.d http://download.gluster.org/pub/gluster/glusterfs/LATEST/EPEL.repo/glusterfs-epel.repo yum install glusterfs{-fuse,-server} service glusterd start service glusterd status chkconfig glusterd on ``` -------------------------------- ### Example: Start Geo-Replication Session Source: https://docs.gluster.org/en/latest/Administrator-Guide/Geo-Replication An example demonstrating how to start a geo-replication session with specific primary and secondary volume details. ```bash gluster volume geo-replication gvol-primary \ geoaccount@snode1.example.com::gvol-secondary \ start ``` -------------------------------- ### Configurable Simple GlusterFS Setup Source: https://docs.gluster.org/en/latest/Administrator-Guide/Puppet This example shows how to pass parameters to the `gluster::simple` class to customize the GlusterFS setup, such as defining the replica count and specifying multiple volumes. ```puppet class { '::gluster::simple': replica => 2, volume => ['volume1', 'volume2', 'volumeN'], } ``` -------------------------------- ### Install and Start SCSI Target Service Source: https://docs.gluster.org/en/v3/Administrator%20Guide/GlusterFS%20iSCSI Install the necessary scsi-target-utils package and start the target daemon service. ```bash # yum install scsi-target-utils # service tgtd start ``` -------------------------------- ### Configure and Start Keystone Service Source: https://docs.gluster.org/en/latest/Administrator-Guide/GlusterFS-Keystone-Quickstart Enable the Keystone service to start on boot and then start the service. A delay may be needed before interacting with the service if scripting. ```bash sudo chkconfig openstack-keystone on sudo service openstack-keystone start # If you script this, you'll want to wait a few seconds to start using it ``` -------------------------------- ### Build and Install GlusterFS from Source Source: https://docs.gluster.org/en/latest/Administrator-Guide/Setting-Up-Clients Compiles and installs the Gluster Native Client software after the configuration step. This command builds the client and installs it to the system. ```bash make make install ``` -------------------------------- ### Build and Install ZFS Source: https://docs.gluster.org/en/latest/Administrator-Guide/Gluster-On-ZFS Builds and installs ZFS from source. This includes installing preliminary packages, configuring, compiling, and installing the ZFS RPMs, excluding the static module RPM. ```bash yum install zlib-devel libuuid-devel libblkid-devel libselinux-devel parted lsscsi ./configure make rpm rm zfs-modules-0.6.0*.x86_64.rpm rpm -Uvh zfs*.x86_64.rpm zfs*.noarch.rpm ``` -------------------------------- ### Install GlusterFS Source: https://docs.gluster.org/en/latest/Developer-guide/Building-GlusterFS Install the built GlusterFS binaries and files into the system. 'sudo' may be required if installing to a default prefix like '/usr/local'. ```bash sudo make install ``` -------------------------------- ### Install and Start iSCSI Target Service Source: https://docs.gluster.org/en/latest/Administrator-Guide/GlusterFS-iSCSI Install the necessary scsi-target-utils package and start the target daemon service. This provides the iSCSI target functionality. ```bash yum install scsi-target-utils service tgtd start ``` -------------------------------- ### Example: Retrieving Backend Brick Path from GFID Source: https://docs.gluster.org/en/latest/Troubleshooting/gfid-to-path Demonstrates using the `trusted.glusterfs.pathinfo` extended attribute to get the backend brick path for a given GFID. Shows the output format including volume type and brick path. ```bash [root@vm1 glusterfs]# getfattr -n trusted.glusterfs.pathinfo -e text /mnt/testvol/.gfid/11118443-1894-4273-9340-4b212fa1c0e4 getfattr: Removing leading '/' from absolute path names # file: mnt/testvol/.gfid/11118443-1894-4273-9340-4b212fa1c0e4 trusted.glusterfs.pathinfo="( )" ``` -------------------------------- ### Build and Install GlusterFS Source: https://docs.gluster.org/en/latest/Developer-guide/Development-Workflow Compile the GlusterFS source code and install it on the system. ```bash make && make install ``` -------------------------------- ### Enable and Start glusterd Automatically (systemd) Source: https://docs.gluster.org/en/latest/Administrator-Guide/Start-Stop-Daemon This command enables the glusterd service to start on boot and starts it immediately if it's not already running. ```bash systemctl enable --now glusterd ``` -------------------------------- ### Install GlusterFS Server Source: https://docs.gluster.org/en/v3/Quick-Start-Guide/Quickstart Install the GlusterFS server package on both nodes. ```bash yum install glusterfs-server ``` -------------------------------- ### Configure Automatic Start on Boot (Debian/Ubuntu) Source: https://docs.gluster.org/en/latest/Administrator-Guide/Start-Stop-Daemon Configure Debian-based systems to automatically start glusterd on system boot. ```bash update-rc.d glusterd defaults ``` -------------------------------- ### Example: Set Geo-Replication Checkpoint Source: https://docs.gluster.org/en/v3/Administrator%20Guide/Geo%20Replication An example of setting a checkpoint for Geo-Replication between 'gv1' and 'snode1::gv2'. ```bash gluster volume geo-replication gv1 snode1::gv2 config checkpoint now ``` -------------------------------- ### Start glusterd Manually (init.d) Source: https://docs.gluster.org/en/latest/Administrator-Guide/Start-Stop-Daemon Use this command to start the glusterd service on systems using init.d scripts. ```bash /etc/init.d/glusterd start ``` -------------------------------- ### Example: Mount Specific Device with ACLs Source: https://docs.gluster.org/en/latest/Administrator-Guide/Access-Control-Lists Example of mounting a specific device partition with POSIX ACLs support. ```bash mount -o acl /dev/sda1 /export1 ``` -------------------------------- ### Install Development Tools Source: https://docs.gluster.org/en/latest/Administrator-Guide/Gluster-On-ZFS Installs essential development tools required for compiling ZFS from source. ```bash yum groupinstall "Development Tools" ``` -------------------------------- ### Example: Mount GlusterFS Volume with ACLs Source: https://docs.gluster.org/en/latest/Administrator-Guide/Access-Control-Lists Example of mounting a glusterfs volume with POSIX ACLs support. ```bash mount -t glusterfs -o acl 198.192.198.234:glustervolume /mnt/gluster ``` -------------------------------- ### Install Gluster Server on Ubuntu Source: https://docs.gluster.org/en/v3/Install-Guide/Install Installs the GlusterFS server package on Ubuntu systems after adding the community PPA. ```bash sudo apt-get install glusterfs-server ``` -------------------------------- ### Start glusterd Manually (systemd) Source: https://docs.gluster.org/en/latest/Administrator-Guide/Start-Stop-Daemon Use this command to start the glusterd service on systems using systemd. ```bash systemctl start glusterd ``` -------------------------------- ### Start Gluster Daemon (Online Upgrade) Source: https://docs.gluster.org/en/latest/Upgrade-Guide/upgrade-to-4.1 Starts the Gluster daemon on the upgraded server to bring services back online. ```bash glusterd ``` -------------------------------- ### Example: View Geo-Replication Configuration Options Source: https://docs.gluster.org/en/v3/Administrator%20Guide/Geo%20Replication Examples demonstrating how to view general configuration and specific options like 'sync-jobs' for a geo-replication session. ```bash gluster volume geo-replication gv1 snode1::gv2 config ``` ```bash gluster volume geo-replication gv1 snode1::gv2 config sync-jobs ``` -------------------------------- ### Install Gluster Native Client Prerequisites Source: https://docs.gluster.org/en/latest/Administrator-Guide/Setting-Up-Clients Installs necessary prerequisite packages for the Gluster Native Client on RPM-based distributions. ```bash sudo yum -y install openssh-server wget fuse fuse-libs openib libibverbs ``` -------------------------------- ### Start Gluster Daemon Source: https://docs.gluster.org/en/v3/Upgrade-Guide/upgrade_to_4.0 Start the Gluster daemon after installing the new version on a server. This is required for both online and offline upgrade procedures. ```bash #glusterd ``` -------------------------------- ### Display Configure Help Source: https://docs.gluster.org/en/latest/Developer-guide/Building-GlusterFS View all available configuration options by running the configure script with the '--help' flag. ```bash ./configure --help ``` -------------------------------- ### Example: Create Test Volume with Thin Arbiter Source: https://docs.gluster.org/en/latest/Administrator-Guide/Thin-Arbiter-Volumes An example demonstrating the creation of a Gluster volume named 'testvol' with replica 2 and a thin arbiter. The --force option is used to override potential warnings. ```bash glustercli volume create testvol --replica 2 server{1..2}:/bricks/brick-{1..2} --thin-arbiter server-3:/bricks/brick_ta --force volume create: testvol: success: please start the volume to access data ``` -------------------------------- ### Example: Configure Sync Jobs for Geo-Replication Source: https://docs.gluster.org/en/v3/Administrator%20Guide/Geo%20Replication Example showing how to configure the number of simultaneous file synchronizations for a geo-replication session. ```bash gluster volume geo-replication gv1 snode1::gv2 config sync-jobs 3 ``` -------------------------------- ### GlusterFS Self-Heal Log Entries Source: https://docs.gluster.org/en/latest/Troubleshooting/troubleshooting-afr Example log messages indicating the progress of entry and metadata self-healing operations. These logs show when healing starts, completes, and the sources/sinks involved for specific file GFIDs. ```log [2019-05-07 12:05:14.460442] I [MSGID: 108026] [afr-self-heal-entry.c:883:afr_selfheal_entry_do] 0-testvol-replicate-0: performing entry selfheal on d120c0cf-6e87-454b-965b-0d83a4c752bb [2019-05-07 12:05:14.474710] I [MSGID: 108026] [afr-self-heal-common.c:1741:afr_log_selfheal] 0-testvol-replicate-0: Completed entry selfheal on d120c0cf-6e87-454b-965b-0d83a4c752bb. sources=[0] 2 sinks=1 [2019-05-07 12:05:14.493506] I [MSGID: 108026] [afr-self-heal-common.c:1741:afr_log_selfheal] 0-testvol-replicate-0: Completed data selfheal on a9b5f183-21eb-4fb3-a342-287d3a7dddc5. sources=[0] 2 sinks=1 [2019-05-07 12:05:14.494577] I [MSGID: 108026] [afr-self-heal-metadata.c:52:__afr_selfheal_metadata_do] 0-testvol-replicate-0: performing metadata selfheal on a9b5f183-21eb-4fb3-a342-287d3a7dddc5 [2019-05-07 12:05:14.498398] I [MSGID: 108026] [afr-self-heal-common.c:1741:afr_log_selfheal] 0-testvol-replicate-0: Completed metadata selfheal on a9b5f183-21eb-4fb3-a342-287d3a7dddc5. sources=[0] 2 sinks=1 ``` -------------------------------- ### Example gfind_missing_files.sh Execution and Output Source: https://docs.gluster.org/en/v3/GlusterFS%20Tools/gfind_missing_files Demonstrates how to run gfind_missing_files.sh and shows a typical output, including the GFIDs of missing files and a warning for unconvertible GFIDs. ```bash $ionice -c 2 -n 7 ./gfind_missing_files.sh /bricks/m3 acdc slave-vol ~/test_results/m3-4.txt Calling crawler... Crawl Complete. gfids of skipped files are available in the file /root/test_results/m3-4.txt Starting gfid to path conversion Path names of skipped files are available in the file /root/test_results/m3-4.txt_pathnames WARNING: Unable to convert some GFIDs to Paths, GFIDs logged to /root/test_results/m3-4.txt_gfids Use bash gfid_to_path.sh /root/test_results/m3-4.txt_gfids to convert those GFIDs to Path Total Missing File Count : 126733 ``` -------------------------------- ### Arguments for Volume Start Source: https://docs.gluster.org/en/latest/Administrator-Guide/Hook-scripts When starting a volume, these arguments can be passed to the hook scripts to indicate if it's the first volume being started. ```bash Start volume --first=yes, if the volume is the first to be started --first=no, for otherwise ``` -------------------------------- ### Install Additional Dependencies and Tools Source: https://docs.gluster.org/en/v3/Administrator%20Guide/Building%20QEMU%20With%20gfapi%20For%20Debian%20Based%20Systems Installs remaining dependencies and tools needed for building QEMU, including GlusterFS related libraries. ```bash # get almost all the rest and the tools to work up the Debian magic apt-get install devscripts quilt libiscsi-dev libusbredirparser-dev libssh2-1-dev libvdeplug-dev libjpeg-dev glusterfs* ``` -------------------------------- ### Start a Gluster Volume Source: https://docs.gluster.org/en/latest/Administrator-Guide/Setting-Up-Volumes Starts a Gluster volume. Ensure the volume is started before attempting to mount it to avoid client operations hanging. ```bash # gluster volume start [force] ``` ```bash # gluster volume start test-volume Starting test-volume has been successful ``` -------------------------------- ### Create and Start GlusterFS Admin Volume Source: https://docs.gluster.org/en/latest/Administrator-Guide/GlusterFS-Keystone-Quickstart Creates and starts a GlusterFS volume for administrative purposes and then starts the OpenStack Keystone service. ```bash sudo gluster volume create $volname $myhostname:$pathtobrick sudo gluster volume start $volname sudo service openstack-keystone start ``` -------------------------------- ### Configure Automatic Start on Boot (Red Hat/Fedora) Source: https://docs.gluster.org/en/latest/Administrator-Guide/Start-Stop-Daemon Configure Red Hat-based systems to automatically start glusterd on system boot. ```bash chkconfig glusterd on ``` -------------------------------- ### Example: Create Gluster Snapshots Source: https://docs.gluster.org/en/v3/Administrator%20Guide/Geo%20Replication An example of creating snapshots named 'snap1' for volumes 'gv2' (slave) and 'gv1' (master). ```bash gluster snapshot create snap1 gv2 gluster snapshot create snap1 gv1 ``` -------------------------------- ### Install GCC, Python Development Headers, and Setuptools on Fedora Source: https://docs.gluster.org/en/latest/Developer-guide/compiling-rpms Installs necessary build tools for compiling GlusterFS on Fedora systems. ```bash sudo yum -y install gcc python-devel python-setuptools ``` -------------------------------- ### Install ZFS on RHEL 7 Source: https://docs.gluster.org/en/latest/Administrator-Guide/Gluster-On-ZFS Installs ZFS on Linux for RHEL 7 by adding EPEL and ZFS repositories and installing necessary packages. ```bash yum localinstall --nogpgcheck https://download.fedoraproject.org/pub/epel/7/x86_64/e/epel-release-7-2.noarch.rpm yum localinstall --nogpgcheck http://archive.zfsonlinux.org/epel/zfs-release.el7.noarch.rpm yum install kernel-devel zfs ``` -------------------------------- ### Simple GlusterFS Setup with Puppet Source: https://docs.gluster.org/en/latest/Administrator-Guide/Puppet This snippet demonstrates the most basic way to set up a GlusterFS cluster using the `gluster::simple` class. It ensures identical configurations across all hosts in the cluster by using a shared Puppet host definition. ```puppet node /^annex\d+$/ { class { '::gluster::simple': } } ``` -------------------------------- ### Install ZFS on RHEL 6 Source: https://docs.gluster.org/en/latest/Administrator-Guide/Gluster-On-ZFS Installs ZFS on Linux for RHEL 6 by adding EPEL and ZFS repositories and installing necessary packages. ```bash yum localinstall --nogpgcheck https://download.fedoraproject.org/pub/epel/6/x86_64/epel-release-6-8.noarch.rpm yum localinstall --nogpgcheck http://archive.zfsonlinux.org/epel/zfs-release.el6.noarch.rpm yum install kernel-devel zfs ``` -------------------------------- ### Example 'mount' Output for GlusterFS Source: https://docs.gluster.org/en/v3/Administrator%20Guide/Setting%20Up%20Clients This is an example of what the output of the `mount` command might look like after a successful Gluster volume mount. ```bash server1:/test-volume on /mnt/glusterfs type fuse.glusterfs (rw,allow_other,default_permissions,max_read=131072 ``` -------------------------------- ### Install OpenSSH Server on Debian Source: https://docs.gluster.org/en/latest/Administrator-Guide/Setting-Up-Clients Installs the OpenSSH server, vim, and wget packages on Debian-based systems. This is a prerequisite for Gluster Native Client installation. ```bash sudo apt-get install openssh-server vim wget ``` -------------------------------- ### Build and Install GlusterFS from Source Source: https://docs.gluster.org/en/v3/Administrator%20Guide/Setting%20Up%20Clients Compiles and installs the Gluster Native Client software after the configuration step. These commands are executed in the source directory. ```bash # make ``` ```bash # make install ``` -------------------------------- ### Starting and Enabling Bareos Daemons Source: https://docs.gluster.org/en/latest/Administrator-Guide/Bareos Ensures that the Bareos storage daemon, file daemon, and director services are running and configured to start automatically on system boot. ```bash systemctl start bareos­sd systemctl start bareos­fd systemctl start bareos­dir systemctl enable bareos­sd systemctl enable bareos­fd systemctl enable bareos­dir ``` -------------------------------- ### Enable and Start Events API (SysVInit) Source: https://docs.gluster.org/en/latest/Administrator-Guide/Events-APIs For SysVInit systems like CentOS 6, enable the glustereventsd service to start on boot and then start the service. ```bash chkconfig glustereventsd on service glustereventsd start ``` -------------------------------- ### Example: Create a Test Arbiter Volume Source: https://docs.gluster.org/en/v3/Administrator%20Guide/arbiter-volumes-and-quorum An example demonstrating the creation of a Gluster volume named 'testvol' with replica 3 and arbiter 1, using six bricks. ```bash # gluster volume create testvol replica 3 arbiter 1 server{1..6}:/bricks/brick volume create: testvol: success: please start the volume to access data ``` -------------------------------- ### Enable and Start Events API (Systemd) Source: https://docs.gluster.org/en/latest/Administrator-Guide/Events-APIs For systems using systemd, enable and start the glustereventsd service. This ensures the service starts on boot and is running. ```bash systemctl enable glustereventsd systemctl start glustereventsd ``` -------------------------------- ### Example gfind_missing_files.sh Execution and Output Source: https://docs.gluster.org/en/latest/GlusterFS-Tools/gfind-missing-files This example demonstrates how to run the gfind_missing_files.sh script and shows a typical output, including the GFIDs of skipped files and a warning about potential GFID-to-path conversion failures. ```bash # ionice -c 2 -n 7 ./gfind_missing_files.sh /bricks/m3 acdc secondary-vol ~/test_results/m3-4.txt Calling crawler... Crawl Complete. gfids of skipped files are available in the file /root/test_results/m3-4.txt Starting gfid to path conversion Path names of skipped files are available in the file /root/test_results/m3-4.txt_pathnames WARNING: Unable to convert some GFIDs to Paths, GFIDs logged to /root/test_results/m3-4.txt_gfids Use bash gfid_to_path.sh /root/test_results/m3-4.txt_gfids to convert those GFIDs to Path Total Missing File Count : 126733 ``` -------------------------------- ### Example: Create an Arbiter Volume Source: https://docs.gluster.org/en/latest/Administrator-Guide/arbiter-volumes-and-quorum An example of creating an arbiter volume named 'testvol' with 6 bricks, configured as replica 2 with 1 arbiter. ```bash gluster volume create testvol replica 2 arbiter 1 server{1..6}:/bricks/brick ``` -------------------------------- ### Configure Automatic Start on Boot (Other Systems) Source: https://docs.gluster.org/en/latest/Administrator-Guide/Start-Stop-Daemon Configure systems other than Red Hat or Debian to automatically start glusterd by adding an entry to /etc/rc.local. ```bash echo "glusterd" >> /etc/rc.local ``` -------------------------------- ### Build and Install ZFS RPMs Source: https://docs.gluster.org/en/v3/Administrator%20Guide/Gluster%20On%20ZFS Installs necessary development packages, configures, builds, and installs the ZFS RPM packages. It removes the static module RPM as DKMS is being used. ```bash yum install zlib-devel libuuid-devel libblkid-devel libselinux-devel parted lsscsi ./configure make rpm rm zfs-modules-0.6.0*.x86_64.rpm rpm -Uvh zfs*.x86_64.rpm zfs*.noarch.rpm ``` -------------------------------- ### Build and Install SPL Source: https://docs.gluster.org/en/latest/Administrator-Guide/Gluster-On-ZFS Builds and installs the SPL (Solaris Porting Layer) from source. This process generates RPMs, removes the static module RPM, and installs the remaining packages. ```bash ./configure make rpm rm spl-modules-0.6.0*.x86_64.rpm rpm -Uvh spl*.x86_64.rpm spl*.noarch.rpm ``` -------------------------------- ### Download and Prepare QEMU and GlusterFS Sources Source: https://docs.gluster.org/en/v3/Administrator%20Guide/Building%20QEMU%20With%20gfapi%20For%20Debian%20Based%20Systems Downloads QEMU and GlusterFS source code and their respective Debian packaging files. It also prepares the GlusterFS source for integration into the QEMU build. ```bash cd .. mkdir qemu cd qemu # download our sources. you'll want to check back frequently on these for changes wget http://ftp.de.debian.org/debian/pool/main/q/qemu/qemu_1.7.0+dfsg.orig.tar.xz wget http://ftp.de.debian.org/debian/pool/main/q/qemu/qemu_1.7.0+dfsg-2.debian.tar.gz wget http://download.gluster.org/pub/gluster/glusterfs/3.4/LATEST/glusterfs-3.4.2.tar.gz tar xf glusterfs-3.4.2.tar.gz tar xf qemu_1.7.0+dfsg.orig.tar.xz cd qemu-1.7.0+dfsg/ # unpack the debian magic tar xf ../qemu_1.7.0+dfsg-2.debian.tar.gz # bring glusterfs in to the buiild cp -r ../glusterfs-3.4.2 glusterfs # the glusterfs check in configure looks around weird. I've never asked why but moving the src stuff up one works and tests fine cd glusterfs/api/ mv src/* . cd ../.. #you'll need to edit debian/control to enable glusterfs replacing - ##--enable-glusterfs todo + # --enable-glusterfs + glusterfs-common (>= 3.4.0), #And finally build. It'll take ages. http://xkcd.com/303/ # apply series if any while quilt push; do quilt refresh; done # build packages debuild -i -us -uc -b cd .. ``` -------------------------------- ### Mount Partition and Prepare Gluster Brick Source: https://docs.gluster.org/en/latest/Install-Guide/Configure Create the directory `/export/sdb1` if it doesn't exist and then mount all filesystems defined in `/etc/fstab`. ```bash mkdir -p /export/sdb1 && mount -a ``` -------------------------------- ### Install software-properties-common on Ubuntu Source: https://docs.gluster.org/en/latest/Install-Guide/Install Installs the software-properties-common package, which is required for managing repositories on Ubuntu. ```bash apt install software-properties-common ``` -------------------------------- ### GlusterFS Configure Summary Source: https://docs.gluster.org/en/v3/Developer-guide/Building-GlusterFS Example output of the GlusterFS configure script, showing enabled features. ```text GlusterFS configure summary =========================== FUSE client : yes Infiniband verbs : yes epoll IO multiplex : yes argp-standalone : no fusermount : yes readline : yes georeplication : yes Linux-AIO : yes Enable Debug : no Block Device xlator : yes glupy : yes Use syslog : yes XML output : yes Encryption xlator : yes Unit Tests : no Track priv ports : yes POSIX ACLs : yes Data Classification : yes SELinux features : yes firewalld-config : no Experimental xlators : yes Events : yes EC dynamic support : x64 sse avx Use memory pools : yes Nanosecond m/atimes : yes Legacy gNFS server : no ``` -------------------------------- ### Install GlusterFS Server on Debian Source: https://docs.gluster.org/en/latest/Install-Guide/Install Installs the GlusterFS server package on Debian-based systems. ```bash apt install glusterfs-server ``` -------------------------------- ### Create Geo-replication Setup Source: https://docs.gluster.org/en/v3/release-notes/4.0.0 Use this command to set up Geo-replication when Master and Remote volumes are available and running. ```bash glustercli geo-replication create :: ``` -------------------------------- ### Install Openstack-Keystone Source: https://docs.gluster.org/en/latest/Administrator-Guide/GlusterFS-Keystone-Quickstart Installs the OpenStack Keystone service, utility tools, and Python client. ```bash sudo yum install openstack-keystone openstack-utils python-keystoneclient ``` -------------------------------- ### Start glusterd Manually Source: https://docs.gluster.org/en/v3/Administrator%20Guide/Start%20Stop%20Daemon Use this command to start the glusterd service on a GlusterFS server. ```bash # /etc/init.d/glusterd start ``` -------------------------------- ### Create and Mount Brick Directories (Two Bricks Per Server) Source: https://docs.gluster.org/en/latest/Administrator-Guide/Brick-Naming-Conventions On all servers, create two brick directories and mount their respective physical disk partitions. This prepares the system for a volume with multiple bricks per server. ```bash mkdir -p /data/glusterfs/myvol2/brick{1,2} mount /dev/sdb1 /data/glusterfs/myvol2/brick1 mount /dev/sdc1 /data/glusterfs/myvol2/brick2 ``` -------------------------------- ### Start Gluster Events Daemon Source: https://docs.gluster.org/en/latest/Upgrade-Guide/generic-upgrade-procedure Starts the glustereventsd service if it was previously enabled and stopped. ```bash systemctl start glustereventsd ``` -------------------------------- ### Start Gluster Events Daemon Source: https://docs.gluster.org/en/latest/Upgrade-Guide/upgrade-to-4.1 Starts the glustereventsd service if it was previously enabled and stopped. ```bash systemctl start glustereventsd ``` -------------------------------- ### Initialize Bareos SQLite Database Source: https://docs.gluster.org/en/v3/Administrator%20Guide/Bareos Creates the initial Bareos database using SQLite and sets the correct ownership and permissions for the database file. This is a minimal setup for testing. ```bash # sqlite3 /var/lib/bareos/bareos.db < /usr/lib/bareos/scripts/ddl/creates/sqlite3.sql # chown bareos:bareos /var/lib/bareos/bareos.db # chmod 0660 /var/lib/bareos/bareos.db ``` -------------------------------- ### Example of Deleting a Geo-Replication Session Source: https://docs.gluster.org/en/v3/Administrator%20Guide/Geo%20Replication This example shows how to delete a specific geo-replication session. ```bash gluster volume geo-replication gv1 snode1::gv2 delete ``` -------------------------------- ### Install QEMU Build Dependencies Source: https://docs.gluster.org/en/latest/Administrator-Guide/Building-QEMU-With-gfapi-For-Debian-Based-Systems Installs the necessary build dependencies for QEMU on Debian-based systems. ```bash apt-get build-dep qemu ``` -------------------------------- ### Start GlusterFS Daemon Source: https://docs.gluster.org/en/v3/Developer-guide/Building-GlusterFS Manually starts the glusterd daemon in the background. Requires root privileges. ```bash # glusterd ``` -------------------------------- ### Run Bareos Backup Job Source: https://docs.gluster.org/en/latest/Administrator-Guide/Bareos Initiate a backup job using bconsole. This example shows how to select and run the 'BackupClient1' job. ```bash *run A job name must be specified. The defined Job resources are: 1: BackupClient1 2: BackupCatalog 3: RestoreFiles Select Job resource (1-3): 1 Run Backup job JobName: BackupClient1 Level: Incremental Client: backup-fd ... OK to run? (yes/mod/no): yes Job queued. JobId=1 ``` -------------------------------- ### Create and Mount Volume Source: https://docs.gluster.org/en/v3/Administrator%20Guide/Trash Create a simple distributed GlusterFS volume and start it, followed by mounting the volume using the native client. ```bash # gluster volume create test rhs:/home/brick # gluster volume start test # mount -t glusterfs rhs:test /mnt ``` -------------------------------- ### Set Alert Time Example Source: https://docs.gluster.org/en/latest/Administrator-Guide/Directory-Quota Example of setting the alert time to one day for the 'test-volume'. ```bash # gluster volume quota test-volume alert-time 1d volume quota : success ```