Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

os/bluestore/NVMEDevice: add the spdk core mask check #14068

Merged
merged 1 commit into from Mar 22, 2017

Conversation

optimistyzy
Copy link
Contributor

This patch adds the spdk core mask check and also
set the master core for starting DPDK.

Signed-off-by: optimistyzy optimistyzy@gmail.com


if (sn_tag.empty()) {
r = -ENOENT;
derr << __func__ << " empty serial number: " << cpp_strerror(r) << dendl;
return r;
}

core_value = strtoll(g_conf->bluestore_spdk_coremask.c_str(), NULL, 16);
for (int i = 0; i < 64; i++) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"64" meaning?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@yuyuyu101 I updated this code, it used to check the each bit in core_value.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@yuyuyu101 I updated this code, it used to check the each bit in core_value.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@yuyuyu101 I updated this code, it used to check the each bit in core_value.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@yuyuyu101 I updated this code, it used to check the each bit in core_value.

@optimistyzy
Copy link
Contributor Author

@yuyuyu101 I updated this code, it used to check each bit in core_value.

@tangwenjun3
Copy link
Contributor

this patch tested and worked well in my ceph,and solve the issues ( http://tracker.ceph.com/issues/19093)
succeed to deploy multiple SPDK blueStore OSD instances per node。

my osd config is that:
[osd.0]
host = 127.0.0.1
osd data = /data/osd/osd.0
bluestore_block_path = spdk:55cd2e404c7e1063
bluestore_spdk_socket_mem = 512,512
bluestore_spdk_coremask = 0x3 #0、1 core

[osd.1]
host = 127.0.0.1
osd data = /data/osd/osd.1
bluestore_block_path = spdk:55cd2e404bde228b
bluestore_spdk_socket_mem = 512,512
bluestore_spdk_coremask = 0XC00000 # 22、23 core

// at least two cores are needed for using spdk
if (core_num < 2) {
r = -ENOENT;
derr << __func__ << " invalid spdk coremask: " << cpp_strerror(r) << dendl;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

suggest explicitly tell the reason like at least two cores needed

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

updated.

This patch adds the spdk core mask check and also
set the master core for starting DPDK.

Signed-off-by: optimistyzy <optimistyzy@gmail.com>
@optimistyzy
Copy link
Contributor Author

updated with suggested comments. @yuyuyu101

@yuyuyu101 yuyuyu101 changed the title Bluestore, NVMEDevice: add the spdk core mask check os/bluestore/NVMEDevice: add the spdk core mask check Mar 22, 2017
@yuyuyu101 yuyuyu101 merged commit 6962b0d into ceph:master Mar 22, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
3 participants