You are not logged in.

#1 2008-07-18 07:49:19

MONODA
Member
Registered: 2008-02-09
Posts: 256

Will killing pacman have any side effects?

Hi recently while doing an upgrade with pacman, the download of a package will stop and I will not get any feedback anymore. So I leave it for a few hours but nothing happens so I decided to ^C which I know will kill pacman. What bad side effects should I expect from doing this? and is anyone else having a similar problem with pacman?

Offline

#2 2008-07-18 07:56:18

milan
Member
Registered: 2007-03-20
Posts: 38

Re: Will killing pacman have any side effects?

There won't be any side effects. If you restart upgrading the packages by typing 'pacman -Su', the upgrade process will continue where it stopped.

Offline

#3 2008-07-18 08:28:03

MONODA
Member
Registered: 2008-02-09
Posts: 256

Re: Will killing pacman have any side effects?

cool thanks

Offline

#4 2008-07-18 09:55:22

moljac024
Member
From: Serbia
Registered: 2008-01-29
Posts: 2,676

Re: Will killing pacman have any side effects?

This is annoying, we had a topic about this. It seems that pacman just stops responding from time to time for some of us. Of course, there is no special way to reproduce it, so it's a tough bug.


The day Microsoft makes a product that doesn't suck, is the day they make a vacuum cleaner.
--------------------------------------------------------------------------------------------------------------
But if they tell you that I've lost my mind, maybe it's not gone just a little hard to find...

Offline

#5 2008-07-22 09:57:34

jimmy512
Member
From: London
Registered: 2008-05-25
Posts: 16

Re: Will killing pacman have any side effects?

You might need to remove the pacman database lock at /var/lib/pacman/db.lck if you are no longer using pacman.

Offline

#6 2008-07-22 12:43:43

dav7
Member
From: Australia
Registered: 2008-02-08
Posts: 674

Re: Will killing pacman have any side effects?

moljac024 wrote:

This is annoying, we had a topic about this. It seems that pacman just stops responding from time to time for some of us. Of course, there is no special way to reproduce it, so it's a tough bug.

Maybe pacman should be modified to support an option (for pacman.conf) that causes pacman to log a TON of debug info to eg /var/log/pacman-debug.log, and those that experience the issue can try the setting out. And by "ton" I mean... every 2nd line in pacman being a debug_print() call (or whatever) tongue

Just an idea. I like ideas. cool

-dav7


Windows was made for looking at success from a distance through a wall of oversimplicity. Linux removes the wall, so you can just walk up to success and make it your own.
--
Reinventing the wheel is fun. You get to redefine pi.

Offline

#7 2008-07-22 13:05:45

shining
Pacman Developer
Registered: 2006-05-10
Posts: 2,043

Re: Will killing pacman have any side effects?

dav7 wrote:
moljac024 wrote:

This is annoying, we had a topic about this. It seems that pacman just stops responding from time to time for some of us. Of course, there is no special way to reproduce it, so it's a tough bug.

Maybe pacman should be modified to support an option (for pacman.conf) that causes pacman to log a TON of debug info to eg /var/log/pacman-debug.log, and those that experience the issue can try the setting out. And by "ton" I mean... every 2nd line in pacman being a debug_print() call (or whatever) tongue

Just an idea. I like ideas. cool

You mean like pacman --debug ?

To moljac024 : At which step does pacman stop responding? During download? You might have some network issues, unrelated to pacman.
At least, I don't experience anything similar, and I am sure many other users as well.


pacman roulette : pacman -S $(pacman -Slq | LANG=C sort -R | head -n $((RANDOM % 10)))

Offline

#8 2008-07-22 13:39:24

moljac024
Member
From: Serbia
Registered: 2008-01-29
Posts: 2,676

Re: Will killing pacman have any side effects?

shining wrote:
dav7 wrote:
moljac024 wrote:

This is annoying, we had a topic about this. It seems that pacman just stops responding from time to time for some of us. Of course, there is no special way to reproduce it, so it's a tough bug.

Maybe pacman should be modified to support an option (for pacman.conf) that causes pacman to log a TON of debug info to eg /var/log/pacman-debug.log, and those that experience the issue can try the setting out. And by "ton" I mean... every 2nd line in pacman being a debug_print() call (or whatever) tongue

Just an idea. I like ideas. cool

You mean like pacman --debug ?

To moljac024 : At which step does pacman stop responding? During download? You might have some network issues, unrelated to pacman.
At least, I don't experience anything similar, and I am sure many other users as well.

Yes, it just hangs during download. And at random times. And no, it's no network issue because as soon as I restart it, it continues downloading. A couple of times I've left my laptop downloading updates and went away doing other things only to return an hour or two later and see that it stopped 5 minutes after it started and had been hanging the whole time.

Should I just run pacman with --debug always ? I guess I could do that.


The day Microsoft makes a product that doesn't suck, is the day they make a vacuum cleaner.
--------------------------------------------------------------------------------------------------------------
But if they tell you that I've lost my mind, maybe it's not gone just a little hard to find...

Offline

#9 2008-07-22 14:21:14

shining
Pacman Developer
Registered: 2006-05-10
Posts: 2,043

Re: Will killing pacman have any side effects?

moljac024 wrote:

Yes, it just hangs during download. And at random times. And no, it's no network issue because as soon as I restart it, it continues downloading. A couple of times I've left my laptop downloading updates and went away doing other things only to return an hour or two later and see that it stopped 5 minutes after it started and had been hanging the whole time.

Should I just run pacman with --debug always ? I guess I could do that.

I really don't understand your justification of this not being a network issue.
And I doubt --debug will be helpful in case of download / network related problems.
What I would suggest is commenting out the XferCommand with wget in pacman.conf and try this for one week maybe, depending on how often you usually get this problem.
If everything works fine, it probably indicates some problems inside libdownload.
Otherwise, it probably indicates some kinds of network issue.

In any cases, information about your setup could help : which architecture, are you using a virtual machine, which network driver are you using, are you behind a proxy, etc...


pacman roulette : pacman -S $(pacman -Slq | LANG=C sort -R | head -n $((RANDOM % 10)))

Offline

#10 2008-08-09 22:45:59

lambchops468
Member
From: USA
Registered: 2008-04-25
Posts: 17

Re: Will killing pacman have any side effects?

moljac024 wrote:
shining wrote:
dav7 wrote:

Maybe pacman should be modified to support an option (for pacman.conf) that causes pacman to log a TON of debug info to eg /var/log/pacman-debug.log, and those that experience the issue can try the setting out. And by "ton" I mean... every 2nd line in pacman being a debug_print() call (or whatever) tongue

Just an idea. I like ideas. cool

You mean like pacman --debug ?

To moljac024 : At which step does pacman stop responding? During download? You might have some network issues, unrelated to pacman.
At least, I don't experience anything similar, and I am sure many other users as well.

Yes, it just hangs during download. And at random times. And no, it's no network issue because as soon as I restart it, it continues downloading. A couple of times I've left my laptop downloading updates and went away doing other things only to return an hour or two later and see that it stopped 5 minutes after it started and had been hanging the whole time.

Should I just run pacman with --debug always ? I guess I could do that.

Same thing happens to me, except the download slows down to a crawl. It seems like its frozen but pacman is going very slowly.

Offline

#11 2008-08-09 23:06:00

skottish
Forum Fellow
From: Here
Registered: 2006-06-16
Posts: 7,942

Re: Will killing pacman have any side effects?

lambchops468 wrote:
moljac024 wrote:
shining wrote:

You mean like pacman --debug ?

To moljac024 : At which step does pacman stop responding? During download? You might have some network issues, unrelated to pacman.
At least, I don't experience anything similar, and I am sure many other users as well.

Yes, it just hangs during download. And at random times. And no, it's no network issue because as soon as I restart it, it continues downloading. A couple of times I've left my laptop downloading updates and went away doing other things only to return an hour or two later and see that it stopped 5 minutes after it started and had been hanging the whole time.

Should I just run pacman with --debug always ? I guess I could do that.

Same thing happens to me, except the download slows down to a crawl. It seems like its frozen but pacman is going very slowly.

Servers get busy. Switches get busy. ISP sometimes shut down parts of their system for maintenance. Sometimes your signal is getting jacked. Sometimes there's wireless interference. Sometimes there's water in the lines. Sometimes.....

There are many things that can happen to networks without them going down.

Offline

#12 2008-08-10 10:00:00

moljac024
Member
From: Serbia
Registered: 2008-01-29
Posts: 2,676

Re: Will killing pacman have any side effects?

If it were as you say this would happen with my download managers, torrents and other package managers, which is not the case. Clearly pacman is failing somewhere where others are succeeding.


The day Microsoft makes a product that doesn't suck, is the day they make a vacuum cleaner.
--------------------------------------------------------------------------------------------------------------
But if they tell you that I've lost my mind, maybe it's not gone just a little hard to find...

Offline

#13 2008-08-10 12:19:05

iphitus
Forum Fellow
From: Melbourne, Australia
Registered: 2004-10-09
Posts: 4,927

Re: Will killing pacman have any side effects?

skottish wrote:

Sometimes.....

...the hampsters get tired

moljac024: I know it's fun to blame pacman for the bug - "you epic failure pacman!" - but let's try and work out where the bug really lies first. It's been suggested you try using an Xfercommand like wget to see if that improves the situation.

Offline

#14 2008-08-10 18:15:50

moljac024
Member
From: Serbia
Registered: 2008-01-29
Posts: 2,676

Re: Will killing pacman have any side effects?

iphitus wrote:
skottish wrote:

Sometimes.....

...the hampsters get tired

moljac024: I know it's fun to blame pacman for the bug - "you epic failure pacman!" - but let's try and work out where the bug really lies first. It's been suggested you try using an Xfercommand like wget to see if that improves the situation.

I'm sorry my posts haven't been more helpful, I did try with an Xfer command (wget) and I didn't use it for too long. I'm not sure how it behaved though. Although it must not have been an improvement since I ditched it. I could try again. I'm at work right now but will try as soon as I get home.


The day Microsoft makes a product that doesn't suck, is the day they make a vacuum cleaner.
--------------------------------------------------------------------------------------------------------------
But if they tell you that I've lost my mind, maybe it's not gone just a little hard to find...

Offline

#15 2008-08-15 05:53:24

DaveCode
Member
Registered: 2008-08-15
Posts: 103

Re: Will killing pacman have any side effects?

Hi, I can confirm this bug.  I have been installing Arch fresh, so all software is current.  The bug has happened twice in two days.  We have other machines on a KVM switch with the Arch box, same LAN.  The other machines can all surf, download, etc. while pacman is hung up.  So the network is fine but pacman is not.  As the other posters say, the timing is during package download but otherwise seemingly random.

Personally I would suspect some sort of buffer allocation type of bug, like waiting for a memory manager call to return, but dropping the return value, or somesuch.  However I have no basis for that, just a wild guess.

Nervously I used ctrl-C and did a clean afterwards.  Everything seems more or less ok, but the bug exists.  Thank you!

Offline

#16 2008-08-15 08:59:26

moljac024
Member
From: Serbia
Registered: 2008-01-29
Posts: 2,676

Re: Will killing pacman have any side effects?

iphitus I've tried with the default Xfercommand and it's still happening. It just freezes and waits for a restart.


The day Microsoft makes a product that doesn't suck, is the day they make a vacuum cleaner.
--------------------------------------------------------------------------------------------------------------
But if they tell you that I've lost my mind, maybe it's not gone just a little hard to find...

Offline

#17 2008-08-15 09:40:15

shining
Pacman Developer
Registered: 2006-05-10
Posts: 2,043

Re: Will killing pacman have any side effects?

DaveCode wrote:

Hi, I can confirm this bug.  I have been installing Arch fresh, so all software is current.  The bug has happened twice in two days.  We have other machines on a KVM switch with the Arch box, same LAN.  The other machines can all surf, download, etc. while pacman is hung up.  So the network is fine but pacman is not.  As the other posters say, the timing is during package download but otherwise seemingly random.

Personally I would suspect some sort of buffer allocation type of bug, like waiting for a memory manager call to return, but dropping the return value, or somesuch.  However I have no basis for that, just a wild guess.

Nervously I used ctrl-C and did a clean afterwards.  Everything seems more or less ok, but the bug exists.  Thank you!

moljac024 just said he could replicate it with the default XferCommand, so...
Please try this as well.


pacman roulette : pacman -S $(pacman -Slq | LANG=C sort -R | head -n $((RANDOM % 10)))

Offline

#18 2008-08-18 05:57:02

DaveCode
Member
Registered: 2008-08-15
Posts: 103

Re: Will killing pacman have any side effects?

shining wrote:

moljac024 just said he could replicate it with the default XferCommand, so...
Please try this as well.

The bug (for me) happened with the default XferCommand, native pacman.  After hitting it some few times, I switched XferCommand to wget.  I still observed the bug, but not as frequently.

# pacman --version | head -n 2
Pacman v3.2.0 - libalpm 3.0.0
# man pacman | tail -n 1
Pacman 3.1.4-278-gcf258-d     2008-07-24

Offline

#19 2008-08-18 06:04:51

shining
Pacman Developer
Registered: 2006-05-10
Posts: 2,043

Re: Will killing pacman have any side effects?

DaveCode wrote:
shining wrote:

moljac024 just said he could replicate it with the default XferCommand, so...
Please try this as well.

The bug (for me) happened with the default XferCommand, native pacman.  After hitting it some few times, I switched XferCommand to wget.  I still observed the bug, but not as frequently.

Even if it is less frequent, if it also happens with a totally different downloader, it means you have some network issues.
The problem is not in pacman/libdownload.


pacman roulette : pacman -S $(pacman -Slq | LANG=C sort -R | head -n $((RANDOM % 10)))

Offline

#20 2008-08-26 23:14:35

DaveCode
Member
Registered: 2008-08-15
Posts: 103

Re: Will killing pacman have any side effects?

My impression with wget was that it was the other end of the network, the mirror site.  That would hit either pacman or wget.  But the bug is repeatable with pacman no matter the mirror.

Offline

#21 2008-08-27 06:49:53

shining
Pacman Developer
Registered: 2006-05-10
Posts: 2,043

Re: Will killing pacman have any side effects?

DaveCode wrote:

My impression with wget was that it was the other end of the network, the mirror site.  That would hit either pacman or wget.  But the bug is repeatable with pacman no matter the mirror.

So it happens with every mirror, every downloader, and you still don't want to admit the problem is at YOUR END ?


pacman roulette : pacman -S $(pacman -Slq | LANG=C sort -R | head -n $((RANDOM % 10)))

Offline

#22 2008-08-27 08:11:10

byte
Member
From: Düsseldorf (DE)
Registered: 2006-05-01
Posts: 2,046

Re: Will killing pacman have any side effects?

Back to the main topic: It should be no problem to interrupt (ctrl-c) pacman while downloading, but I would advise against it during the actual install/upgrade/removal.


1000

Offline

#23 2008-08-28 02:06:30

dr.cranium
Member
Registered: 2008-01-25
Posts: 65

Re: Will killing pacman have any side effects?

I hate to bring it OT but I also had the same problem that they (Moljac and DaveCode) had.  I was trying to fix other problems and it went away.  I forget what I did though.  I was first using the tip on the wiki about using Pacget and aria2.  Then I noticed it not working.  So I went to vanilla pacman.  It would hang while downloading.  It seemed like about 5-10 minutes after starting the upgrade.

Offline

#24 2008-10-22 17:30:29

drpickett
Member
Registered: 2008-09-23
Posts: 3

Re: Will killing pacman have any side effects?

I am running Arch Linux in a Virtual PC context.  I was noticing similar problems when doing a pacman -Su.  I'd download 150K-300K bytes, and it would stop.  I traced the problem to wget on my system.  When I did a manual wget of the same file as pacman was trying to download, it would stop in a similar fashion each time.  Setting a very aggressive timeout and an infinite number of retries worked for me:

wget --timeout=5 --tries=0

Granted it was a bit slower and hiccuped each 5 seconds, but it did the job.   I put timeout=5 and tries=0 as the default in my /etc/wgetrc file and redid the pacman -Su

So, there are some networking shenanigans going on in my virtual machine that I do not understand, but this is a hackaround that is working for now

Offline

#25 2008-10-22 17:55:27

drpickett
Member
Registered: 2008-09-23
Posts: 3

Re: Will killing pacman have any side effects?

drpickett wrote:

I am running Arch Linux in a Virtual PC context.  I was noticing similar problems when doing a pacman -Su.  I'd download 150K-300K bytes, and it would stop.  I traced the problem to wget on my system.  When I did a manual wget of the same file as pacman was trying to download, it would stop in a similar fashion each time.  Setting a very aggressive timeout and an infinite number of retries worked for me:

wget --timeout=5 --tries=0

Granted it was a bit slower and hiccuped each 5 seconds, but it did the job.   I put timeout=5 and tries=0 as the default in my /etc/wgetrc file and redid the pacman -Su

So, there are some networking shenanigans going on in my virtual machine that I do not understand, but this is a hackaround that is working for now

Note: you may also accomplish this by going into /etc/pacman.conf and adding the following line:

XferCommand = /usr/bin/wget --timeout=5 --tries=0 %u

This is cleaner, and worked just fine for me

dp

Offline

Board footer

Powered by FluxBB