Start/stop the geo-replication session from
volume geo-replication [
Query status of the geo-replication session from
volume geo-replication
Pause/resume the geo-replication session from
volumegeo-replication
Delete the geo-replication session from
volume geo-replication
View (when no option provided) or set configuration for this geo-replication session. Use \ to reset option
8.2.7 Bitrot Commands
volume bitrot
volume bitrot
Scrub-throttle value is a measure of how fast or slow the scrubber scrubs the filesystem for volume
volume bitrot
volume bitrot
Pause/Resume scrub. Upon resume, scrubber continues where it left off. status option shows the statistics of scrubber. ondemand option starts the scrubbing immediately if the scrubber is not paused or already running.
8.2.8 快照命令
snapshot create
User can override this behaviour using \option. The description cannot be more than 1024 char-acters. To be able to take a snapshot, volume should be present and it should be in started state.
snapshot restore
Restores an already taken snapshot of a GlusterFS volume. Snapshot restore is an offline activity therefore if the volume is online (instarted state) then the restore operation will fail. Once the snapshot is restored it will not be available in the list of snapshots. snapshot clone
Create a clone of a snapshot volume, the resulting volume will be GlusterFS volume. User can provide a clone-name. To be able to take aclone, snapshot should be present and it should be in activated state.
snapshot delete ( all |
If snapname is specified then mentioned snapshot is deleted. If volname is specified then all snapshots belonging to that particular volume is deleted. If keyword *all* is used then all snapshots belonging to the system is deleted. snapshot list [volname]
Listsallsnapshots taken. If volname is provided, then only the snapshots belonging to that particular volume is listed.
snapshot info [snapname | (volume
This command gives information such as snapshot name, snapshot UUID, time at which snapshot was created, and it lists down the snap-volume-name, number of snapshots already taken and number of snapshots still available for that particular volume, andthestate of the snapshot. Ifsnapname is specified then info of thementionedsnapshot is displayed. If volname is specified then info of all snapshots belonging to that volume is displayed. If bothsnapname andvolnameisnot specified then info of all thesnapshotspresentin the system are displayed. snapshot status [snapname | (volume
This command gives status of the snapshot. The details included are snapshot brick path, volume group(LVM details), status of the snapshot bricks, PID of the bricks, data percentage filled for that particular volume group to which the snapshots belong to, and total sizeof the logical volume.
If snapname is specified then status of the mentioned snapshot is displayed. If volname is specified then status of all snapshots belonging to that volume is displayed. If both snapname and volname is not specified then status of all the snapshots present in the system aredisplayed. snapshot config [volname] ([snap-max-hard-limit
snapshot config without any keywords displays the snapshot config values of all volumes in the system. If volname is provided, then thesnapshot config values of that volume is displayed. 石家庄众毅信息技术有限公司共47页第36页
Snapshot config command along with keywords can be used to change the existing config values. If volname is provided then config value of that volume is changed, else it will set/change the system limit.
snap-max-soft-limit and auto-delete are global options, that will be inherited by all volumes in the system and cannot be set to individ ual volumes.
snap-max-hard-limit can be set globally, as well as per volume. The lowest limit between the global system limit and the volume specificlimit, becomes the \for a volume.
snap-max-soft-limit is a percentage value, which is applied on the \snap-max-hard-limit\
When auto-delete feature is enabled, then upon reaching the \every successful snapshot creation, theoldest snapshot will be deleted.
When auto-delete feature is disabled, then upon reaching the %user gets a warning with every successful snapshot creation.
When auto-delete feature is disabled, then upon reaching the \snap-max-hard-limit\further snapshot creations will not be allowed.
activate-on-create is disabled by default. If you enable activate-on-create, then further snapshot will be activated during the time ofsnapshot creation. snapshot activate
Activates the mentioned snapshot.
Note : By default the snapshot is activated during snapshot creation. snapshot deactivate
Deactivates the mentioned snapshot. snapshot help
Display help for the snapshot commands.
8.2.9 自修复命令
volume heal
Triggers index self heal for the files that need healing. volume heal
Enable/disable self-heal-daemon for volume
Triggers self heal on all the files. volume heal
Lists the files that need healing. 石家庄众毅信息技术有限公司共47页第37页
volume heal
Lists the files which are in split-brain state. volume heal
volume heal
Performs healing of
volume heal
Selects
volume heal
8.2.10 其它命令
get-state [
Get local state representation of mentioned daemon and store data in provided path information
help Display the command options. quit Exit the gluster command line interface.
石家庄众毅信息技术有限公司共47页第38页
第9章 客户端方式
客户端使用GFS有多种方式,性能最高的方式是使用gluster的native接口,此外还有NFS和CIFS方式。
9.1 native方式
1 安装gluserfs-fuse安装包,
2 挂载卷:mount -t glusterfs host/ip:path mnt-point
注意,这里提供的IP和主机只用来为客户提供volfile信息,后续客户便直接和需要的服务器通信了。 3 设置自动挂载
echo \
9.2 NFS服务
Gluster提供了内置的NFS服务,支持其他实现了NFSv3的客户端直接访问。
1. #service nfs stop # 关闭Linux内核自带的NFS服务 2. #service rpcbind start # 启动rpc端口映射管理 3. #rpc.statd
然后客户端挂载
1. mount -t nfs -o vers=3 host/ip:/path mnt-port
window7客户端
程序和功能->打开或关闭windows功能,安装NFS客户端功能,即可使用mount/showmount功能。
9.3 CIFS方式
cifs可以提供给WIN及samba客户端访问,对于windows程序,可以使用//ip/path通过SMB协议来方便的使用远程资源 1 在服务器将glusterfs挂载到/mnt/gfs
2 服务器通过samba配置将/mnt/gfs导出服务,启动smb服务
3 在win客户端上挂载samber服务器导出共享mount -t cifs //ip/path /mnt-point
9.4 QEMU集成 9.5 iSCSI
石家庄众毅信息技术有限公司共47页第39页
百度搜索“77cn”或“免费范文网”即可找到本站免费阅读全部范文。收藏本站方便下次阅读,免费范文网,提供经典小说综合文库GlusterFS学习笔记(翻译by 张文超)(8)在线全文阅读。
相关推荐: