@tony-yin
        
        2017-08-20T08:44:37.000000Z
        字数 1511
        阅读 1105
    Magicloud
stop_ezs3_service: stop_ezs3_servicestop osddisable osd
load config: /etc/mcs3/storage.conf (存储卷的配置信息,即osd的配置信息)service ganglia-monitor stop' returns 'Stopping Ganglia Monitor Daemon: gmond.get osd id by osd namestop osd ezs3-ha service_ceph stop osd0kill -9 xxxceph osd down 0, ceph osd out 0, ceph osd rm 0disable osdumount:
mount_point = "/data/osd.{}".format(self.get_osd_id())if os.path.ismount(mount_point):umount -f -l /data/osd.0 ?
sed -i '\@/data/osd.0@d' /etc/fstab
delete part_map
set partition mapcl.node_management.osd_disabledprepare enable osd
set public interace,cluster interface(if cluster interface is true) and save in ceph.conf (osd, interface等信息存放文件:/etc/ceph/ceph.conf)consolidate_raid_configure /opt/MegaRAID/MegaCli/MegaCli64 -AdpBbuCMD -Aall |grep Exit |tr -d "\n"a series of megaci command记录osd的状态: role.set(OSD, RoleState.ENABLING)
enable osd (@monlock ?)
update task info (有空看下代码,如何实现ajax轮询的)get_partition_map:
try:kvstore.get('partition_map', timeout, timeout!=0)catch:rados -p .ezs3 get partition_map -
stop ezs3 service
创建桶节点并且建立link:
if not host_osd_enabled:ceph osd crush add-bucket {} host".format(crush_host_bucket)ceph osd crush link {} pool=default".format(crush_host_bucket)
service ganglia-monitor stop
StorageVolume
enable_osd ceph osd createmount: mount -o noatime,user_xattr /dev/disk/by-partlabel/osd1-data /data/osd.0add osd and saveceph mon getmap -o /tmp/monmap (二进制文件)ceph-osd -i {osd_id} --monmap /tmp/monmap --mkfs --mkjournalstart osd:
ezs3-ha service_ceph start osd0
ceph osd crush add {osd_id} 0 pool=default host={crush_host_bucket}
set osd uuid and osd post  stop command