Mentions légales du service
Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
R
reference-repository
Manage
Activity
Members
Labels
Plan
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
grid5000
reference-repository
Commits
55638816
Commit
55638816
authored
16 years ago
by
Cyril Rohr
Browse files
Options
Downloads
Patches
Plain Diff
trying to use the dns_lookup feature
parent
fe4120f9
No related branches found
No related tags found
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
generators/grid5000.rb
+2
-1
2 additions, 1 deletion
generators/grid5000.rb
generators/input/rennes.rb
+13
-7
13 additions, 7 deletions
generators/input/rennes.rb
generators/lib/g5k_generator.rb
+7
-1
7 additions, 1 deletion
generators/lib/g5k_generator.rb
with
22 additions
and
9 deletions
generators/grid5000.rb
+
2
−
1
View file @
55638816
...
...
@@ -16,8 +16,9 @@ usage = %{
}
# true if we want to simulate
, else false.
# true if we want to simulate
:
simulation_mode
=
!
$*
.
delete
(
"-s"
).
nil?
if
$*
.
empty?
puts
usage
exit
-
1
...
...
This diff is collapsed.
Click to expand it.
generators/input/rennes.rb
+
13
−
7
View file @
55638816
site
:rennes
do
site
:rennes
do
|
site_uid
|
name
"Rennes"
location
"Rennes, France"
web
"http://www.irisa.fr"
...
...
@@ -17,7 +17,7 @@ site :rennes do
model
"HP ProLiant DL145G2"
created_at
nil
99
.
times
do
|
i
|
node
"paravent-
#{
i
+
1
}
"
do
node
"paravent-
#{
i
+
1
}
"
do
|
node_uid
|
architecture
({
:smp_size
=>
2
,
:smt_size
=>
2
,
...
...
@@ -48,7 +48,9 @@ site :rennes do
{
:interface
=>
'SATA'
,
:size
=>
80
.
GB
(
false
),
:driver
=>
"sata_nv"
}
]
network_adapters
[
{
:interface
=>
'InfiniBand 10G'
,
:rate
=>
10
.
giga
,
:vendor
=>
"InfiniHost"
,
:version
=>
"MT23108"
,
:enabled
=>
true
},
{
:interface
=>
'InfiniBand 10G'
,
:rate
=>
10
.
giga
,
:switch
=>
"c6509-grid"
,
:network_address
=>
"
#{
node_uid
}
.
#{
site_uid
}
.grid5000.fr"
,
:ip
=>
dns_lookup
(
"
#{
node_uid
}
.
#{
site_uid
}
.grid5000.fr"
),
:vendor
=>
"InfiniHost"
,
:version
=>
"MT23108"
,
:enabled
=>
true
},
{
:interface
=>
'Ethernet'
,
:rate
=>
1
.
giga
,
:enabled
=>
true
},
{
:interface
=>
'Ethernet'
,
:rate
=>
1
.
giga
,
:enabled
=>
false
}
]
...
...
@@ -60,7 +62,7 @@ site :rennes do
model
"Dell PowerEdge 1950"
created_at
Time
.
parse
(
"2007-09-01"
).
httpdate
33
.
times
do
|
i
|
node
"paramount-
#{
i
+
1
}
"
do
node
"paramount-
#{
i
+
1
}
"
do
|
node_uid
|
architecture
({
:smp_size
=>
2
,
:smt_size
=>
4
,
...
...
@@ -93,7 +95,9 @@ site :rennes do
{
: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
=>
'Myri-10G'
,
:rate
=>
10
.
giga
,
:switch
=>
"c6509-grid"
,
:network_address
=>
"
#{
node_uid
}
.
#{
site_uid
}
.grid5000.fr"
,
:ip
=>
dns_lookup
(
"
#{
node_uid
}
.
#{
site_uid
}
.grid5000.fr"
),
:vendor
=>
'Myrinet'
,
:version
=>
"10G-PCIE-8A-C"
,
:enabled
=>
true
},
{
:interface
=>
'Ethernet'
,
:rate
=>
1
.
giga
,
:enabled
=>
true
},
{
:interface
=>
'Ethernet'
,
:rate
=>
1
.
giga
,
:enabled
=>
false
}
]
...
...
@@ -106,7 +110,7 @@ site :rennes do
created_at
Time
.
parse
(
"2006-12-01"
).
httpdate
64
.
times
do
|
i
|
node
"paraquad-
#{
i
+
1
}
"
do
node
"paraquad-
#{
i
+
1
}
"
do
|
node_uid
|
architecture
({
:smp_size
=>
2
,
:smt_size
=>
4
,
...
...
@@ -137,7 +141,9 @@ site :rennes do
{
: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
=>
'Myri-10G'
,
:rate
=>
10
.
giga
,
:switch
=>
"c6509-grid"
,
:network_address
=>
"
#{
node_uid
}
.
#{
site_uid
}
.grid5000.fr"
,
:ip
=>
dns_lookup
(
"
#{
node_uid
}
.
#{
site_uid
}
.grid5000.fr"
),
:vendor
=>
'Myrinet'
,
:version
=>
"10G-PCIE-8A-C"
,
:enabled
=>
true
},
{
:interface
=>
'Ethernet'
,
:rate
=>
1
.
giga
,
:enabled
=>
true
},
{
:interface
=>
'Ethernet'
,
:rate
=>
1
.
giga
,
:enabled
=>
false
}
]
...
...
This diff is collapsed.
Click to expand it.
generators/lib/g5k_generator.rb
+
7
−
1
View file @
55638816
require
'resolv'
module
G5K
SITES
=
%w{rennes grenoble bordeaux toulouse sophia orsay nancy lille lyon}
...
...
@@ -57,6 +59,10 @@ class ReferenceGenerator
@context
.
recursive_merge!
(
method
.
to_sym
=>
args
.
first
)
end
def
dns_lookup
(
network_address
)
Resolv
.
getaddress
(
network_address
)
end
%w{site cluster environment node service}
.
each
do
|
method
|
define_method
(
method
)
do
|
uid
,
*
options
,
&
block
|
key
=
method
.
pluralize
.
to_sym
...
...
@@ -74,7 +80,7 @@ class ReferenceGenerator
@context
[
key
]
<<
G5K
::
Tree
.
new
.
replace
({
:uid
=>
uid
,
:type
=>
method
})
@context
=
@context
[
key
].
last
end
block
.
call
if
block
block
.
call
(
uid
)
if
block
end
@context
=
old_context
end
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment