desgrange.net

502 Bad Gateway and subversion

If you get a 502 Bad Gateway message when moving a file in subversion via WebDAV interface over HTTPS on Apache and without using a proxy, you may have misconfigured SSL in Apache.

I was getting that error but when searching the web for a solution, I only found people having the problem when using an HTTPS proxy redirecting to a subversion on HTTP.

Until I found this thread. The problem is that SSL directives are not specified for the virtual host used for subversion (I have several virtual host and I forgot to put the directives for this one).

<VirtualHost *:443>
  ServerName svn.foo.bar
  ServerAdmin webmaster@foo.bar

  SSLEngine on
  SSLCertificateFile /etc/apache2/ssl/ssl.crt
  SSLCertificateKeyFile /etc/apache2/ssl/ssl.key

  <location />
    DAV svn

    SVNPath /path/to/svn/repository

    AuthType Basic
    AuthName "Subversion Repository"
    AuthUserFile /path/to/dav_svn.passwd
    AuthzSVNAccessFile /path/to/dav_svn.authz

    Require valid-user
  </location>
</VirtualHost>

The three lines starting with SSL where missing, but SSL was working since other virtual hosts were already declaring it.

Kubuntu 8.10

Last week Kubuntu 8.10 was released. Like OpenBSD, there is a new release every 6 months.

Kubuntu is a Linux distribution based on Ubuntu (which is based on Debian). Kubuntu is Ubuntu but the default desktop environment is KDE instead of Gnome.

The big improvement compared to Kubuntu 8.04 is the new version of KDE (4.1 instead of 3.x). KDE 4 is a major rewrite of KDE with a lot of improvements. Version 4.0 was mostly aiming at developers but version 4.1 is now suitable for regular users.

Installation

I downloaded the CD on BitTorrent and installed it on a virtual machine (with Sun's VirtualBox).

The CD allows you to boot on the live CD, and install Kubuntu from the live CD, or to directly start the installation process.

Only few questions are asked:

  • Your language (Kubuntu is translated in a lot of different languages).
  • Your time zone.
  • Your keyboard layout.
  • How to set up your hard drive (since I wanted to use the full disk, I just had to click on next, this is the only tricky part of the installation).
  • Your name, login and the name you want to give to your computer.

Then the installation start. Disk partitioning, formatting, packages installation. You just have to wait.

At the end, reboot, that's done.

First boot

The boot screen is still the same, with the same progress bar as in previous versions.

The new login screen is very nice (well, I like it) except the list of the users on the left (providing a default picture for each user should fill that blank part and make it better looking).

Then you have to wait a bit more while KDE is loading your session (nice loading animation).

At last, the desktop.

No more icons on the desktop. All the files that were on it are now displayed on the "Desktop" plasmoid. Plasmoids are KDE's applets, equivalent of Mac OS's widgets or Windows Vista's gadgets.

Not long after you logged in, a notification tells that updates are already available. So let's have a look.

Adept is launched. It's the graphical software you will use to install or remove softwares and upgrade installed softwares.

The interface is way much better than the one provided in the previous version of Kubuntu.

Let's have a look at the K menu.

Interesting, everything is displayed in the same window, there are no sub-menus opening on the side. It's cleaner, not sure if it's very useful. They have done a lot of usability tests on it, but the gain is not obvious. Anyway, I usually don't use the K menu (maybe that's why I don't see all the improvements in it ;-)).

I have tried a beta version few month ago and there was a thing a bit better, I didn't had to click to move between the panels. After a quick look (right click on the K menu), there are some options: use the classic menu (for those who don't like the new one), and change panels without clicking. KDE was known to have a lot of options everywhere, this version kept that spirit.

Right next to the K menu is an "home" folder icon. A click on it will allow you to quickly navigate inside your home folder.

In KDE, a piece a software was central for the user: Konqueror. Konqueror was used as a web browser but it was also used as a file manager. Konqueror is very versatile, with a huge amount of options. You can browse web pages, your local hard drive, any disks, FTP, remote SSH/SFTP, audio CD (even extract music from audio CD in the simplest way I have ever seen), all that the same way.

In the late version of KDE 3, a new file manager called Dolphin. At first I didn't understand why. There was no lawsuit against KDE forcing them to separate the file manager from the web browser ;-), and Konqueror was just fine.

After using Dolphin a bit, I have to admit that it's great. Focusing on mostly one task: browse files, Dolphin is a simpler tool, pleasant to use. However, Konqueror is still used as the web browser.

I said that I do not use the K menu a lot. At least, I don't use it to launch applications. I know the name of the applications I want to use, and using the keyboard can be faster than the mouse. On KDE 3, I used an application call Katapult. Hit a keyboard shortcut, a window appear, start typing the name of the application. Katapult list applications whose name is starting with the same letters. Hit enter and the application is launched. Very fast and convenient way to launch applications.

In KDE 4, no need for Katapult anymore. KRunner has been given the same functionality (hit Alt+F2 to launch it).

A lot more can be told about KDE 4, the amount of changes is impressive. I installed it on a virtual machine, now I want to install it on a real computer, to see the full potential of it, to be able to play with all the new stuff using graphic acceleration (not available on my VM :-().

Let's switch it off for now.

I used KDE 4.1 just for few hours but I think it's a very cool desktop environment. There are still some glitches, some improvements can be done, but it's already very nice.

KDE 4.2 is already under heavy development, more improvements are coming.

OpenBSD 4.4

Every 6 months, the new version of OpenBSD is released (on May 1 and November 1).

OpenBSD is known to be the most secure operating system, and that's why I use it as a router/firewall (on my fit-PC).

OpenBSD 4.4

Today's version is 4.4. New stuff in this release:

  • More platforms supported, better support for some existing ones.
  • Lots of drivers updates.
  • Updated shipped softwares (like OpenSSH, OpenSSL).
  • Lots of improvements.

You can also have a look to the full list of changes.

Upgrade

Upgrading OpenBSD is very easy. In my case I downloaded the installation ISO, burned it on a CD and booted on it.

After some questions (for most of them I just had to press enter), a check disk, 10 minutes to copy the files and reboot, the system was up again, working fine.

Upgrading took 20 minutes in total (from the moment I powered down the router and the moment it was operational with the new version). Most of the time was used to copy and install files, boot and disk check (the fit-PC is not a very fast computer). The upgrade software asked me around 15 questions, most of them the default value was the right one, for some other I had to enter either yes or done, that's all.

Theme and Song

Each version of OpenBSD has a theme. For 4.4 it's inspired by Star Wars:

SourceWars

And with every release, there is a song: "Trial of the BSD Knights" (sounds a bit like Cantina Band).

Lyrics are available as well as the songs files (as MP3 and OGG Vorbis).

Donations

OpenBSD is a very good operating system, open source, all that for free.

You can help them by coding, filling bug reports, translating documentation, giving hardware to developers, buying OpenBSD CDROM, audio CD, or simply by giving money.

I had my first OpenBSD by buying the OpenBSD 3.4 CDROM 5 years ago (I also bought a T-shirt).

This year I gave a small amount of money via PayPal.

Helping them will help the overall security of the internet. Several tools from OpenBSD are now widely used on other operating system (like OpenSSH which his now shipped with nearly all *nix systems (including Apple's Mac OS X)).

Reboot Mac OS X when Windows is crashed

What's cool with a Mac, besides having a beautiful and powerful computer, is that you can run Windows on it (well, I haven't used Windows for a while, so to me it's not a very cool feature).

This is nice for people switching from Windows to Mac OS X, they are still able to run Windows when they need to.

But nasty things may occur. For example Windows crashing before it has completely booted, or you haven't validated your Windows license. So, your shiny Mac is booting Windows, crashing, booting Windows, crashing over and over again.

In opposition to Linux, Mac OS X does not ask you which operating system you want to start on at boot time. When you are on Mac OS X or on Windows, there is a menu to reboot on the other operating system.

In the case you can't reach the menu, there is an other solution than formatting the hard drive and re-installing the system.

The solution is to keep the following keys pressed when the Mac is booting: command+alt+r+p.

This command tells the computer to start on the first partition, the one holding Mac OS X.

Keyboards and layouts

When using eXtreme Programming (XP) as software methodology, you often get a lot of problems to put it in place (management does not agree, some developers are reluctant). But what you might not expect is having tiny annoying problems with keyboards.

One of the techniques pushed by XP is pair programming. This implies having two developers working together in front of the same computer.

At any moment only one developer is writing code (this is the driver) and the other one is reviewing the code, giving advices, making sure that the code written by the driver is following the design rules of the project, etc. (this is the navigator).

But the roles between the two developers switch frequently, or the navigator needs to write a little piece of code to show to the driver, so the keyboard is moving a lot between both of them.

Sometimes we end up having two keyboards plugged in the computer, one for each of them, like this:

Pair programming setup

Teams are frequently composed with people coming from different countries and having different habits and so many different keyboards layouts. I worked with an Irish guy using an American qwerty keyboard with an English layout (or vice versa), in France we usually use French azerty keyboards with French layout but I'm using an Apple international English qwerty keyboard with international English qwerty layout.

So each time you start pair programming you have to look at what kind of keyboard you are going to use (if it's not yours) and what layout is used (and maybe change the layout each time one the developer start writing).

What I find annoying here is that even with two keyboards, you have to switch the layout because the operating system uses only one layout at a time. I have seen the same behavior on Microsoft Windows, GNU/Linux and even Mac OS X.

I'm wondering why layouts are not bound with keyboards. Maybe not a strict binding like keyboard A use only layout A and keyboard B use only layout B, but a list of layouts and the keyboards are bound with the last layout they where used with.

Maybe pair programmers are not very common, but I think that we are not the only ones with that problem. More and more laptops are sold, and quite often people use a desktop keyboard while using the laptop at home. They have to change the layout only once, but I'm sure we should avoid that (and on some operating system the task is really not easy the first time).

There are also programmable keyboards. On such keyboards you can change the code sent by each key when typing and create your own layouts. Maybe those kind of keyboards will solve the problem but they are expensive and hard to find.

Art Lebedev created the Optimus Maximus programmable keyboard where each key is an OLED display. Here they solved an other problem: having one unique "universal" keyboard. It can be used with azerty layout, qwerty layout or anything you can imagine and each key display the characters which is going to be written.

Optimus Maximus

Among others, a thing I find very interesting in the Optimus Maximus is the software to configure the keyboard:

Optimus Configurator

It provides a nice interface to configure layouts. I would like that kind of interface to configure my keyboards, since they are seldom recognized correctly, some keys are always wrong, or the behavior is not exactly what I want and finding the right layout in a big list is painful.

Here is the scenario I would like to have:

  • I have a computer with an azerty keyboard plugged in and configured.
  • I plug a new keyboard on my computer.
  • A configuration window should open asking to type some keys in order to detect which kind of layout is configured (like Mac OS X or some Linux distribution do).
  • If it's recognized as a qwerty keyboard, each time I type something on the keyboard the layout switch to qwerty.
  • If I type on the azerty keyboard, the azerty layout is used.
  • When using the qwerty keyboard I should be able to switch to an other layout, azerty for example. The last layout used for a given keyboard is bound to it until I change it.
  • A nice interface like Optimus Configurator should allow me to fine tune my layouts.

As far as I have seen until now, mainstream operating systems assume that a lot of things are unique. This situation started to change few years ago, now we can plug several keyboards, mice, screens on the same computer, but the software doing the configuration has not evolved a lot. The most common thing is having several screens. If you already tried to configure multiple screens, you may have found that it's quite easy on Mac OS X, it's hard on Windows and it's really painful on Linux. The worst thing I have seen is some software considering that multiple screens equals 2 screens, with 3 screens it's just not working and clearly not designed for. But most of the time, you can have only one keyboard/mouse configuration (you can't have several mice with different speed configurations).

Edit (2012-08-27): looks like I was wrong, a keymap can be specified for each keyboard on Linux.

En vrac

Je reprends un peu le principe de Tristan Nitot pour les billets "En vrac".

  • Linus Torvalds s'essaye au blog. S'il décide de continuer, ce sera certainement un blog à suivre, surtout pour son côté très direct à donner son opinion. Manque plus que Theo de Raadt se fasse un blog lui aussi.
  • Apple vient de sortir ses nouveaux MacBook et MacBook Pro taillé dans l'alu. Intéressant de voir que pendant la présentation ils ont passé beaucoup de temps à montrer comment les ordinateurs étaient fabriqués, ce qui n'est pas dans leurs habitudes ni dans ce qui intéressait leurs cibles jusqu'à présent. Un signe de plus de la migration d'un plus large panel de personnes vers les machines d'Apple ?

RAID-5 software sous GNU/Linux : la panne

Un jour où l'autre, la panne peut arriver, autant s'y préparer un peu. Malheureusement c'est souvent la panne à laquelle on ne s'attend pas qui se produit.

Pour tester mon installation en RAID-5, après avoir mis une centaine de giga octets de données dessus, j'ai débranché un disque puis je l'ai rebranché. Comme prévu le disque s'est remis en synchronisation.

Malheureusement, pendant la synchronisation un des autres disques a disparu. 2 disques non synchronisés = perte de toutes les données. Raison de la perte du disque : câble SATA défectueux (dans un ordinateur il y a plein de composants très compliqués et sensibles, forcément c'est un câble tout bête qui déconne).

Après quelques tentatives avec mdadm pour remettre sur pied l'array de disques, je suis arrivé à avoir 3 disques actifs sur 4, mais impossible de démarrer l'array, même avec les options pour forcer le démarrage.

Lorsque linux écrit sur les disques, il indique une sorte de numéro de transaction. Malheureusement, mon disque avec le problème de câble a un numéro pas à jour, alors que je n'ai rien écrit sur le RAID-5 depuis la perte des 2 disques (l'opération aurait de toute façon été impossible). C'est bien dommage d'avoir 3 disques bon (ce qui dans mon cas est donc suffisant) et ne pas pouvoir faire redémarrer l'array.

Grâce à mon ami Google, je suis tombé sur la commande suivante :

# echo "clean" > /sys/block/md0/md/array_state

Elle consiste juste à faire croire que l'array de disques fonctionne bien… et ça marche. Tout est reparti d'un coup, mes données toujours accessibles et non corrompues.

La page qui m'a beaucoup aidé : http://www.linuxquestions.org/questions/linux-general-1/raid5-with-mdadm-does-not-ron-or-rebuild-505361/

RAID-5 software sous GNU/Linux

Petit tutorial pour monter rapidement un système en RAID-5 sous linux.

Rappel sur le RAID-5

RAID signifie "Redundant Array of Inexpensive/Independent Disks". Le but de cette technologie est d'améliorer la tolérance aux pannes d'un système de stockage en utilisant plusieurs disques durs vus comme un seul.

Dans le cas du RAID-5, il est possible de perdre un disque sans pour autant perdre de données. La perte d'un deuxième disque entraînerait, par contre, la perte de l'intégralité des données.

Le RAID-5 nécessite un minimum de 3 partitions de tailles identiques (réparties sur 3 disques différents). La taille utile du disque résultant (l'espace disque vu par l'utilisateur) est la somme des tailles des partitions moins une (soit : (nombre de partitions - 1) * taille d'une partition).

Préliminaires

La distribution linux utilisée ici est Debian, il vous sera donc nécessaire d'adapter ceci en fonction de celle que vous utilisez.

Le disque RAID créé n'est pas utilisé comme disque système.

Pour commencer, munissez-vous de plusieurs disques de taille identique (ici 4 disques de 500 Go) et montez les un par un dans votre ordinateur. Surtout pensez bien à identifier vos disques au fur et à mesure que vous les installez. Vous devez noter leur nom logique vu par linux et leur correspondance avec le disque physique. Ces informations vous seront utiles en cas de panne, linux vous indiquera le nom logique du disque en panne et vous devrez alors être capable de repérer le disque physique correspondant pour le changer.

Vous pouvez par exemple noter l'"id" ou le "path" de chaque disque lorsque vous les installez (d'où l'intérêt de les installer un par un) :

$ ls -l /dev/disk/by-id/↵
total 0
lrwxrwxrwx 1 root root  9 2008-01-20 12:45 ata-SAMSUNG_HD501LJ-S0MUJ1MPC01769 -> ../../sdc
lrwxrwxrwx 1 root root  9 2008-01-20 12:45 ata-SAMSUNG_HD501LJ-S0MUJ1MPC01770 -> ../../sde
lrwxrwxrwx 1 root root  9 2008-01-20 12:45 ata-SAMSUNG_HD501LJ-S0MUJ1MPC01771 -> ../../sdb
(…)
$ ls -l /dev/disk/by-path/↵
total 0
lrwxrwxrwx 1 root root  9 2008-01-20 12:45 pci-0000:00:12.0-scsi-0:0:0:0 -> ../../sdd
lrwxrwxrwx 1 root root  9 2008-01-20 12:45 pci-0000:00:12.0-scsi-1:0:0:0 -> ../../sde
lrwxrwxrwx 1 root root  9 2008-01-20 12:45 pci-0000:01:00.0-scsi-0:0:0:0 -> ../../sdb
(…)

Note : Le "path" dépend du branchement du disque. Si vous débranchez un disque pour le brancher sur une autre prise, son "path" changera.

Une fois tous les disques installés, il faut créer une partition de type "Linux raid autodetect" :

$ sudo fdisk /dev/sde↵
n↵ (crée une nouvelle partition)
p↵ (partition primaire)
1↵ (partition primaire numéro 1, accepter ensuite les tailles par défaut pour utiliser la totalité du disque)
t↵ (changer le type de partition)
Hex code (type L to list codes): fd↵ (change le type de partition pour "Linux raid autodetect")
w↵ (écrit la table de partition sur le disque et quitte fdisk)

Cette manipulation est donc à répéter sur chacun des disques (les miens étant /dev/sdb à /dev/sde).

Action

Entrons maintenant dans le vif du sujet, la création du disque en RAID-5.

Pour ce faire vous devez avoir l'utilitaire mdadm, à installer avec la commande suivante si vous ne l'avez pas :

$ sudo apt-get install mdadm↵

Création du d'un disque en RAID-5 logiciel à partir de mes 4 disques sdb, sdc, sdd et sde :

$ sudo mdadm --create --verbose /dev/md0 --level=5 --raid-devices=4 /dev/sdb1 /dev/sdc1 /dev/sdd1 /dev/sde1↵

Voilà, c'est fini.

Conclusion

Les préliminaires sont toujours plus long.

Plus sérieusement, un disque "virtuel" a été créé (ici c'est /dev/md0). C'est ce disque qu'il faut monter (et formater) pour profiter de votre tout nouveau disque RAID.

Pour vérifier son état :

$ sudo mdadm --detail /dev/md0↵
/dev/md0:
        Version : 00.90.03
  Creation Time : Sat Jan 19 17:03:46 2008
     Raid Level : raid5
     Array Size : 1465151808 (1397.28 GiB 1500.32 GB)
  Used Dev Size : 488383936 (465.76 GiB 500.11 GB)
   Raid Devices : 4
  Total Devices : 4
Preferred Minor : 0
    Persistence : Superblock is persistent

    Update Time : Sun Jan 20 15:49:00 2008
          State : clean
 Active Devices : 4
Working Devices : 4
 Failed Devices : 0
  Spare Devices : 0

         Layout : left-symmetric
     Chunk Size : 64K

           UUID : 02918692:35547ed8:6ec71e01:ff96950c
         Events : 0.34

    Number   Major   Minor   RaidDevice State
       0       8       49        0      active sync   /dev/sdd1
       1       8       65        1      active sync   /dev/sde1
       2       8        1        2      active sync   /dev/sdc1
       3       8       17        3      active sync   /dev/sdb1

Il est important que la ligne "State" affiche "clean" et que la colonne "State" affiche "active sync" pour chaque disque. Juste après la création du volume RAID, l'état doit ressembler à "clean, degraded, recovering", c'est normal, le système est en train de synchroniser les disques entre eux (cette étape peut être assez longue, quelques heures avant d'arriver à "clean"). Pour voir l'avancement de la synchronisation :

$ cat /proc/mdstat↵

Maintenant il fait surveiller l'état du disque régulièrement, il ne faut pas attendre qu'il ne marche plus pour s'inquiéter, il sera déjà trop tard (2 disques seront déjà tombés).

Par défaut (voir le fichier /etc/mdadm/mdadm.conf) mdadm envoi un mail à l'utilisateur "root" en cas de problème, je vous conseille de configurer cette propriété pour que le mail soit envoyé à une adresse email que vous lisez régulièrement.

Lorsque le système est "clean", vous pouvez stopper un des disques pour simuler une panne, vérifier que vous recevez bien une alerte par email. Redémarrez ensuite le disque (et attendez plusieurs heures le temps que le système redevienne "clean") :

$ sudo mdadm /dev/md0 --fail /dev/sdb1↵ (déclare le disque sdb1 "en panne")
$ sudo mdadm /dev/md0 --add /dev/sdb1↵ (ajoute le disque sdb1 au système RAID, la synchronisation reprend immédiatement)

Je vous conseille fortement de lire la documentation pour bien comprendre comment tout fonctionne.

Si vous avez déjà un volume RAID en place et que vous voulez l'étendre en rajoutant un disque, apparemment c'est possible : http://scotgate.org/?p=107.

Bon courage.

Ponctuation

Où et quand mettre des espaces dans la ponctuation française.

Qu'est-ce qu'une espace ?

L'espace, en typographie, est un nom féminin. On parle donc d'une espace.

Il y a deux types d'espaces :

  • Les espaces "classiques", que l'on obtient avec la barre d'espacement sur un clavier.
  • Les espaces "insécables", qui sont des espaces sur lesquelles un retour à la ligne ne peut pas être effectué. Ces espaces sont celles que l'on retrouve par exemple avant un caractère deux-points pour éviter qu'il ne se retrouve tout seul en début de ligne suivante. En HTML, une espace insécable est représenté par &nbsp;.

Il faut aussi savoir que toutes les espaces n'ont pas la même largeur, mais je vais passer sur ce point que je ne maîtrise pas du tout.

Quand les utiliser ?

  • Il faut insérer une espace après les signes de ponctuation suivants : virgule (,), point (.), points de suspension ().
  • Une espace insécable avant et une espace après les signes suivants : deux-points (:), point-virgule (;), point d'exclamation (!), point d'interrogation (?).
  • Pour les caractères comme les parenthèses (()), les crochets ([]), les accolades ({}), il faut mettre une espace avant le caractère ouvrant et après le caractère fermant.
  • Pour les guillemets droits ("), le comportement est le même que pour les parenthèses.
  • Pour les guillemets à la française (« et »), il faut une espace avant et après le caractère. Comme « ceci » donc. Les espaces "intérieures" sont insécables.

Quand ne pas les utiliser ?

  • Il n'y a pas d'espace autour de l'apostrophe (').
  • Après un(e) parenthèse/crochet/accolade ouvrant(e) ou avant un(e) parenthèse/crochet/accolade fermant(e).
  • Après un(e) parenthèse/crochet/accolade fermant(e) si ce caractère est suivi par un autre signe de ponctuation ne demandant pas d'espace avant. Par exemple, une parenthèse suivie d'une virgule : "),".

Liens :

Relativité

Pour faire suite à mon billet précédent sur le temps et sa mesure, approchons rapidement le temps d'un point de vue relativiste.

Albert Einstein a énoncé quelques théories dont celle de la relativité restreinte et celle de la relativité générale.

Ces théories (qui fonctionnent plutôt bien) disent, entre autre, que le temps ne s'écoule pas à la même vitesse partout. Pour simplifier (parce que je ne suis pas un expert non plus) on peut dire que l'écoulement du temps est perturbé par la gravité et la vitesse de déplacement (en fait le phénomène est identique dans les 2 cas).

Un corps soumis à une forte gravité, voit son temps s'écouler plus lentement que celui d'un corps non soumis à cette force de gravité. De même pour un corps se déplaçant à grande vitesse.

Dans mon précédent billet je vous parlais de mesurer le temps avec des horloges atomiques pour une très grande précision. À quoi peut bien servir cette précision si l'écoulement du temps n'est pas uniforme ?

À la surface de la Terre, je pense que l'on peut considérer que le temps s'écoule effectivement de façon uniforme. Donc à quoi est-ce que cela peut nous servir dans notre vie de tous les jours de savoir que le temps est relativiste alors ?

Exemple simple : le GPS

Un satellite GPS embarque une horloge atomique. C'est l'heure de cette horloge qui est envoyée par le satellite pour pouvoir se positionner à la surface de la Terre (le récepteur GPS compare la position et l'heure envoyée par les différents satellites qu'il capte afin de déterminer sa propre position).

Pour une bonne précision, le décalage entre les horloges des satellites doit être de l'ordre de 20 à 30 nano secondes.

Un satellite GPS se déplace à environ 14 000 km/h, ce qui lui donne 7 µs de retard par jour. D'un autre côté, les satellites GPS sont à très haute altitude (20 000 km), là où la gravité terrestre se fait beaucoup moins sentir, ce qui donne 45,7 µs d'avance par jour au satellite. L'un dans l'autre, un satellite GPS avance de 38,7 µs par jour (soit 38 700 nano secondes !).

En 38,7 µs, le signal électromagnétique envoyé par les satellites GPS a le temps de parcourir 11,6 km. Si la relativité n'avais pas été prise en compte lors de la mise en place du GPS, il serait devenu inutilisable dès son premier jour de service.

Liens :