Difference between revisions of "Mirrorlist CGI Script"

From CDOT Wiki
Jump to: navigation, search
(Package the Mirrorlist CGI Script Library)
(Package the Mirrorlist CGI Script Library)
 
(3 intermediate revisions by the same user not shown)
Line 35: Line 35:
 
* scamper
 
* scamper
  
 +
 +
<u>'''Algorithm 1'''</u>
 
The algorithm for the script measures the speed of each mirrorlist and repository within the yum mirrorlist.
 
The algorithm for the script measures the speed of each mirrorlist and repository within the yum mirrorlist.
 
By using the ping command the script will capture the time for an icmp packet to return from the target destination
 
By using the ping command the script will capture the time for an icmp packet to return from the target destination
Line 50: Line 52:
 
* running fedora for the first time
 
* running fedora for the first time
  
 
+
<u>'''Algorithm 2'''</u>
 
Another Algorithm that can implemented is to rearrange the mirrorlist according to location
 
Another Algorithm that can implemented is to rearrange the mirrorlist according to location
Note: This algorithm will not be as reliable as the first therefore time invested on this algorithm will be low
+
''Note: This algorithm will not be as reliable as the first therefore time invested on this algorithm will be low''
 
The algorithm will extract the current location of the device via time zone and geographically locate each site's location
 
The algorithm will extract the current location of the device via time zone and geographically locate each site's location
 
The algorithm will rearrange the database according to the closest site server.
 
The algorithm will rearrange the database according to the closest site server.
Line 88: Line 90:
 
Goals for each release and plans for reaching those goals:
 
Goals for each release and plans for reaching those goals:
 
<!-- Note: Each student must have unique goals. These goals may be ''related'' to other students' work, but must be ''distinct'' and ''attainable'' regardless of the state of the other students' work. For example, under the umbrella of one project title, one student may work on packaging a piece of software and another may work on documentation, or one may work on solving one bug and another on solving another bug, but two students must not work on the same bug or depend on the other students' work in order to be able to complete their own project. -->
 
<!-- Note: Each student must have unique goals. These goals may be ''related'' to other students' work, but must be ''distinct'' and ''attainable'' regardless of the state of the other students' work. For example, under the umbrella of one project title, one student may work on packaging a piece of software and another may work on documentation, or one may work on solving one bug and another on solving another bug, but two students must not work on the same bug or depend on the other students' work in order to be able to complete their own project. -->
* 0.1 - Initial packaging. Package sent for review in Fedora (if this is useful on devices beyond the Pi) or Pidora (if useful only on the Pi)
+
* 0.1 - Completion of the script
* 0.2 - Review issues addressed, package through the review process.
+
* 0.2 - Review issues addressed, testing, compilation issue (if found)
* 0.3 - Package in Fedora or Pidora.
+
* 0.3 - Package in Fedora 19-20
  
 
== Communication ==
 
== Communication ==
Line 108: Line 110:
  
 
=== Source Code Control ===
 
=== Source Code Control ===
 
* Upstream source code: https://github.com/quick2wire/quick2wire-python-api
 
 
<!-- Add a link to source code URLs, including git/mercurial/svn/cvs repositories -->
 
<!-- Add a link to source code URLs, including git/mercurial/svn/cvs repositories -->
  
 
=== Blogs ===
 
=== Blogs ===
  
*  
+
* http://matrix.senecac.on.ca/~mkmatthew/
 
<!-- Links to the blogs of people involved, both inside and outside Seneca -->
 
<!-- Links to the blogs of people involved, both inside and outside Seneca -->
  

Latest revision as of 09:22, 17 October 2013

Package the Mirrorlist CGI Script Library

Project Description

This project will create a script that will optimize the performance of all yum updates and package installation.

Project Leader

Matthew Kam-Man Wong

Project Contributor(s)

  • TBA

Project Details

Dependencies required:

  • ping
  • ifconfig
  • grep
  • sed
  • awk

The following are optional:

  • scamper


Algorithm 1 The algorithm for the script measures the speed of each mirrorlist and repository within the yum mirrorlist. By using the ping command the script will capture the time for an icmp packet to return from the target destination

  • The script will capture 4 packets per site
  • awk and sed will be used to extract the last two lines of the ping results

For each site, the data will be stored in a database for future references.

  • The database will be rearranged by using sed by ascending order
  • After the rearrangement the data will be append to the current yum static file.

When yum performs an update or installation of a package it will refer to the static file's first line and work its way down the list.

This algorithm will execute in the following conditions

  • A change in gateway IP address
  • Change in DNS server IP address
  • running fedora for the first time

Algorithm 2 Another Algorithm that can implemented is to rearrange the mirrorlist according to location Note: This algorithm will not be as reliable as the first therefore time invested on this algorithm will be low The algorithm will extract the current location of the device via time zone and geographically locate each site's location The algorithm will rearrange the database according to the closest site server. This works by a process of elimination

  • By country
  • Province/State
  • City

Conditions for this algorithm:

  • if ICMP is disabled
  • the bandwidth is to low to download
  • change of location
  • restrictions on iptables



Project Plan

Tracking

  • Bugzilla or Trac will be used for review management.


Goals by Release

Goals for each release and plans for reaching those goals:

  • 0.1 - Completion of the script
  • 0.2 - Review issues addressed, testing, compilation issue (if found)
  • 0.3 - Package in Fedora 19-20

Communication

Mailing Lists

  • Google group:

Upsteam Wiki and Web

Links/Bugs/Tracking

Source Code Control

Blogs


Project News

  • 2013-10-07: Project started!