Poll

Should the repo speed test progress indicatory be displayed as pulsating bar with text updates, or a bar indicating percentage of repo's tested (also with text updates)?

Pulsating bar, with text updates
1 (5.3%)
Percent completed, with text updates
14 (73.7%)
Scrap the idea and keep my favorite repo a secret!
4 (21.1%)

Total Members Voted: 17

Author Topic: SCRIPT: Repo speed test GUI  (Read 11228 times)

Offline travisN000

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 1758
SCRIPT: Repo speed test GUI
« on: October 31, 2009, 07:20:19 PM »
With some help from Don_crissti over at www.linuxgator.org I've put together a zenity (GUI) / bash script to run a speed test on all of the official PCLinuxOS repositories, display the results to the user, and then let the user pick which repository should be their default repository.

Once the user picks a repository the sources.list file is re-written with all of the other "good" repositories disabled, and only the user selected repo enabled (repos that don't time out during the speed test, or are not older than the user defined age are considered good).  Local and pass repos are preserved from the current sources.list file, but are disabled; the current sources.list is backed up in /etc/apt before the new one is written.

So far it seems to work pretty well, but I wanted some feedback on one aspect of the GUI..  do you like the pulsating progress indicator, or the (more useful) percentage progress indicator?

I've attached two copies if the script below.. one to demonstrate each indicator.  Please test and VOTE!

The final version will be determined by you.. the users!  ;D


EDIT:  
I have locked the poll..  It seems the over-whelming majority like the progress bar to indicate the percent completed.

Also, by popular request the following changes have been made:
--re-writing of the existing /etc/apt/sources.list file requires a command line switch (off by default)
--files are saved in the user's home directory
--user can select the number of public on-line repo's to keep in the new sources.list file
--local and pass repos from the old sources.list are added to the top of the new sources.list file
--local "localhost" and lan ip repo's are also now preserved

The new version is attached below.. Please test and post your feedback!  ;D


Code: [Select]
Available console options to override default behavior include:.
  -a, -age=<time in days>           Allowed repo age before FAIL
  -n, -number=<number of repos>     Max number of official repos to keep (fastest)
  -s, -sources=<url of file>        Location of official online sources.list
  -t, -timeout=<time in seconds>    Time to start file download before FAIL
  -v, -verbose                      Verbose output for debugging
  -w, -write                        Prompt to write new sources.list to /etc/apt (root password)
  -u, -usage                        Display sample command line usage, help
  -h, -help                         Display this help message

[attachment deleted by admin]
« Last Edit: December 15, 2009, 06:45:18 AM by travisn000 »

Offline travisN000

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 1758
Re: TESTING & POLL: Repo speed test GUI
« Reply #1 on: October 31, 2009, 07:21:37 PM »
PS..  if you don't know how to install and test, just ask!
 ;D

Offline Joble

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 6804
  • USA - Mountain Time
Re: TESTING & POLL: Repo speed test GUI
« Reply #2 on: October 31, 2009, 07:31:34 PM »
Awesome!  I like the percent better.

It kept my local repo, it kept my PASS, and pclosusers was fastest from my house.   ;D

And!  It detected my kde4, just like you said it would.
« Last Edit: October 31, 2009, 07:47:15 PM by Joble »
Search First.
Forum Rules
Hero means I talk a lot, nothing more, nothing less!
Have an Awesome Day!
Healthy System

Offline Tuxfriend

  • Hero Member
  • *****
  • Posts: 1256
Re: TESTING & POLL: Repo speed test GUI
« Reply #3 on: October 31, 2009, 07:37:27 PM »
So far it seems to work pretty well, but I wanted some feedback on one aspect of the GUI..  do you like the pulsating progress indicator, or the (more useful) percentage progress indicator?

If it's more useful, then I'd rather have the percentage progress indicator.  ;D
Best regards

Eddie

Offline Hootiegibbon

  • Hero Member
  • *****
  • Posts: 4151
Re: TESTING & POLL: Repo speed test GUI
« Reply #4 on: October 31, 2009, 07:42:27 PM »
travisn000,

Gotta say, good work. I will agree with Joble here and suggest you go with the percentage bar, although the pulse does remind me a bit of KnightRider.

Jase


I am Hootiegibbon, undisputed champion fo the typo

My .dotfiles

Offline gseaman

  • PCLinuxOS Tester
  • Hero Member
  • *******
  • Posts: 3791
Re: TESTING & POLL: Repo speed test GUI
« Reply #5 on: October 31, 2009, 08:17:32 PM »
I ran the speed test gui with the percent bar. Good work!

Galen

Offline Tuxfriend

  • Hero Member
  • *****
  • Posts: 1256
Re: TESTING & POLL: Repo speed test GUI
« Reply #6 on: October 31, 2009, 08:27:19 PM »
... although the pulse does remind me a bit of KnightRider.

Germans have nightmares about Hassel the Hoff. As a German, I can attest to that ...  ;D
Best regards

Eddie

Offline wlan

  • Sr. Member
  • ****
  • Posts: 252
Re: TESTING & POLL: Repo speed test GUI
« Reply #7 on: October 31, 2009, 08:44:09 PM »
nice work. a very handy tool. it told me what i already knew, but useful anyway.
good job.

regards
I disagree with Kay Jewelers. I would bet on any given Friday or Saturday night, more kisses begin with Miller Lite than Kay.

AMD Athlon(tm) 64 Processor 3700+
Asus A8R-MVP MB
2gb OCZ ram
nvidia pci-e 6600GT
320 GB Hitachi
Dlink Airlink Atheros (wireless)

Offline magiman7

  • PCLinuxOS Tester
  • Hero Member
  • *******
  • Posts: 707
  • Three C's of Life = Cigars, Coffee, Linux ?
    • To Stay Informed
Re: TESTING & POLL: Repo speed test GUI
« Reply #8 on: October 31, 2009, 09:12:26 PM »
It worked really nicely, but it got rid of my openoffice repo

Offline travisN000

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 1758
Re: TESTING & POLL: Repo speed test GUI
« Reply #9 on: October 31, 2009, 10:21:36 PM »
It worked really nicely, but it got rid of my openoffice repo

I'll have to look into this...  I could modify the script pretty easily to also add in the open-office repo, but I'm pretty sure that the recommended way to install / update open-office is to use pinoc's getopenoffice script

EDIT: 
The script does back up the previous sources.list in the /etc/apt folder..  restoring the old one should be a simple mv as root.
« Last Edit: October 31, 2009, 10:49:20 PM by travisn000 »

Offline YouCanToo

  • PCLinuxOS Tester
  • Hero Member
  • *******
  • Posts: 5331
  • Location: Lebanon, OR., USA
    • Spreading the word.......
Re: TESTING & POLL: Repo speed test GUI
« Reply #10 on: October 31, 2009, 10:35:47 PM »
Wow travisn000 what a nice job you have done  :D I really have to vote for the percent bar. Something about that pulsating progress indicator, reminds me of one to many games of pong.

@joble   pclosusers.com only rated 5th place during my test....... bummer.




Be sure to visit the NEW Knowledge Base


Linux is user-friendly- it's just picky who its friends are!

Offline travisN000

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 1758
Re: TESTING & POLL: Repo speed test GUI
« Reply #11 on: October 31, 2009, 10:42:39 PM »
Wow travisn000 what a nice job you have done  :D I really have to vote for the percent bar. Something about that pulsating progress indicator, reminds me of one to many games of pong.

@joble   pclosusers.com only rated 5th place during my test....... bummer.

Thank yOU!

..in testing it I probably ran the script 50+ times;  pclosusers.com ranked #1 about 90% of the time from my location.  Every once in a while it would drop a few spots, and once or twice it even got kicked out to the "bad" list for not responding within the 3 second time-out (hard-coded, could be changed).  I guess the point of my rambling is that network conditions can change minute-by-minute, so don't depend on just one test!
« Last Edit: November 01, 2009, 12:29:51 AM by travisn000 »

Offline gseaman

  • PCLinuxOS Tester
  • Hero Member
  • *******
  • Posts: 3791
Re: TESTING & POLL: Repo speed test GUI
« Reply #12 on: October 31, 2009, 10:47:21 PM »
This is great! I have a local repo for packaging. It gets saved, but is on the bottom of the list. (I would like to have the repo list cut down to the top 10. If it is run again, you could still check the entire list but only show the top ten.

Galen

Offline travisN000

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 1758
Re: TESTING & POLL: Repo speed test GUI
« Reply #13 on: October 31, 2009, 10:59:58 PM »
This is great! I have a local repo for packaging. It gets saved, but is on the bottom of the list. (I would like to have the repo list cut down to the top 10. If it is run again, you could still check the entire list but only show the top ten.

Galen


If you want to modify your personal copy, do a search for the following line:
Code: [Select]
for (( r=0; r<${#finalrepolist[@]}; r++ ))
..and change it to:
Code: [Select]
for (( r=0; r<10; r++ ))
..that should limit the number of repos written to the new sources.list file (I didn't test it though!  :D)

Otherwise, try clicking "cancel" after about 10 of the repo's have been tested..  ..you can also click OK at the end when asked if you want to open synaptic and it will take you directly to the syanptic repository window where you can manually delete any ones you do not want.
« Last Edit: October 31, 2009, 11:01:58 PM by travisn000 »

Offline dobbs

  • Sr. Member
  • ****
  • Posts: 324
Re: TESTING & POLL: Repo speed test GUI
« Reply #14 on: October 31, 2009, 11:28:52 PM »
Nice script, works great. I voted for the percent. The pulse made me dizzy... :D
Began the journey in 2006