Skip to content

Commit

Permalink
fix(system_monitor): high-memory process are not provided in MEM orde…
Browse files Browse the repository at this point in the history
…r (backport autowarefoundation#4654) (#769)

fix(system_monitor): high-memory process are not provided in MEM order (autowarefoundation#4654)

* fix(process_monitor): high-memory process are not being provided in %MEM order



* changed option from 'g' to 'n'



---------

Signed-off-by: ito-san <fumihito.ito@tier4.jp>
Co-authored-by: ito-san <57388357+ito-san@users.noreply.github.com>
  • Loading branch information
h-ohta and ito-san authored Aug 29, 2023
1 parent 6e26a1f commit c01ba62
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -401,7 +401,7 @@ void ProcessMonitor::getHighMemoryProcesses(const std::string & output)
bp::pipe err_pipe{err_fd[0], err_fd[1]};
bp::ipstream is_err{std::move(err_pipe)};

bp::child c("sort -r -k 10", bp::std_out > p2, bp::std_err > is_err, bp::std_in < p1);
bp::child c("sort -r -k 10 -n", bp::std_out > p2, bp::std_err > is_err, bp::std_in < p1);
c.wait();
if (c.exit_code() != 0) {
is_err >> os.rdbuf();
Expand Down

0 comments on commit c01ba62

Please sign in to comment.