Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Felix Seibert
xtreemfs_client
Commits
163c8049
Commit
163c8049
authored
Apr 16, 2018
by
Felix Seibert
Browse files
add max_files_in_progress as command-line argument
parent
f0636fad
Changes
2
Hide whitespace changes
Inline
Side-by-side
xtreemfs_client/OSDManager.py
View file @
163c8049
...
...
@@ -122,7 +122,9 @@ class OSDManager(object):
f
=
open
(
path_to_config
,
"wb"
)
pickle
.
dump
(
self
.
distribution
,
f
)
def
create_distribution_from_existing_files
(
self
,
fix_layout_internally
=
True
,
apply_layout
=
True
,
def
create_distribution_from_existing_files
(
self
,
fix_layout_internally
=
True
,
max_files_in_progress
=
10000
,
apply_layout
=
True
,
environment
=
'LOCAL'
):
"""
create a good data distribution out of data already present in the file system.
...
...
@@ -171,7 +173,7 @@ class OSDManager(object):
start_time
=
time
.
time
()
if
fix_layout_internally
:
self
.
fix_physical_layout_internally
()
self
.
fix_physical_layout_internally
(
max_files_in_progress
=
max_files_in_progress
)
else
:
if
environment
==
'SLURM'
:
osd_list
=
self
.
distribution
.
get_osd_list
()
...
...
xtreemfs_client/das.py
View file @
163c8049
...
...
@@ -62,6 +62,8 @@ parser.add_argument("--fix-internally", action='store_const', const=True, defaul
'layout. otherwise files will be temporarily located outside xtreemfs,'
'increasing the chance for data loss.'
)
parser
.
add_argument
(
"--max-files-in-progress"
,
nargs
=
1
)
args
=
parser
.
parse_args
()
if
args
.
debug
:
...
...
@@ -106,4 +108,5 @@ elif args.update:
elif
args
.
create_from_existing_files
:
x_man
.
create_distribution_from_existing_files
(
fix_layout_internally
=
args
.
fix_internally
,
environment
=
args
.
environment
)
environment
=
args
.
environment
,
max_files_in_progress
=
int
(
args
.
max_files_in_progress
[
0
]))
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment