Project

General

Profile

Actions

Bug #12859

open

pkg sometimes hangs for nothing

Added by giahung 1997tn almost 3 years ago. Updated almost 3 years ago.

Status:
New
Priority:
Normal
Assignee:
-
Category:
-
Target version:
Start date:
Due date:
% Done:

0%

Estimated time:
Difficulty:
Medium
Tags:

Description

Especially when searching for packages with pkg search -rp. Sometimes it just hangs there and doing nothing. Checked for network activity via VirtualBox, I found no network IO at all. A quick look via top also show no system resource being used other than what already there and there is no process named pkg! So this means it failed to run at all! I have to cancel it with Ctrl+C.

I don't have any knowledge about programming but I used to hear someone said it's the symptom of it failed to fork/exec itself, but please don't take my words seriously, since I really really don't know anything about programming at all!

And I found most of the time after a reboot I could search for packages with pkg search -rp again. It's weirded, I still have plenty of ram there!

Sometimes it's because network bottleneck and it's solved by tried again after some hours. I think if there is problem, pkg should let me know and exit peacefully instead of letting me to wait for nothing.

Actions #1

Updated by Aurélien Larcher almost 3 years ago

Provide more information, it usually means a networking problem, like not an issue with pkg itself.

Actions #2

Updated by giahung 1997tn almost 3 years ago

Aurélien Larcher wrote:

Provide more information, it usually means a networking problem, like not an issue with pkg itself.

That's everything I could give. I'm a new user.

Actions #3

Updated by matt farnsworth almost 3 years ago

The program top is probably not well suited for your use case. Try ps -p $(pgrep pkg) or ps aux | grep pkg

I would suggest checking for network connectivity and sufficient bandwidth before starting pkg commands. pkg/client/transport/engine does have a feature to check if responses are "too slow" or stalled. (I have not checked if it works)

You can also add -v -v -v for more feedback from pkg

Actions

Also available in: Atom PDF