• Home
  • Archive
  • Tools
  • Contact Us

The Customize Windows

Technology Journal

  • Cloud Computing
  • Computer
  • Digital Photography
  • Windows 7
  • Archive
  • Cloud Computing
  • Virtualization
  • Computer and Internet
  • Digital Photography
  • Android
  • Sysadmin
  • Electronics
  • Big Data
  • Virtualization
  • Downloads
  • Web Development
  • Apple
  • Android
Advertisement
You are here: Home » Nginx PHP5-FPM Restart Fix Note For Ubuntu (HP Cloud)

By Abhishek Ghosh September 19, 2015 9:21 am Updated on September 19, 2015

Nginx PHP5-FPM Restart Fix Note For Ubuntu (HP Cloud)

Advertisement

PHP5-FPM Restart Can Be Fixed on Ubuntu in 2 Ways. Our Famous Nginx PHP5-FPM Restart Fix Needs a Note For Ubuntu Instances on HP Cloud. We have forgotten how we fixed the issue, but our uploading the fix to Github seems to be useful for the users. We are elaborating the issue along with our fix and alternative method.

 

Nginx PHP5-FPM Restart Fix Note For Ubuntu : Problem Scenario

 

The user installed PHP5-FPM. Then changed some basic settings around php.ini or installed some dependent packages. Upon running service php5-fpm restart, the server will not take restart and throw “stop: Unknown instance” error.
Upon reboot, PHP5-FPM may fail to start again. It is pathetic & not intentionally created. Running tail -f /var/log/php5-fpm.log& returns no significant issue.

 

Nginx PHP5-FPM Restart Fix Note For Ubuntu : Our Way of Fix

 

Here is our full Github project to fix the Ngnx PHP5-FPM Restart Issue. As you can see, it is licensed under GNU GENERAL PUBLIC LICENSE, that means it is a Free Software.

Advertisement

---

Problem creating file is :

Vim
1
/etc/init/php-fpm.conf

cd to /etc/init/ and do a ls to check the file name. The filename can be different (php-fpm or php5-fpm). cd to /etc/init/ and find the file named php-fpm.conf or php5-fpm.conf, run a cat to see the content and find the lines :

Vim
1
2
3
4
5
# Precise upstart does not support reload signal, and thus rejects the
# job. We'd rather start the daemon, instead of forcing users to
# reboot https://bugs.launchpad.net/ubuntu/+source/php5/+bug/1272788
#
# reload signal USR2

and uncomment this :

Vim
1
reload signal USR2

on running service php5-fpm restart, you’ll get warning though. Because, of this script :

Vim
1
/etc/init.d/php5-fpm

Open Filezilla, take backup of /etc/init.d/php5-fpm on your computer, delete php5-fpm script from /etc/init.d/ and create a new script :

Vim
1
nano /etc/init.d/php5-fpm

curl or wget this file :

Vim
1
https://raw.githubusercontent.com/AbhishekGhosh/Nginx-PHP5-FPM-Restart-Fix-on-Ubuntu/master/php5-fpm

reboot, PP5-FPM will work fine :)

 

Nginx PHP5-FPM Restart Fix Note For Ubuntu : Alternative Way of Fix

 

On the Ubuntu launchpad forums it is suggested that users may create an /etc/init/php5-fpm.override file with only reload signal USR2 in it instead of editing /etc/init/php5-fpm.conf file. There is no other difference on the rest of the method.

Nginx PHP5-FPM Restart Fix Note For Ubuntu (HP Cloud)

 

Nginx PHP5-FPM Restart Fix Note For Ubuntu : For OS X

 

/usr/local/sbin is your $PATH. Create a new file :

Vim
1
nano /usr/local/etc/php/fpm-restart

copy-paste this :

Vim
1
2
3
4
5
6
7
8
9
10
11
12
13
#!/bin/sh
 
echo "Custom Script Stopping PHP5-FPM..."
launchctl unload -w ~/Library/LaunchAgents/homebrew-php*.plist
 
echo "Custom Script Starting PHP5-FPM..."
launchctl load -w ~/Library/LaunchAgents/homebrew-php*.plist
 
# alternate file name, use if current does not work :
# homebrew.mxcl.php*.plist
 
echo "PHP5-FPM Restarted!"
exit 0

Now chmod it rightly & symlink it :

Vim
1
2
chmod ug+x /usr/local/etc/php/fpm-restart && cd /usr/local/sbin
ln -s /usr/local/etc/php/fpm-restart

Thats it.

Tagged With php5-fpm restart

This Article Has Been Shared 128 Times!

Facebook Twitter Pinterest

Abhishek Ghosh

About Abhishek Ghosh

Abhishek Ghosh is a Businessman, Surgeon, Author and Blogger. You can keep touch with him on Twitter - @AbhishekCTRL.

Here’s what we’ve got for you which might like :

Articles Related to Nginx PHP5-FPM Restart Fix Note For Ubuntu (HP Cloud)

  • Nginx PHP5-FPM WordPress : Major Tweaks

    Here is a Short Yet More Than Enough Guide For the Most To Tweak Nginx PHP5-FPM WordPress Setup Running on Ubuntu 14.04 on Rackspace Cloud Server.

  • HHVM WordPress (Nginx Ubuntu Server) Tweaks

    Here are some special HHVM Wordpress (Nginx Ubuntu Server) Tweaks for Page Speed optimization, Compatibility of WordPress Themes and Plugins.

  • Steps To Install Nginx Plus on Ubuntu Server (HP Cloud)

    Here Are the Steps To Install Nginx Plus on Ubuntu Server Running on HP Cloud. Nginx Plus is the Paid Version of Nginx with Extra Features.

  • Zend Opcache Optimization for Nginx Ubuntu (HP Cloud)

    Here is Full Guide to Zend Opcache Optimization for Nginx PHP5-FPM for Ubuntu Server Running on HP Cloud. We Suggest to Use Zend Opcache over APC.

  • Nginx Cache Purge Module For fastcgi_cache WordPress

    Nginx Plus by Default Supports Cache Purging. Nginx Cache Purge Module For fastcgi_cache Exists Can Be Used For Community Edition of Nginx.

Additionally, performing a search on this website can help you. Also, we have YouTube Videos.

Take The Conversation Further ...

We'd love to know your thoughts on this article.
Meet the Author over on Twitter to join the conversation right now!

If you want to Advertise on our Article or want a Sponsored Article, you are invited to Contact us.

Contact Us

Subscribe To Our Free Newsletter

Get new posts by email:

Please Confirm the Subscription When Approval Email Will Arrive in Your Email Inbox as Second Step.

Search this website…

 

Popular Articles

Our Homepage is best place to find popular articles!

Here Are Some Good to Read Articles :

  • Cloud Computing Service Models
  • What is Cloud Computing?
  • Cloud Computing and Social Networks in Mobile Space
  • ARM Processor Architecture
  • What Camera Mode to Choose
  • Indispensable MySQL queries for custom fields in WordPress
  • Windows 7 Speech Recognition Scripting Related Tutorials

Social Networks

  • Pinterest (24.3K Followers)
  • Twitter (5.8k Followers)
  • Facebook (5.7k Followers)
  • LinkedIn (3.7k Followers)
  • YouTube (1.3k Followers)
  • GitHub (Repository)
  • GitHub (Gists)
Looking to publish sponsored article on our website?

Contact us

Recent Posts

  • Cyberpunk Aesthetics: What’s in it Special January 27, 2023
  • How to Do Electrical Layout Plan for Adding Smart Switches January 26, 2023
  • What is a Data Mesh? January 25, 2023
  • What is Vehicular Ad-Hoc Network? January 24, 2023
  • Difference Between Panel Light, COB Light, Track Light January 21, 2023

About This Article

Cite this article as: Abhishek Ghosh, "Nginx PHP5-FPM Restart Fix Note For Ubuntu (HP Cloud)," in The Customize Windows, September 19, 2015, January 29, 2023, https://thecustomizewindows.com/2015/09/nginx-php5-fpm-restart-fix-note-for-ubuntu-hp-cloud/.

Source:The Customize Windows, JiMA.in

PC users can consult Corrine Chorney for Security.

Want to know more about us? Read Notability and Mentions & Our Setup.

Copyright © 2023 - The Customize Windows | dESIGNed by The Customize Windows

Copyright  · Privacy Policy  · Advertising Policy  · Terms of Service  · Refund Policy

We use cookies on our website to give you the most relevant experience by remembering your preferences and repeat visits. By clicking “Accept”, you consent to the use of ALL the cookies.
Do not sell my personal information.
Cookie SettingsAccept
Manage consent

Privacy Overview

This website uses cookies to improve your experience while you navigate through the website. Out of these, the cookies that are categorized as necessary are stored on your browser as they are essential for the working of basic functionalities of the website. We also use third-party cookies that help us analyze and understand how you use this website. These cookies will be stored in your browser only with your consent. You also have the option to opt-out of these cookies. But opting out of some of these cookies may affect your browsing experience.
Necessary
Always Enabled
Necessary cookies are absolutely essential for the website to function properly. These cookies ensure basic functionalities and security features of the website, anonymously.
CookieDurationDescription
cookielawinfo-checkbox-analytics11 monthsThis cookie is set by GDPR Cookie Consent plugin. The cookie is used to store the user consent for the cookies in the category "Analytics".
cookielawinfo-checkbox-functional11 monthsThe cookie is set by GDPR cookie consent to record the user consent for the cookies in the category "Functional".
cookielawinfo-checkbox-necessary11 monthsThis cookie is set by GDPR Cookie Consent plugin. The cookies is used to store the user consent for the cookies in the category "Necessary".
cookielawinfo-checkbox-others11 monthsThis cookie is set by GDPR Cookie Consent plugin. The cookie is used to store the user consent for the cookies in the category "Other.
cookielawinfo-checkbox-performance11 monthsThis cookie is set by GDPR Cookie Consent plugin. The cookie is used to store the user consent for the cookies in the category "Performance".
viewed_cookie_policy11 monthsThe cookie is set by the GDPR Cookie Consent plugin and is used to store whether or not user has consented to the use of cookies. It does not store any personal data.
Functional
Functional cookies help to perform certain functionalities like sharing the content of the website on social media platforms, collect feedbacks, and other third-party features.
Performance
Performance cookies are used to understand and analyze the key performance indexes of the website which helps in delivering a better user experience for the visitors.
Analytics
Analytical cookies are used to understand how visitors interact with the website. These cookies help provide information on metrics the number of visitors, bounce rate, traffic source, etc.
Advertisement
Advertisement cookies are used to provide visitors with relevant ads and marketing campaigns. These cookies track visitors across websites and collect information to provide customized ads.
Others
Other uncategorized cookies are those that are being analyzed and have not been classified into a category as yet.
SAVE & ACCEPT