[pacman-dev] Manual rankmirrors.
I use rankmirrors and I notice on timeouts pacman automatically switches. Today, though most packages downloaded quickly from the mirror just selected by rankmirrors, one or two went very very slow. I guess differing routes by different package requests. Would it be easy to add a ^S (Ctrl-S) to tell pacman to stop and retry at the next mirror. If I ever find the time, not too likely for a while, I might look into it. Just figured if anyone had worked on it and thought yeah I could just change that then it wold be worth flinging the idea at the devs. On a side note should pacman be using /proc/mounts for Checkspace rather than /etc/mtab.
On Wed, Apr 25, 2012 at 2:49 PM, Kevin Chadwick <ma1l1ists@yahoo.co.uk> wrote:
On a side note should pacman be using /proc/mounts for Checkspace rather than /etc/mtab.
1) We don't reference a filename at all in the code, we use "standardized" functions to access this 2) On your Arch machine, /etc/mtab is a symlink to /proc/self/mounts already So I'm not quite sure what your plan of action is here. -Dan
On Wed, 25 Apr 2012 14:00:05 -0500 Dan McGee wrote:
1) We don't reference a filename at all in the code, we use "standardized" functions to access this
Are error codes handled correctly? Seems /proc/mounts should trump /etc/mtab to me.
2) On your Arch machine, /etc/mtab is a symlink to /proc/self/mounts already
So I'm not quite sure what your plan of action is here.
Re-action really. To update yesterday I had to manually remove /etc/mtab. This made Checkspace fail. I've decided to just disable CheckSpace as it's caused a different problem before. p.s. (I also had to mount /proc rw)
On Thu, Apr 26, 2012 at 11:19:35AM +0100, Kevin Chadwick wrote:
Re-action really. To update yesterday I had to manually remove /etc/mtab. This made Checkspace fail. I've decided to just disable CheckSpace as it's caused a different problem before.
p.s. (I also had to mount /proc rw)
Uh, I've heard that before? [1] Wow... feels bad. cheers! mar77i [1] http://www.archlinux.org/news/filesystem-upgrade-manual-intervention-require...
On Fri, 27 Apr 2012 12:25:59 +0200 Martti Kühne wrote:
Uh, I've heard that before? [1] Wow... feels bad.
cheers! mar77i
[1] http://www.archlinux.org/news/filesystem-upgrade-manual-intervention-require...
It was a symlink and that had already been done.
On Thu, Apr 26, 2012 at 11:19:35AM +0100, Kevin Chadwick wrote:
Re-action really. To update yesterday I had to manually remove /etc/mtab. This made Checkspace fail. I've decided to just disable CheckSpace as it's caused a different problem before.
p.s. (I also had to mount /proc rw)
Could you elaborate on the error messages and why you did what you did, then? Seems you left out a significant bit, since I have no comparable error here.
On Fri, 27 Apr 2012 13:41:30 +0200 Martti Kühne wrote:
Could you elaborate on the error messages and why you did what you did, then? Seems you left out a significant bit, since I have no comparable error here.
If no-one else hits this then no matter. I might look into improving rankmirrors one day, if it's not already been done by then. For now I might just switch to the newer bytemark mirror. I'm guessing it will be more reliable than UK2s. From memory I removed /etc/mtab... can't recall sorry and the errors seem to be missing from pacman.log. I'm fairly sure it simply said it couldn't remove /etc/mtab. I'm guessing it was this that failed on the original run: upgraded filesystem (2012.2-2 -> 2012.2-4) Once /etc/mtab was removed it complained about read-only /proc. I disabled checkspace as it said out of space error because I had removed /etc/mtab before re-running pacman. Obviously /proc/mounts was still intact.
/etc/mtab is symlinked to /proc/self/mount └─╼ ls -l /etc/mtab lrwxrwxrwx 1 root root 17 Apr 1 19:41 /etc/mtab -> /proc/self/mounts On Wed, Apr 25, 2012 at 08:49:48PM +0100, Kevin Chadwick wrote:
I use rankmirrors and I notice on timeouts pacman automatically switches. Today, though most packages downloaded quickly from the mirror just selected by rankmirrors, one or two went very very slow. I guess differing routes by different package requests.
Would it be easy to add a ^S (Ctrl-S) to tell pacman to stop and retry at the next mirror. If I ever find the time, not too likely for a while, I might look into it. Just figured if anyone had worked on it and thought yeah I could just change that then it wold be worth flinging the idea at the devs.
On a side note should pacman be using /proc/mounts for Checkspace rather than /etc/mtab.
On Wed, Apr 25, 2012 at 3:49 PM, Kevin Chadwick <ma1l1ists@yahoo.co.uk> wrote:
Would it be easy to add a ^S (Ctrl-S) to tell pacman to stop and retry at the next mirror.
The mirrors may not necessarily be in sync, the next mirror could have a completely different version of the package. Could cause difficulties...
On Wed, Apr 25, 2012 at 08:49:48PM +0100, Kevin Chadwick wrote:
I use rankmirrors and I notice on timeouts pacman automatically switches. Today, though most packages downloaded quickly from the mirror just selected by rankmirrors, one or two went very very slow. I guess differing routes by different package requests.
How about ranking mirrors by a metric that's actually meaningful? rankmirrors uses ping, which is utterly worthless, as you're seeing right here. Mirror selection should be based on: 1) locality (and hopefully that correlates with speed) 2) update-to-date-ness We provide a tool on www.archlinux.org [1] that offers this already. If you suffer from the inability to make decisions, you can use Reflector, which merely parses a JSON representation of this page and suggests something for you.
Would it be easy to add a ^S (Ctrl-S) to tell pacman to stop and retry at the next mirror. If I ever find the time, not too likely for a while, I might look into it. Just figured if anyone had worked on it and thought yeah I could just change that then it wold be worth flinging the idea at the devs.
I'm glad you've thought this through. Ctrl-S is the canonical key combination for most terminals to trigger flow control off. If you'd like to actually code this up, you'll need to rig up a non-blocking FD connected to stdin of the controlling terminal. Make sure it's portable to BSD, Cygwin, and OSX. d [1] http://www.archlinux.org/mirrors/status/
On Wed, 25 Apr 2012 15:55:32 -0400 Dave Reisner wrote:
How about ranking mirrors by a metric that's actually meaningful? rankmirrors uses ping, which is utterly worthless, as you're seeing right here. Mirror selection should be based on:
Aah, I always use tcping (or is it hping) for testing tcp connectivity. Does it not check throughput and such.
1) locality (and hopefully that correlates with speed) 2) update-to-date-ness
We provide a tool on www.archlinux.org [1] that offers this already. If you suffer from the inability to make decisions, you can use Reflector, which merely parses a JSON representation of this page and suggests something for you.
Well I chose the servers well manually, one night I guess the ISP UK2 was moving some data around or something because it went really slow so I added rankmirrors to my update script.
participants (6)
-
Dan McGee
-
Daniel Wallace
-
Dave Reisner
-
DJ Mills
-
Kevin Chadwick
-
Martti Kühne