Opera Mirror Program

Opera Mirror Configuration

General

Opera provides a mirror master for read-only rsync access by approved mirror sites. The access to the master servers will be restricted by the mirror sites's IP address/network. Only the officially approved mirror sites will be allowed to access the mirror master.

The basic command to pull the public distribution from the mirror master is something like:

rsync -a mirror.opera.com::pub-opera /var/mirror/pub/opera

Contact Addresses

mirror-admin[at]opera.com
Technical requests and new mirror registrations.

Master Server

mirror.opera.com
This is the default mirror master address.
mirror.no.opera.com
EU mirror master. Located in Oslo, Norway.
mirror.us.opera.com
US mirror master (we don't have any US master anymore, so it's the same as EU server).

Distribution Module

::pub-opera
This is the rsync base path for the public distribution files to be mirrored. The path corresponds to the /pub/opera path on the ftp server. For example, the rsync path mirror.opera.com::pub-opera/win/ will correspond to the ftp path ftp://ftp.opera.com/pub/opera/win/

Rsync Configuration

Recommended configuration directives:

--delete
This will delete obsolete files from the mirror directory when they are removed from the master server. Be careful with this on initial setup - if path setup is wrong, it may delete more than wanted. Use with -n (dry-run) until everything works fine.
-a
Preserve file permissions, recursive, etc.

Additional configuration directives:

-c
This will force checksums to be used for file comperisation (instead of time/size) between master and slave files. It will make the sync process a bit slower, but it may be required to use this in the future, to make sure that no illegally modified files (trojans/viruses) is distributed from mirror sites.
-v
Verbose - useful for testing initial setup (add multiple -v for more verbosity).
-n
Dry run - will not change any files, recommend for initial testing.
-q
Quiet - will silent most of the output, useful for cron jobs.

For more info about rsync: rsync.samba.org

Time Schedules

We suggest that the mirrors are configured to syncronize with the mirror master at least twice a day, ideally 4 times a day. To prepare the mirrors with new releases before they are announced to the public, we suggest the following hours for updates (all time settings in UTC):

6:00 (primary)
Main release time. All mirror sites should syncronize during this hour, to prepare for eventual new releases.
12.00 (optional)
US announce time.
18:00 (secondary)
Eventual urgent bugfixes on new releases will be distributed at this time.
00.00 (optional)
Generally low internet traffic. Should be good for huge updates. New releases may be available at this time the day before a press release.

To spread the load from mirror sites somehow, the mirror sites should use a random minute setting for syncronization - any minute in the following hour is recommended.

Directory Structure

The mirrors are free to mount the public opera directory wherever they find useful in their local filesystem (but make sure this location fits with the links on the Opera website download page). It is not allowed to change the internal directory structure below /pub/opera/, as this may cause confusion both for download links and statistics. If needed, create symlinks into the official structure instead. The official directory structure will be the same as the one provided by ftp.opera.com.

Statistics

Not neeeded. Download statistics from mirror sites may be sent by mail to mirror-report[at]opera.com. If possible set the subjectline (or from address) to use your mirror site's domain name. At the moment we can handle xferlog and apache log formats - other formats may be supported. Opera does not require any privacy information from the logs like client IP's, refeerers etc. A sample statistic script may be provided later.

Rsync Client Pull Samples

Sample script to be runned from cron or maually

#!/bin/sh
# Script for rsync pull from mirror.opera.com
TARGET="/var/mirror/ftp.opera.com/pub/opera"
SOURCE="mirror.opera.com::pub-opera"
OPTIONS="-a --delete"

rsync $OPTIONS $SOURCE $TARGET

### END

Simple cron.d script

Note: May be dropped into /etc/cron.d

# This will run a rsync pull 15 minutes over every 6 hours.
15 */6 * * *	root	rsync -a --delete mirror.opera.com::pub-opera /var/mirror/ftp.opera.com/pub/opera
### END

Download resources