Commit c37d578c authored by Cyril Rohr's avatar Cyril Rohr
Browse files

added generators

parent ec843a39
{
"type": "grid",
"uid": "grid5000"
}
\ No newline at end of file
require 'pp'
require 'rubygems'
require 'fileutils'
require 'json'
require 'time'
require File.dirname(__FILE__)+'/lib/core_extensions'
require File.dirname(__FILE__)+'/lib/g5k_generator'
usage = %{
A tool to generate the Grid5000 reference data.
Usage:
ruby grid5000.rb [input files] [options]
Options:
-s : simulation mode
}
# true if we want to simulate, else false.
simulation_mode = !$*.delete("-s").nil?
if $*.empty?
puts usage
elsif ($*.map{|file| File.exists?(file) && File.extname(file) == ".rb"}.include? false)
puts "Error: your input files do not exist or are not ruby files (.rb extension)."
else
description_files = $*
puts "[Input files:\t\t #{description_files.join(", ")}]"
puts "[Simulation mode:\t #{simulation_mode}]"
generator = G5K::ReferenceGenerator.new({:uid => "grid5000", :type => "grid"}, *description_files)
data = generator.generate
generator.write('../data', :simulate => simulation_mode)
end
\ No newline at end of file
# SITES = %{bordeaux grenoble lille lyon nancy orsay rennes sophia toulouse}
environment 'sid-x64-base-1.0' do
state "stable"
file({:path => "/home/nancy/xdelaruelle/images/sid-x64-base-1.0.tgz", :md5 => "e39be32c087f0c9777fd0b0ad7d12050"})
valid_on "Dell PE1855, Dell PE1950, HP DL140G3, HP DL145G2, IBM e325, IBM e326, IBM e326m, Sun V20z, Sun X2200 M2, Sun X4100".split(", ")
kernel "2.6.18-8"
based_on "Debian version sid for amd64"
consoles [{:port => "ttyS0", :bps => 34800}]
services []
accounts [{:login => "root", :password => "grid5000"}, {:login => "g5k", :password => "grid5000"}]
applications "Vim, XEmacs, JED, nano, JOE, Perl, Python, Ruby".split(", ")
x11_forwarding true
max_open_files 8192
tcp_bandwidth 1.giga
end
\ No newline at end of file
site :grenoble do
name "Grenoble"
location "Grenoble, France"
web
description ""
latitude
longitude
email_contact
sys_admin_contact
security_contact
user_support_contact
%w{sid-x64-base-1.0}.each{|env_uid| environment env_uid, :refer_to => "grid5000/environments/#{env_uid}"}
cluster :genepi do
model "Bull R422-E1"
date_of_arrival Time.parse("2008-10-01").to_i
34.times do |i|
node "genepi-#{i+1}" do
architecture({
:smp_size => 2,
:smt_size => 8,
:platform_type => "x86_64"
})
processor({
:vendor => "Intel",
:model => "Intel Xeon",
:version => "E5420 QC",
:clock_speed => 2.5.giga,
:instruction_set => "",
:other_description => "",
:cache_l1 => nil,
:cache_l1i => nil,
:cache_l1d => nil,
:cache_l2 => nil
})
main_memory({
:ram_size => 8.GB(true), # bytes
:virtual_size => nil
})
operating_system({
:name => nil,
:release => nil,
:version => nil
})
storage_devices [
{:interface => 'SATA', :size => 160.GB(false), :driver => nil}
]
network_adapters [
]
end
end
end
end
\ No newline at end of file
site :orsay do
name "Orsay"
location "Orsay, France"
web
description ""
latitude
longitude
email_contact
sys_admin_contact
security_contact
user_support_contact
%w{sid-x64-base-1.0}.each{|env_uid| environment env_uid, :refer_to => "grid5000/environments/#{env_uid}"}
cluster :netgdx do
model "IBM eServer 326m"
date_of_arrival nil
misc "bios:1.28/bcm:1.20.17/bmc:1.10/rsaII:1.00"
30.times do |i|
node "netgdx-#{i+1}" do
architecture({
:smp_size => 2,
:smt_size => 2,
:platform_type => "x86_64"
})
processor({
:vendor => "AMD",
:model => "AMD Opteron",
:version => "246",
:clock_speed => 2.giga,
:instruction_set => "",
:other_description => "",
:cache_l1 => 1.MB,
:cache_l1i => nil,
:cache_l1d => nil,
:cache_l2 => nil
})
main_memory({
:ram_size => 2.GB(true), # bytes
:virtual_size => nil
})
operating_system({
:name => nil,
:release => nil,
:version => nil
})
storage_devices [
{:interface => 'SATA', :size => 80.GB(false), :driver => nil}
]
network_adapters [
{:interface => 'Ethernet', :rate => 1.giga, :enabled => true, :driver => nil},
{:interface => 'Ethernet', :rate => 1.giga, :enabled => true, :driver => nil},
{:interface => 'Ethernet', :rate => 1.giga, :enabled => true, :driver => nil}
]
end
end
end # cluster net-gdx
cluster :gdx do
model "IBM eServer 326m"
date_of_arrival nil
misc "bios:1.28/bcm:1.20.17/bmc:1.10/rsaII:1.00"
(186+126).times do |i|
node "gdx-#{i+1}" do
architecture({
:smp_size => 2,
:smt_size => 2,
:platform_type => "x86_64"
})
processor({
:vendor => "AMD",
:model => "AMD Opteron",
:version => "246",
:clock_speed => 2.giga,
:instruction_set => "",
:other_description => "",
:cache_l1 => 1.MB,
:cache_l1i => nil,
:cache_l1d => nil,
:cache_l2 => nil
})
main_memory({
:ram_size => 2.GB(true), # bytes
:virtual_size => nil
})
operating_system({
:name => nil,
:release => nil,
:version => nil
})
storage_devices [
{:interface => 'SATA', :size => 80.GB(false), :driver => nil}
]
network_adapters [
{:interface => 'Ethernet', :rate => 1.giga, :enabled => true},
{:interface => 'Ethernet', :rate => 1.giga, :enabled => false},
{:interface => 'Myri-10G', :rate => 10.giga, :enabled => true, :vendor => "Myrinet", :version => "10G-PCIE-8A-C"}
]
end
end
# extension specifics, starting at node 187
126.times do |i|
node "gdx-#{186+i+1}" do
processor({
:version => "250",
:clock_speed => 2.4.giga
})
end
end
end # cluster gdx
end
\ No newline at end of file
site :rennes do
name "Rennes"
location "Rennes, France"
web "http://www.irisa.fr"
description ""
latitude 48.114722
longitude -1.679444
email_contact
sys_admin_contact
security_contact
user_support_contact
%w{sid-x64-base-1.0}.each do |env_id|
environment env_id, :refer_to => "grid5000/environments/#{env_id}"
end
cluster :paravent do
model "HP ProLiant DL145G2"
created_at nil
99.times do |i|
node "paravent-#{i+1}" do
architecture({
:smp_size => 2,
:smt_size => 2,
:platform_type => "x86_64"
})
processor({
:vendor => "AMD",
:model => "AMD Opteron",
:version => "246",
:clock_speed => 2.giga,
:instruction_set => "",
:other_description => "",
:cache_l1 => nil,
:cache_l1i => nil,
:cache_l1d => nil,
:cache_l2 => nil
})
main_memory({
:ram_size => 2.GB(true), # bytes
:virtual_size => nil
})
operating_system({
:name => nil,
:release => nil,
:version => nil
})
storage_devices [
{:interface => 'SATA', :size => 80.GB(false), :driver => "sata_nv"}
]
network_adapters [
{:interface => 'InfiniBand 10G', :rate => 10.giga, :vendor => "InfiniHost", :version => "MT23108", :enabled => true},
{:interface => 'Ethernet', :rate => 1.giga, :enabled => true},
{:interface => 'Ethernet', :rate => 1.giga, :enabled => false}
]
end
end
end
cluster :paramount do
model "Dell PowerEdge 1950"
created_at Time.parse("2007-09-01").to_i
33.times do |i|
node "paramount-#{i+1}" do
architecture({
:smp_size => 2,
:smt_size => 4,
:platform_type => "x86_64"
})
processor({
:vendor => "Intel",
:model => "Intel Xeon",
:version => "5148 LV",
:clock_speed => 2.33.giga,
:instruction_set => "",
:other_description => "",
:cache_l1 => nil,
:cache_l1i => nil,
:cache_l1d => nil,
:cache_l2 => nil
})
main_memory({
:ram_size => 8.GB(true), # bytes
:virtual_size => nil
})
operating_system({
:name => nil,
:release => nil,
:version => nil
})
storage_devices [
{:interface => 'SATA', :size => 300.GB(false), :driver => "megaraid_sas", :raid => "0"},
{:interface => 'SATA', :size => 300.GB(false), :driver => "megaraid_sas", :raid => "0"}
]
network_adapters [
{:interface => 'Myri-10G', :rate => 10.giga, :vendor => 'Myrinet', :version => "10G-PCIE-8A-C", :enabled => true},
{:interface => 'Ethernet', :rate => 1.giga, :enabled => true},
{:interface => 'Ethernet', :rate => 1.giga, :enabled => false}
]
end
end
end
cluster(:paraquad) do
model "Dell PowerEdge 1950"
created_at Time.parse("2006-12-01").to_i
64.times do |i|
node "paraquad-#{i+1}" do
architecture({
:smp_size => 2,
:smt_size => 4,
:platform_type => "x86_64"
})
processor({
:vendor => "Intel",
:model => "Intel Xeon",
:version => "5148 LV",
:clock_speed => 2.33.giga,
:instruction_set => "",
:other_description => "",
:cache_l1 => nil,
:cache_l1i => nil,
:cache_l1d => nil,
:cache_l2 => nil
})
main_memory({
:ram_size => 4.GB(true), # bytes
:virtual_size => nil
})
operating_system({
:name => nil,
:release => nil,
:version => nil
})
storage_devices [
{:interface => 'SATA', :size => 160.GB(false), :driver => "mptsas"}
]
network_adapters [
{:interface => 'Myri-10G', :rate => 10.giga, :vendor => 'Myrinet', :version => "10G-PCIE-8A-C", :enabled => true},
{:interface => 'Ethernet', :rate => 1.giga, :enabled => true},
{:interface => 'Ethernet', :rate => 1.giga, :enabled => false}
]
end
end
end
end
\ No newline at end of file
site :sophia do
name "Sophia-Antipolis"
location "Sophia-Antipolis, France"
web
description ""
latitude
longitude
email_contact
sys_admin_contact
security_contact
user_support_contact
%w{sid-x64-base-1.0}.each do |env_id|
environment env_id, :refer_to => "grid5000/environments/#{env_id}"
end
cluster :azur do
model "IBM eServer 325"
created_at Time.parse("2005-02-18").to_i
72.times do |i|
node "azur-#{i+1}" do
architecture({
:smp_size => 2,
:smt_size => 2,
:platform_type => "x86_64"
})
processor({
:vendor => "AMD",
:model => "AMD Opteron",
:version => "246",
:clock_speed => 2.giga,
:instruction_set => "",
:other_description => "",
:cache_l1 => 1.MB,
:cache_l1i => nil,
:cache_l1d => nil,
:cache_l2 => nil
})
main_memory({
:ram_size => 2.GB(true), # bytes
:virtual_size => nil
})
operating_system({
:name => nil,
:release => nil,
:version => nil
})
storage_devices [
{:interface => 'IDE', :size => 80.GB(false), :driver => "amd74xx"}
]
network_adapters []
end
end
end
cluster :helios do
model "Sun Fire X4100"
created_at Time.parse("2006-06-02").to_i
56.times do |i|
node "helios-#{i+1}" do
architecture({
:smp_size => 2,
:smt_size => 4,
:platform_type => "x86_64"
})
processor({
:vendor => "AMD",
:model => "AMD Opteron",
:version => "275",
:clock_speed => 2.2.giga,
:instruction_set => "",
:other_description => "",
:cache_l1 => 1.MB,
:cache_l1i => nil,
:cache_l1d => nil,
:cache_l2 => nil
})
main_memory({
:ram_size => 4.GB(true), # bytes
:virtual_size => nil
})
operating_system({
:name => nil,
:release => nil,
:version => nil
})
storage_devices [
{:interface => 'SAS', :size => 73.GB(false), :driver => "mptsas", :raid => "0"},
{:interface => 'SAS', :size => 73.GB(false), :driver => "mptsas", :raid => "0"}
]
network_adapters []
end
end
end
cluster :sol do
model "Sun Fire X2200 M2"
created_at Time.parse("2007-02-23").to_i
50.times do |i|
node "sol-#{i+1}" do
architecture({
:smp_size => 2,
:smt_size => 4,
:platform_type => "x86_64"
})
processor({
:vendor => "AMD",
:model => "AMD Opteron",
:version => "2218",
:clock_speed => 2.6.giga,
:instruction_set => "",
:other_description => "",
:cache_l1 => 1.MB,
:cache_l1i => nil,
:cache_l1d => nil,
:cache_l2 => nil
})
main_memory({
:ram_size => 4.GB(true), # bytes
:virtual_size => nil
})
operating_system({
:name => nil,
:release => nil,
:version => nil
})
storage_devices [
{:interface => 'SATA', :size => 250.GB(false), :driver => "sata_nv"}
]
network_adapters [
{:interface => 'Ethernet', :rate => 1.giga, :enabled => true, :vendor => "NVIDIA", :version => "MCP55 Pro"},
{:interface => 'Ethernet', :rate => 1.giga, :enabled => true, :vendor => "NVIDIA", :version => "MCP55 Pro"},
{:interface => 'Ethernet', :rate => 1.giga, :enabled => false, :vendor => "Broadcom", :version => "BCM5715c"},
{:interface => 'Ethernet', :rate => 1.giga, :enabled => false, :vendor => "Broadcom", :version => "BCM5715c"}
]
end
end
end
#
# cluster :storage do
# model "Sun X4100"
# node "storage-1" do
# architecture({
# :smp_size => 2,
# :smt_size => 2,
# :platform_type => ""
# })
# processor({
# :vendor => "AMD",
# :model => "AMD Opteron",
# :version => "275",
# :clock_speed => 2.2.giga,
# :instruction_set => "",
# :other_description => "",
# :cache_l1 => nil,
# :cache_l1i => nil,
# :cache_l1d => nil,
# :cache_l2 => nil
# })
# main_memory({
# :ram_size => 4.GB(true), # bytes
# :virtual_size => nil
# })
# operating_system({
# :name => nil,
# :release => nil,
# :version => nil
# })
# storage_devices [
# {:interface => 'SAS', :size => 73.GB(false), :rpm => 10_000, :raid => "1 'Mirroring'"},
# {:interface => 'SATA II', :size => 2.TB(false), :raid => "5", :name => "Sun StorEdge 3511 FC Array"}
# ]
# network_adapters [
# {:interface => 'Ethernet', :rate => 1.giga, :enabled => true, :vendor => "Intel", :version => "e1000"},
# {:interface => 'Ethernet', :rate => 1.giga, :enabled => true, :vendor => "Intel", :version => "e1000"},
# {:interface => 'Ethernet', :rate => 1.giga, :enabled => true, :vendor => "Intel", :version => "e1000"},
# {:interface => 'Ethernet', :rate => 1.giga, :enabled => true, :vendor => "Intel", :version => "e1000"},
# {:interface => 'Fibre Channel', :rate => 2.giga, :enabled => true, :vendor => "QLogic", :version => "QLA2342"}
# ]
# end
# end
end
\ No newline at end of file
site :toulouse do
name "Toulouse"
location "Toulouse, France"
web
description ""
latitude
longitude
email_contact
sys_admin_contact
security_contact
user_support_contact
%w{sid-x64-base-1.0}.each{|env_uid| environment env_uid, :refer_to => "grid5000/environments/#{env_uid}"}
cluster :violette do
model "Sun Fire V20z"
date_of_arrival Time.parse("2004-09-01").to_i
57.times do |i|
node "violette-#{i+1}" do
architecture({
:smp_size => 2,
:smt_size => 2,
:platform_type => "x86_64"
})
processor({
:vendor => "AMD",
:model => "AMD Opteron",
:version => "248",
:clock_speed => 2.2.giga,
:instruction_set => "",
:other_description => "",
:cache_l1 => nil,
:cache_l1i => nil,
:cache_l1d => nil,
:cache_l2 => nil
})
main_memory({
:ram_size => 2.GB(true), # bytes
:virtual_size => nil
})
operating_system({
:name => nil,
:release => nil,
:version => nil
})
storage_devices [
{:interface => 'SCSI', :size => 73.GB(false), :driver => "mptspi"}
]
network_adapters [
{:interface => 'Ethernet', :rate => 1.giga, :enabled => true, :driver => "tg3"},
{:interface => 'Ethernet', :rate => 1.giga, :enabled => false, :driver => "tg3"}
]
end
end
end
cluster :pastel do
model "Sun Fire X2200 M2"