---
title: Fixing /etc/init.d/php5-fpm Init Script for PHP 5.4 (from Dotdeb) on Debian Squeeze
date: 2012-08-24T12:50:01+00:00
modified: 2012-08-24T12:51:24+00:00
image:: https://kaspars.net/wp-content/uploads/2012/08/php5-fpm.init-compare.png
permalink: https://kaspars.net/blog/fixing-php5-fpm-init-php-5-4-debian-dotdeb
post_type: post
author:
  name: Kaspars
  avatar: https://reverse.kaspars.net/gravatar/avatar/92bfcd3a8c3a21a033a6484d32c25a40b113ec6891f674336081513d5c98ef76?s=96&d=mm&r=g
post_tag:
  - How to
  - PHP
post_format:
  - Aside
category:
  - Web Performance
---

# Fixing /etc/init.d/php5-fpm Init Script for PHP 5.4 (from Dotdeb) on Debian Squeeze

I recently updated my server to PHP 5.4 and discovered that I was no longer able to restart the `PHP-FPM` service using the regular:

```
$ /etc/init.d/php5-fpm restart
```

or

```
$ service php5-fpm restart
```

I went to the official [Debian GIT repository for the PHP 5.4 beta package](http://anonscm.debian.org/gitweb/?p=pkg-php/php.git;a=blob;f=debian/php5-fpm.init;h=b8e4f861c28ca820b5aaa1421cfdd9850d081c52;hb=HEAD) and found the [following differences](http://diffchecker.com/hYd8rl3j) between the init scripts ([here is the one from Dotdeb](https://raw.github.com/gplessis/dotdeb-php5/squeeze-php53/debian/php5-fpm.init)):

[![](https://kaspars.net/wp-content/uploads/2012/08/php5-fpm.init-compare.png?strip=all&quality=90&resize=500,259 "php5-fpm.init-compare")](http://diffchecker.com/hYd8rl3j)

Replacing my init script with the one from the official beta package solved the problem. I wonder what `export ZEND_DONT_UNLOAD_MODULES=1` does wrong.