Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
G
Geth-Modification
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
张蕾
Geth-Modification
Commits
ec28a58c
Unverified
Commit
ec28a58c
authored
Feb 02, 2018
by
Martin Holst Swende
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
utils: fix #16006 by not lowering OS ulimit
parent
4dedde7b
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
3 deletions
+5
-3
flags.go
cmd/utils/flags.go
+5
-3
No files found.
cmd/utils/flags.go
View file @
ec28a58c
...
...
@@ -714,13 +714,15 @@ func setIPC(ctx *cli.Context, cfg *node.Config) {
// makeDatabaseHandles raises out the number of allowed file handles per process
// for Geth and returns half of the allowance to assign to the database.
func
makeDatabaseHandles
()
int
{
if
err
:=
fdlimit
.
Raise
(
2048
);
err
!=
nil
{
Fatalf
(
"Failed to raise file descriptor allowance: %v"
,
err
)
}
limit
,
err
:=
fdlimit
.
Current
()
if
err
!=
nil
{
Fatalf
(
"Failed to retrieve file descriptor allowance: %v"
,
err
)
}
if
limit
<
2048
{
if
err
:=
fdlimit
.
Raise
(
2048
);
err
!=
nil
{
Fatalf
(
"Failed to raise file descriptor allowance: %v"
,
err
)
}
}
if
limit
>
2048
{
// cap database file descriptors even if more is available
limit
=
2048
}
...
...
Write
Preview
Markdown
is supported
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