<?xml version="1.0" encoding="utf-8"?>
<?xml-stylesheet type="text/xsl" href="../assets/xml/rss.xsl" media="all"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>openATTIC (Posts about ceph howto cluster deepsea)</title><link>/</link><description></description><atom:link href="https://openattic.org/categories/ceph-howto-cluster-deepsea.xml" rel="self" type="application/rss+xml"></atom:link><language>en</language><lastBuildDate>Thu, 22 Aug 2019 20:00:54 GMT</lastBuildDate><generator>Nikola (getnikola.com)</generator><docs>http://blogs.law.harvard.edu/tech/rss</docs><item><title>Create a Ceph Cluster with DeepSea</title><link>https://openattic.org/posts/create-ceph-cluster-with-deepsea/</link><dc:creator>Kai Wagner</dc:creator><description>&lt;div&gt;&lt;p&gt;How to setup a ceph cluster with DeepSea on top of SUSE Leap VMs.&lt;/p&gt;
&lt;ol class="arabic"&gt;
&lt;li&gt;&lt;p class="first"&gt;Install three VMs and configure &lt;cite&gt;"/etc/hosts"&lt;/cite&gt; -&amp;gt; easiest way to do is to add all nodes in &lt;cite&gt;"/etc/hosts"&lt;/cite&gt; on all VMs. Make sure FQDN are set, too&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;&lt;p class="first"&gt;Install &lt;cite&gt;"salt-master"&lt;/cite&gt; on one VM &lt;cite&gt;"zypper in salt-master"&lt;/cite&gt;. Enable the service: &lt;cite&gt;"systemctl enable salt-master"&lt;/cite&gt;&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;&lt;p class="first"&gt;Install &lt;cite&gt;"salt-minion"&lt;/cite&gt; on ALL VMs &lt;cite&gt;"zypper in salt-minion"&lt;/cite&gt;. Enable the service: &lt;cite&gt;"systemctl enable salt-minion"&lt;/cite&gt;&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;&lt;p class="first"&gt;Configure &lt;cite&gt;"/etc/salt/minion"&lt;/cite&gt; on all systems to point to the right master and restart minions &lt;cite&gt;"systemctl restart salt-minion"&lt;/cite&gt;&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;&lt;p class="first"&gt;Accept keys on the salt-master &lt;cite&gt;"salt-key -A -y"&lt;/cite&gt;&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;&lt;p class="first"&gt;Install the build tools on the salt-master VM &lt;cite&gt;"zypper in git make"&lt;/cite&gt;&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;&lt;p class="first"&gt;Clone the DeepSea repo &lt;cite&gt;"git clone https://github.com/SUSE/DeepSea.git"&lt;/cite&gt; on the salt-master VM&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;&lt;p class="first"&gt;Inside the DeepSea folder run &lt;cite&gt;"make install"&lt;/cite&gt;&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;&lt;p class="first"&gt;On the salt master run &lt;cite&gt;"systemctl restart salt-master"&lt;/cite&gt;&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;&lt;p class="first"&gt;Run &lt;cite&gt;"chown -R salt /srv/pillar/*"&lt;/cite&gt;&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;&lt;p class="first"&gt;Run &lt;cite&gt;"salt-run state.orch ceph.stage.0"&lt;/cite&gt; or &lt;cite&gt;"salt-run state.orch ceph.stage.prep"&lt;/cite&gt;&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;&lt;p class="first"&gt;Run &lt;cite&gt;"salt-run state.orch ceph.stage.1"&lt;/cite&gt; or &lt;cite&gt;"salt-run state.orch ceph.stage.discovery"&lt;/cite&gt;&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;&lt;p class="first"&gt;Create &lt;cite&gt;"/srv/pillar/ceph/proposals/policy.cfg"&lt;/cite&gt; and run &lt;cite&gt;"chown salt:salt /srv/pillar/ceph/proposals/policy.cfg"&lt;/cite&gt;. Example:&lt;/p&gt;
&lt;pre class="literal-block"&gt;
# Cluster assignment
cluster-ceph/cluster/*.sls
# Hardware Profile
profile-*-1/cluster/*.sls
profile-*-1/stack/default/ceph/minions/*yml
# Common configuration
config/stack/default/global.yml
config/stack/default/ceph/cluster.yml
# Role assignment
role-master/cluster/*.sls
role-mon/cluster/*.sls
role-mon/stack/default/ceph/minions/*.yml
&lt;/pre&gt;
&lt;/li&gt;
&lt;li&gt;&lt;p class="first"&gt;Run &lt;cite&gt;"salt-run state.orch ceph.stage.2"&lt;/cite&gt; or &lt;cite&gt;"salt-run state.orch ceph.stage.configure"&lt;/cite&gt;&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;&lt;p class="first"&gt;Run &lt;cite&gt;"DEV_ENV=true salt-run state.orch ceph.stage.3"&lt;/cite&gt; or &lt;cite&gt;"DEV_ENV=true salt-run state.orch ceph.stage.deploy"&lt;/cite&gt; -&amp;gt; "DEV_ENV is only needed if you have &amp;lt;=3 VMs"&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;&lt;p class="first"&gt;You should change the pg(p)_num to get rid of the "to few pgs per osd" error &lt;cite&gt;"ceph osd pool set rbd pg_num 120"&lt;/cite&gt; and &lt;cite&gt;"ceph osd pool set rbd pgp_num 120"&lt;/cite&gt;&lt;/p&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;You now should have an up and running cluster.&lt;/p&gt;
&lt;p&gt;Now you could add the openATTIC OBS (openSUSE Build Service) repo and install openATTIC and the openattic-deployment package&lt;/p&gt;
&lt;ol class="arabic simple" start="17"&gt;
&lt;li&gt;Add the needed Repo from OBS &lt;cite&gt;"zypper ar http://download.opensuse.org/repositories/filesystems:/openATTIC/openSUSE_Leap_42.2/filesystems:openATTIC.repo"&lt;/cite&gt;&lt;/li&gt;
&lt;li&gt;Install openATTIC &lt;cite&gt;"zypper in openattic openattic-module-ceph-deployment"&lt;/cite&gt; -&amp;gt; you have to break dependencies because deepsea isn't shipped with leap by default&lt;/li&gt;
&lt;li&gt;Run &lt;cite&gt;"chmod 655 /etc/ceph/ceph.*"&lt;/cite&gt;&lt;/li&gt;
&lt;li&gt;Run &lt;cite&gt;"openattic install"&lt;/cite&gt;&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;You're done :)&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Update 2017-04-07&lt;/strong&gt;&lt;/p&gt;
&lt;ul class="simple"&gt;
&lt;li&gt;Fixed some typos and added some more steps to do.&lt;/li&gt;
&lt;/ul&gt;&lt;/div&gt;</description><category>ceph howto cluster deepsea</category><guid>https://openattic.org/posts/create-ceph-cluster-with-deepsea/</guid><pubDate>Tue, 21 Feb 2017 08:45:47 GMT</pubDate></item></channel></rss>