Re: mkfs and mdadm support


Chronological Thread 
  • From: Miguel Cabeça <cabeca@ist.utl.pt>
  • To: chef@lists.opscode.com
  • Subject: Re: mkfs and mdadm support
  • Date: Wed, 24 Jun 2009 12:22:32 +0100

Hello all,


Filesystem provider:

file_system "/dev/sde" do
  device '/dev/sde'
  partitions [
{'number' => 2, 'type' => 'raid', 'start' => '5GB', 'end' => '10GB'},
{'number' => 1, 'type' => 'raid', 'start' => '0GB', 'end' => '5GB'}
  ]
  action :partition
end


Having the partition stuff on the file_system resource doesn't seem right. On the other hand where should it go? To a Partition resource like this?

partition '/dev/sda' do
  device '/dev/sda'
  table 'GPT'
partitions [ {:type => :raid , :start => '0GB' , :end => '5GB'} , {:type => :raid , :start => '5GB' , :end => '10GB'} ]
  action :partition
end

partition '/dev/sda' do
  device '/dev/sda'
  table 'MBR'
partitions [ {:type => 82 , :start => '0GB' , :end => '2GB'} , {:type => 83 , :start => '2GB' , :end => :remaining} ]
  action :partition
end


The file_system and raid resource are looking pretty good.

Best Regards

Miguel Cabeça




Archive powered by MHonArc 2.6.16.

§