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

Fix for bug #6700 #1948

Merged
merged 1 commit into from Jun 12, 2014
Merged

Fix for bug #6700 #1948

merged 1 commit into from Jun 12, 2014

Conversation

steveftaylor
Copy link
Contributor

When preparing OSD disks with colocated journals, the intialization process
fails when using dmcrypt. The kernel fails to re-read the partition table after
the storage partition is created because the journal partition is already in use
by dmcrypt. This fix unmaps the journal partition from dmcrypt and allows the
partition table to be read.

Signed-off-by: Stephen F Taylor steveftaylor@gmail.com

When preparing OSD disks with colocated journals, the intialization process
fails when using dmcrypt. The kernel fails to re-read the partition table after
the storage partition is created because the journal partition is already in use
by dmcrypt. This fix unmaps the journal partition from dmcrypt and allows the
partition table to be read.

Signed-off-by: Stephen F Taylor <steveftaylor@gmail.com>
@alfredodeza
Copy link
Contributor

This patch totally works for me. After attempting to get dmcrypt working (and failing) I applied this and things started working perfectly:

ceph-deploy osd create --dmcrypt node1:sdb
[ceph_deploy.conf][DEBUG ] found configuration file at: /Users/alfredo/.cephdeploy.conf
[ceph_deploy.cli][INFO  ] Invoked (1.5.4): /Users/alfredo/.virtualenvs/ceph-deploy/bin/ceph-deploy osd create --dmcrypt node1:sdb
[ceph_deploy.osd][DEBUG ] Preparing cluster ceph disks node1:/dev/sdb:
[node1][DEBUG ] connected to host: node1
[node1][DEBUG ] detect platform information from remote host
[node1][DEBUG ] detect machine type
[ceph_deploy.osd][INFO  ] Distro info: Ubuntu 12.04 precise
[ceph_deploy.osd][DEBUG ] Deploying osd to node1
[node1][DEBUG ] write cluster configuration to /etc/ceph/{cluster}.conf
[node1][INFO  ] Running command: sudo udevadm trigger --subsystem-match=block --action=add
[ceph_deploy.osd][DEBUG ] Preparing host node1 disk /dev/sdb journal None activate True
[node1][INFO  ] Running command: sudo ceph-disk-prepare --fs-type xfs --dmcrypt --dmcrypt-key-dir /etc/ceph/dmcrypt-keys --cluster ceph -- /dev/sdb
[node1][DEBUG ] Information: Moved requested sector from 34 to 2048 in
[node1][DEBUG ] order to align on 2048-sector boundaries.
[node1][DEBUG ] The operation has completed successfully.
[node1][DEBUG ] Information: Moved requested sector from 10485761 to 10487808 in
[node1][DEBUG ] order to align on 2048-sector boundaries.
[node1][DEBUG ] The operation has completed successfully.
[node1][DEBUG ] meta-data=/dev/mapper/376b7b97-07cc-4e37-ace1-85bdbcd0708f isize=2048   agcount=4, agsize=196543 blks
[node1][DEBUG ]          =                       sectsz=512   attr=2, projid32bit=0
[node1][DEBUG ] data     =                       bsize=4096   blocks=786171, imaxpct=25
[node1][DEBUG ]          =                       sunit=0      swidth=0 blks
[node1][DEBUG ] naming   =version 2              bsize=4096   ascii-ci=0
[node1][DEBUG ] log      =internal log           bsize=4096   blocks=2560, version=2
[node1][DEBUG ]          =                       sectsz=512   sunit=0 blks, lazy-count=1
[node1][DEBUG ] realtime =none                   extsz=4096   blocks=0, rtextents=0
[node1][DEBUG ] The operation has completed successfully.
[node1][WARNIN] INFO:ceph-disk:Will colocate journal with data on /dev/sdb
[node1][INFO  ] Running command: sudo udevadm trigger --subsystem-match=block --action=add
[node1][INFO  ] checking OSD status...
[node1][INFO  ] Running command: sudo ceph --cluster=ceph osd stat --format=json
[ceph_deploy.osd][DEBUG ] Host node1 is now ready for osd use.

alfredodeza added a commit that referenced this pull request Jun 12, 2014
Fix for bug #6700

Reviewed-by: Alfredo Deza <alfredo.deza@inktank.com>
@alfredodeza alfredodeza merged commit 87650d4 into ceph:master Jun 12, 2014
@steveftaylor steveftaylor deleted the 6700 branch June 12, 2014 14:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants