Trouble installing standalone VSM Dashboard for importing existing ceph cluster

classic Classic list List threaded Threaded
13 messages Options
Reply | Threaded
Open this post in threaded view
|

Trouble installing standalone VSM Dashboard for importing existing ceph cluster

maxstack
Hi,

I am having difficulty installing a standalone VSM dashboard to import an existing ceph cluster.

I am running Ubuntu14, the install script fails at:

Reading package lists... Done
++ wc -l
++ grep 'install ok installed'
++ dpkg -s dpkg-dev
+ IS_DPKG_DEV=1
+ [[ 1 -eq 0 ]]
+ mkdir -p vsm-dep-repo/vsm-dep-repo
+ cd vsm-dep-repo
+ cp '*.deb' vsm-dep-repo
cp: cannot stat ‘*.deb’: No such file or directory


Does anyone have any steps on bringing up a standalone VSM Dashboard on either Centos6 or Ubuntu14 so I can import an existing cluster?

Thanks,

Max
Reply | Threaded
Open this post in threaded view
|

Re: Trouble installing standalone VSM Dashboard for importing existing ceph cluster

bxzhu
hi maxstack,
        If you want to only install the controller node, you should run command "./install.sh -v <version> --controller <ip or hostname> --prepare".
        But if you want to import and manage an existing ceph cluster, you should set your ceph node as vsm agent node that you should install vsm, too.
Reply | Threaded
Open this post in threaded view
|

Re: Trouble installing standalone VSM Dashboard for importing existing ceph cluster

maxstack
Thanks, I moved my install to a Centos 7 server, and downloaded the 2.1 release tar file from github.

Using ./install.sh -v 2.1 --controller 10.0.1.25 --prepare my install now fails with:

Package 1:smartmontools-6.2-4.el7.x86_64 already installed and latest version
Nothing to do
+ sudo -E rm -rf /etc/manifest/cluster.manifest
+ sudo -E cp manifest/10.0.1.25/cluster.manifest /etc/manifest
+ sudo -E chown root:vsm /etc/manifest/cluster.manifest
+ sudo -E chmod 755 /etc/manifest/cluster.manifest
++ env PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/root/bin:/usr/local/bin:/usr/bin:/usr/local/sbin:/usr/sbin cluster_manifest
++ grep error
++ wc -l
Traceback (most recent call last):
  File "/usr/local/bin/cluster_manifest", line 21, in <module>
    from vsm.manifest.parser import ManifestParser
  File "/usr/lib/python2.7/site-packages/vsm/manifest/__init__.py", line 22, in <module>
    from vsm.manifest import config
  File "/usr/lib/python2.7/site-packages/vsm/manifest/config.py", line 26, in <module>
    from vsm import exception
  File "/usr/lib/python2.7/site-packages/vsm/exception.py", line 27, in <module>
    from oslo.config import cfg
ImportError: No module named config
+ '[' 0 -gt 0 ']'
+ [[ -n '' ]]
+ sudo -E env PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/root/bin:/usr/local/bin:/usr/bin:/usr/local/sbin:/usr/sbin vsm-controller

Traceback (most recent call last):
  File "/usr/local/bin/getip", line 146, in <module>
    iper = GetIp()
  File "/usr/local/bin/getip", line 33, in __init__
    self._cluster_addr = self._parser.get_cluster_dict()
  File "/usr/local/bin/getip", line 140, in get_cluster_dict
    _get_cluster_value('ceph_public_addr'),
  File "/usr/local/bin/getip", line 128, in _get_cluster_value
    single_line = self._lines[pos]
IndexError: list index out of range


Whenever I try to run cluster_manifest i get the following traceback:

[root@vsm-controller 2.1.0-336]# cluster_manifest
Traceback (most recent call last):
  File "/usr/local/bin/cluster_manifest", line 21, in <module>
    from vsm.manifest.parser import ManifestParser
  File "/usr/lib/python2.7/site-packages/vsm/manifest/__init__.py", line 22, in <module>
    from vsm.manifest import config
  File "/usr/lib/python2.7/site-packages/vsm/manifest/config.py", line 26, in <module>
    from vsm import exception
  File "/usr/lib/python2.7/site-packages/vsm/exception.py", line 27, in <module>
    from oslo.config import cfg
ImportError: No module named config
Reply | Threaded
Open this post in threaded view
|

Re: Trouble installing standalone VSM Dashboard for importing existing ceph cluster

bxzhu
hi maxstack,
      For the tip of "ImportError: No module named config", I think you have installed the python-oslo-config before you install the vsm or you add the openstack repo by yourself(If yes, remove the openstack repo). You must remove the packages by yourself or can install it on a clear server.
      For the tip of "IndexError: list index out of range", please check the cluster.manifest(the ceph_public_addr parameter) on your controller node folder under the manifest directory.
Reply | Threaded
Open this post in threaded view
|

Re: Trouble installing standalone VSM Dashboard for importing existing ceph cluster

maxstack
Hi bxzhu,

Thanks for you reply, I have installed a fresh CentOS7 server and only added the epel repo, this is where it gets stuck now:

+ sudo -E rm -rf /etc/manifest/cluster.manifest
+ sudo -E cp manifest/10.0.1.20/cluster.manifest /etc/manifest
+ sudo -E chown root:vsm /etc/manifest/cluster.manifest
+ sudo -E chmod 755 /etc/manifest/cluster.manifest
++ env PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/root/bin:/usr/local/bin:/usr/bin:/usr/local/sbin:/usr/sbin cluster_manifest
++ wc -l
++ grep error
No handlers could be found for logger "vsm.manifest.parser"
Traceback (most recent call last):
  File "/usr/local/bin/cluster_manifest", line 240, in <module>
    smp = ManifestChecker(fpath)
  File "/usr/local/bin/cluster_manifest", line 43, in __init__
    self._info = self._smp.format_to_json()
  File "/usr/lib/python2.7/site-packages/vsm/manifest/parser.py", line 584, in format_to_json
    return self._format_cluster_manifest_to_json()
  File "/usr/lib/python2.7/site-packages/vsm/manifest/parser.py", line 565, in _format_cluster_manifest_to_json
    self._dict_insert_storage_class_c()
  File "/usr/lib/python2.7/site-packages/vsm/manifest/parser.py", line 433, in _dict_insert_storage_class_c
    raise
TypeError: exceptions must be old-style classes or derived from BaseException, not NoneType
+ '[' 0 -gt 0 ']'
+ [[ -n '' ]]
+ sudo -E env PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/root/bin:/usr/local/bin:/usr/bin:/usr/local/sbin:/usr/sbin vsm-controller

Traceback (most recent call last):
  File "/usr/local/bin/getip", line 147, in <module>
    res = iper.get_controller_ip()
  File "/usr/local/bin/getip", line 78, in get_controller_ip
    ip = self._match_ip(ip_mask)
  File "/usr/local/bin/getip", line 69, in _match_ip
    res = self._is_in_lan(item, ip_mask)
  File "/usr/local/bin/getip", line 62, in _is_in_lan
    if ip in ipcalc.Network(ip_mask):
  File "/usr/lib/python2.7/site-packages/vsm/ipcalc.py", line 621, in __contains__
    return self.check_collision(ip)
  File "/usr/lib/python2.7/site-packages/vsm/ipcalc.py", line 608, in check_collision
    other = Network(other)
  File "/usr/lib/python2.7/site-packages/vsm/ipcalc.py", line 157, in __init__
    self.ip = self._dqtoi(ip)
  File "/usr/lib/python2.7/site-packages/vsm/ipcalc.py", line 283, in _dqtoi
    if not 0 <= int(h, 16) <= 0xffff:
ValueError: invalid literal for int() with base 16: '6e97%enp0s3'
Reply | Threaded
Open this post in threaded view
|

Re: Trouble installing standalone VSM Dashboard for importing existing ceph cluster

bxzhu
hi maxstack,
        Did you use ipv6? Is it correct?
        And if possible, I suggest that you can use ipv4.
Reply | Threaded
Open this post in threaded view
|

Re: Trouble installing standalone VSM Dashboard for importing existing ceph cluster

bxzhu
In reply to this post by maxstack
BTW, can you post your cluster.manifest file?
Reply | Threaded
Open this post in threaded view
|

Re: Trouble installing standalone VSM Dashboard for importing existing ceph cluster

maxstack
Here is my cluster config, I took parts out because I only wanted to create a dashboard host - then add my test ceph cluster:

# cat manifest/10.0.1.20/cluster.manifest

[cluster]
cluster_a

[file_system]
xfs

[management_addr]
10.0.1.0/24

[ceph_public_addr]
10.0.1.0/24

[ceph_cluster_addr]
10.0.1.0/24

[settings]
storage_group_near_full_threshold  65
storage_group_full_threshold  85
ceph_near_full_threshold  75
ceph_full_threshold  90
pg_count_factor 100
heartbeat_interval 5
osd_heartbeat_interval 10
osd_heartbeat_grace 10
disk_near_full_threshold 75
disk_full_threshold 90
osd_pool_default_size 3

[ec_profiles]
#format: [profile-name] [path-to-plugin] [plugin-name] [pg_num value] [json format key/value]
#the key/value strings should not have spaces
default_profile  /usr/lib64/ceph/erasure-code  jerasure  3  {"k":2,"m":1,"technique":"reed_sol_van"}
#profile_name2  /usr/lib64/ceph/erasure-code  jerasure  6  {"k":4,"m":2,"technique":"reed_sol_van"}

[cache_tier_defaults]
ct_hit_set_count 1
ct_hit_set_period_s 3600
ct_target_max_mem_mb 1000000
ct_target_dirty_ratio 0.4
ct_target_full_ratio 0.8
ct_target_max_objects 1000000
ct_target_min_flush_age_m 10
ct_target_min_evict_age_m 20
Reply | Threaded
Open this post in threaded view
|

Re: Trouble installing standalone VSM Dashboard for importing existing ceph cluster

bxzhu
Did you set the mapping relation of ip(ipv4) and hostname in /etc/hosts file? See from the error, it checks the ipv6.
Reply | Threaded
Open this post in threaded view
|

Re: Trouble installing standalone VSM Dashboard for importing existing ceph cluster

maxstack
Ah I had nothing in my hosts file, this is now the contents of /etc/hosts:

127.0.0.1   localhost localhost.localdomain localhost4 localhost4.localdomain4
::1         localhost localhost.localdomain localhost6 localhost6.localdomain6

10.0.1.20       vsm-controller


And here is the result of ./install.sh -v 2.1 --controller 10.0.1.20 --prepare:

+ cluster_manifest
No handlers could be found for logger "vsm.manifest.parser"
Traceback (most recent call last):
  File "/usr/local/bin/cluster_manifest", line 240, in <module>
    smp = ManifestChecker(fpath)
  File "/usr/local/bin/cluster_manifest", line 43, in __init__
    self._info = self._smp.format_to_json()
  File "/usr/lib/python2.7/site-packages/vsm/manifest/parser.py", line 584, in format_to_json
    return self._format_cluster_manifest_to_json()
  File "/usr/lib/python2.7/site-packages/vsm/manifest/parser.py", line 565, in _format_cluster_manifest_to_json
    self._dict_insert_storage_class_c()
  File "/usr/lib/python2.7/site-packages/vsm/manifest/parser.py", line 433, in _dict_insert_storage_class_c
    raise
TypeError: exceptions must be old-style classes or derived from BaseException, not NoneType
Reply | Threaded
Open this post in threaded view
|

Re: Trouble installing standalone VSM Dashboard for importing existing ceph cluster

bxzhu
In reply to this post by maxstack
According to the info of your cluster.manifest, I think that you have removed all the storage_classes and storage_groups. The error's reason is that you should have one storage_class at least. So please fill into one storage_class and one storage_group at least.
Reply | Threaded
Open this post in threaded view
|

Re: Trouble installing standalone VSM Dashboard for importing existing ceph cluster

maxstack
Thanks, I recopied the sample cluster.manifest and then "./install.sh -v 2.1 --controller 10.0.1.20 -- prepare" finished, so i then ran "./install.sh -v 2.1 --controller 10.0.1.20" which started a load of services but there is no web page listening:

[root@vsm-controller 2.1.0-336]# netstat -alnp | grep 0.0.0.0
tcp        0      0 0.0.0.0:5000            0.0.0.0:*               LISTEN      5770/python
tcp        0      0 10.0.1.20:5673          0.0.0.0:*               LISTEN      5553/beam.smp
tcp        0      0 0.0.0.0:25673           0.0.0.0:*               LISTEN      5553/beam.smp
tcp        0      0 0.0.0.0:8778            0.0.0.0:*               LISTEN      6271/python
tcp        0      0 0.0.0.0:3306            0.0.0.0:*               LISTEN      3342/mysqld
tcp        0      0 0.0.0.0:4369            0.0.0.0:*               LISTEN      5568/epmd
tcp        0      0 0.0.0.0:22              0.0.0.0:*               LISTEN      5273/sshd
tcp        0      0 127.0.0.1:25            0.0.0.0:*               LISTEN      1698/master
tcp        0      0 0.0.0.0:35357           0.0.0.0:*               LISTEN      5770/python
Reply | Threaded
Open this post in threaded view
|

Re: Trouble installing standalone VSM Dashboard for importing existing ceph cluster

bxzhu
For ubuntu, you can check that "sudo service apache2 status" or "sudo netstate -alnp|grep 443". The port is 443.