-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
index segments by maximum by 2 workers #4041
- Loading branch information
1 parent
47f4926
commit c896807
Showing
1 changed file
with
2 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -1102,8 +1102,8 @@ func DownloadAndIndexSnapshotsIfNeed(s *StageState, ctx context.Context, tx kv.R | |
if workers < 1 { | ||
workers = 1 | ||
} | ||
if workers > 4 { | ||
workers = 4 | ||
if workers > 2 { | ||
workers = 2 // 4 workers get killed on 16Gb RAM | ||
This comment has been minimized.
Sorry, something went wrong.
This comment has been minimized.
Sorry, something went wrong.
AskAlexSharov
Author
Collaborator
|
||
} | ||
if err := snapshotsync.BuildIndices(ctx, cfg.snapshots, cfg.snapshotDir, *chainID, cfg.tmpdir, cfg.snapshots.IndicesAvailable(), workers, log.LvlInfo); err != nil { | ||
return err | ||
|
I think it would be better if we make this configurable from cli arguments.