GlusterFS常见错误及解决方法

在安装GlusterFS的时候曾经遇到过一些错误,解决这些错误时花费了不少时间,科威网在此列举几个比较常见的,并提供相应的解决办法,希望可以帮助大家少走几步弯路,节省一些时间。

  1. mount.nfs: access denied by server while mounting…

  2. GlusterFS可以跟你所用的NFS版本有冲突,停用NFS然后重启GlusterFS或者重启服务器可以解决这个问题:

    # /etc/init.d/nfs stop
    # chkconfig nfs off
  3. requested NFS version or transport protocol is not supported

  4. GlusterFS不支持UDP协议,当你的NFS客户端使用UDP协议连接GlusterFS时就会出现这个错误,解决办法是使用TCP协议连接:

    # mount -o mountproto=tcp -t nfs server1:/test-volume /mnt/glusterfs
  5. GlusterFS: {path} or a prefix of it is already part of a volume

  6. 当你创建Volume时,使用曾经被用来创建过Volume的目录将出现这个错误。比如你曾经使用server1:/data目录创建了名叫dis-volume的卷,之后把这个卷删除了,然后又想用server1:/data创建一个名叫rep-volume的卷时,就会遇到这个错误。
    解决办法,在server1上运行命令:

    # setfattr -x trusted.glusterfs.volume-id /data
    # setfattr -x trusted.gfid /data
    # rm -rf /data/.glusterfs
    

    运行上述命令时如果出现属性不存在的错误提示,忽略即可。然后这个目录就可以重新用于创建新Volume了。


除非注明,科威网文章均为原创。转载请以链接形式标明本文地址。
本文地址:http://quenywell.com/glusterfs-error-and-solution/

Leave a Comment

您的邮箱地址不会被公开。 必填项已用 * 标注