FS#2898 - Using pacman for certain things in parallel
Attached to Project:
Pacman
Opened by Leonard Ritter (paniq) - Thursday, 30 June 2005, 18:59 GMT
Last edited by Dan McGee (toofishes) - Thursday, 07 February 2008, 04:44 GMT
Opened by Leonard Ritter (paniq) - Thursday, 30 June 2005, 18:59 GMT
Last edited by Dan McGee (toofishes) - Thursday, 07 February 2008, 04:44 GMT
|
Details
opposed to emerge, pacman does not support being called
multiple times at once.
tho, it would be nice if * searching was enabled in a second/third/etc pacman instance, if the first instance is busy with getting/installing a package * while the first instance is getting/installing, and a second pacman is called with the -S flag, the command gets queued for the first instance, so it hasnt been entered for nothing i'm suggesting this because i have been running into these issues numerous times and i dont really see why the actions mentioned above shouldnt be possible. i can imagine that the second part is rather complex to accomplish, but what about the first part? |
This task depends upon
Closed by Dan McGee (toofishes)
Thursday, 07 February 2008, 04:44 GMT
Reason for closing: Won't implement
Additional comments about closing: This is beyond what pacman is meant to do. There can always be read-only processes accessing the DB (with possible consistency issues during access), but queuing writes between processes just isn't practical.
Thursday, 07 February 2008, 04:44 GMT
Reason for closing: Won't implement
Additional comments about closing: This is beyond what pacman is meant to do. There can always be read-only processes accessing the DB (with possible consistency issues during access), but queuing writes between processes just isn't practical.
If pacman -S is already running and an -Ss instance starts, it can search the databases without conflict.
The second is more complicated. If the first pacman installs a package that conflicts with a package being requested in the second pacman instance, then the second won't know about it until it's too late.
for #2, i'd imagine it like this:
- user opens two root consoles #1 and #2
- user starts pacman #1 on console #1 with pacman -S kde
- user starts pacman #2 on console #2 with pacman -S kde
- pacman #2 complains about pacman #1 running and asks if kde should be queued for pacman #1, user answers yes
- pacman #1 finishes kde install and checks the queue (file?) for more jobs. it finds the job issued by #2 and treats it like a regular user command issued to pacman #1. it reacts correctly: "package already installed, proceed with upgrade?"
* pacman A starts
* pacman B starts, sees the lock fifo exists, writes it's command line to that file
* pacman B sends a SIGUSR1 to pacmanA
* pacman A handles SIGUSR1 by reading the fifo file, and adjusting what it is doing based on the parameters there, and continues.
Assigning to judd for input. It's my opinion that this is too complex to be added, but some others might want it.
Doing things in parallel requires us to change the locking mechanism to be cleaner, and I plan to do that in 3.1