分享

ceph中怎么删除pool

lz19851224 发表于 2016-7-7 16:45:14 [显示全部楼层] 回帖奖励 阅读模式 关闭右栏 2 22017
按照官网的来,能创建、能查看、但是删除就报错,找度娘也没找到怎么回事,说是代码问题

ceph osd pool create jiayuan 100
pool 'jiayuan' created

[root@admin-node bin]# ceph osd lspools
0 rbd,1 .rgw.root,2 default.rgw.control,3 default.rgw.data.root,4 default.rgw.gc,5 default.rgw.log,6 default.rgw.users.uid,7 jiayuan,

[root@admin-node bin]# ceph osd pool delete jiayuan  jiayuan  --yes-i-really-really-mean-it
Traceback (most recent call last):
  File "/usr/bin/ceph", line 948, in <module>
    retval = main()
  File "/usr/bin/ceph", line 881, in main
    sigdict, inbuf, verbose)
  File "/usr/bin/ceph", line 429, in new_style_command
    valid_dict = validate_command(sigdict, cmdargs, verbose)
  File "/usr/lib/python2.7/site-packages/ceph_argparse.py", line 982, in validate_command
    matched = matchnum(args, sig, partial=True)
  File "/usr/lib/python2.7/site-packages/ceph_argparse.py", line 790, in matchnum
    validate_one(word, desc, partial and (len(words) == 0))
  File "/usr/lib/python2.7/site-packages/ceph_argparse.py", line 761, in validate_one
    desc.instance.valid(word, partial)
  File "/usr/lib/python2.7/site-packages/ceph_argparse.py", line 454, in valid
    raise ArgumentValid("{0} not in {1}".  format(s, self))
UnicodeEncodeError: 'ascii' codec can't encode character u'\xa0' in position 0: ordinal not in range(128)
[root@admin-node bin]# ceph osd pool delete jiayuan  jiayuan  
Traceback (most recent call last):
  File "/usr/bin/ceph", line 948, in <module>
    retval = main()
  File "/usr/bin/ceph", line 881, in main
    sigdict, inbuf, verbose)
  File "/usr/bin/ceph", line 429, in new_style_command
    valid_dict = validate_command(sigdict, cmdargs, verbose)
  File "/usr/lib/python2.7/site-packages/ceph_argparse.py", line 982, in validate_command
    matched = matchnum(args, sig, partial=True)
  File "/usr/lib/python2.7/site-packages/ceph_argparse.py", line 790, in matchnum
    validate_one(word, desc, partial and (len(words) == 0))
  File "/usr/lib/python2.7/site-packages/ceph_argparse.py", line 761, in validate_one
    desc.instance.valid(word, partial)
  File "/usr/lib/python2.7/site-packages/ceph_argparse.py", line 454, in valid
    raise ArgumentValid("{0} not in {1}".  format(s, self))
UnicodeEncodeError: 'ascii' codec can't encode character u'\xa0' in position 0: ordinal not in range(128)

已有(2)人评论

跳转到指定楼层
easthome001 发表于 2016-7-7 17:59:58
检测下配置编码
比如:
/etc/default/locale
LANG="en_US.UTF-8"

如果英文不错,可以参考这个链接
http://stackoverflow.com/questions/9942594/unicodeencodeerror-ascii-codec-cant-encode-character-u-xa0-in-position-20
回复

使用道具 举报

lz19851224 发表于 2016-7-8 17:20:13
这个问题已解决 ceph osd pool delete jiayuan jiayuan  --yes-i-really-really-mean-it 命令是一样的不知道今天怎么就行了
ceph osd pool delete jiayuan-1 jiayuan-1  --yes-i-really-really-mean-it
pool 'jiayuan-1' removed
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

关闭

推荐上一条 /2 下一条