Skip to content
This repository was archived by the owner on Sep 30, 2024. It is now read-only.
This repository was archived by the owner on Sep 30, 2024. It is now read-only.

Check memory before cloning a large Perforce depot (or monitor for OOM) #42385

@mike-r-mclaughlin

Description

@mike-r-mclaughlin

Requested by: https://github.com/sourcegraph/accounts/issues/583

Feature request description

Before cloning Perforce depots, check to make sure there is enough memory to successfully run. Alternatively, monitor for oom of the p4-fusion process and report that back to user.

Is your feature request related to a problem? If so, please describe.

We set up a Perforce depot to be cloned and it started running and appeared to be going along ok until we saw this:

[ SUCCESS @ Main:240 ] Received userbase details from the Perforce server
[ PRINT @ Main:245 ] Last CL to start downloading is CL 1066833
[ WARNING @ CreateIndex:137 ] No HEAD commit was found. Created a fresh index. 
signal: killed

In dmesg we saw that p4-fusion had been killed by the OOM reaper.

This took extra effort to track this down and also required us to login to the gitserver (after figuring out which gitserver the clone was running on). It would be better if this was automatic and exposed in the UI somehow.

/cc @jplahn @ryphil

Metadata

Metadata

Assignees

Labels

Type

No type
No fields configured for issues without a type.

Projects

Status
✅ Done - Released (available to install)

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions