# Fog 0.32 + wheezy ou debian 7

**URL:** <https://www.debian-fr.org/t/fog-0-32-wheezy-ou-debian-7/57742>\
**Category:** Trucs et Astuces\
**Created:** [Février 21, 2016, 2:56 UTC](https://www.debian-fr.org/t/fog-0-32-wheezy-ou-debian-7/57742 "2016-02-21T14:56:31Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![guiguitarux](https://www.debian-fr.org/user_avatar/www.debian-fr.org/guiguitarux/32/10039_2.png) [@guiguitarux](https://www.debian-fr.org/u/guiguitarux)\
**Post date:** [Février 21, 2016, 2:56 UTC](https://www.debian-fr.org/t/fog-0-32-wheezy-ou-debian-7/57742/1 "2016-02-21T14:56:31Z")

</div>

Pour ceux qui auraient tenté l’installation, y a bien un problème puisque fog 0.32 est prévu pour fonctionner qu’avec PHP 5.3 or wheezy livre du php 5.4 ; Cependant il existe une solution simple, installer la version php de squeeze en faisant du pinning.

Commencer par arrêter les services avec un petit script :

`
#!/bin/sh
sysv-rc-conf --level 2345 FOGImageReplicator off
sysv-rc-conf --level 2345 FOGMulticastManager off
sysv-rc-conf --level 2345 FOGScheduler off
service apache2 stop
service mysql stop`

Purgez les paquets php5 :

```auto

```

modifier le /etc/sources.list :

```auto
deb http://security.debian.org/ wheezy/updates main contrib non-free
deb http://security.debian.org/ squeeze/updates main contrib non-free
deb http://ftp.fr.debian.org/debian/ wheezy main contrib non-free
deb http://ftp.fr.debian.org/debian/ squeeze main contrib non-free
```

ajouter un fichier /etc/apt/preferences.d/preferences :

```auto
Package: php5*
Pin: release a=oldstable
Pin-Priority: 700

Package: libapache2-mod-php5    
Pin: release a=oldstable
Pin-Priority: 700

Package: libapache2-mod-php5
Pin: release a=oldstable
Pin-Priority: 700

Package: *
Pin: release a=stable
Pin-Priority: 600

```

Réinstaller les paquets php5 en version squeeze :

[code]

# apt-get update

# apt-get install -t squeeze libapache2-mod-php5 php5-common php5 php5-cli php5-curl php5-gd php5-mcrypt php5-mysql[/code]

redémarrez les services avec un petit script :

```auto
#!/bin/sh
sysv-rc-conf --level 2345 FOGImageReplicator on
sysv-rc-conf --level 2345 FOGMulticastManager on
sysv-rc-conf --level 2345 FOGScheduler on
service apache2 start
service mysql start
```

Voilà 😉

PS: on est encore loin de apt-get install fog mais l’avantage de l’installer sur une wheezy c’est d’avoir accès facilement à [apparmor](http://wiki.debian.org/AppArmor/HowTo) et de pouvoir l’installer sur un hyperV ce qui jusque là était impossible à moins d’utiliser les backports…
