LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Security
User Name
Password
Linux - Security This forum is for all security related questions.
Questions, tips, system compromises, firewalls, etc. are all included here.

Notices


Reply
  Search this Thread
Old 12-29-2017, 11:27 PM   #16
YesItsMe
Member
 
Registered: Oct 2014
Posts: 915

Rep: Reputation: 313Reputation: 313Reputation: 313Reputation: 313

Right. Also, you'll need to add PHP to the mix, of course.

I'll have a nap - don't worry.
 
Old 12-29-2017, 11:36 PM   #17
newbie14
Member
 
Registered: Sep 2011
Posts: 646

Original Poster
Rep: Reputation: Disabled
Hi Yes,
I discover a mistake need to add this too listen [::]:8080 default_server;. Anything else you think I must add? I dont get you what do you mean add php ?
 
Old 12-29-2017, 11:39 PM   #18
YesItsMe
Member
 
Registered: Oct 2014
Posts: 915

Rep: Reputation: 313Reputation: 313Reputation: 313Reputation: 313
The server needs to call PHP for PHP files...
https://www.nginx.com/resources/wiki...mples/phpfcgi/
 
Old 12-29-2017, 11:44 PM   #19
newbie14
Member
 
Registered: Sep 2011
Posts: 646

Original Poster
Rep: Reputation: Disabled
Hi Yes,
What is this link ? I am a bit lost doesnt it comes together the support for php ? I also nginx plus is that a better version ?
 
Old 12-29-2017, 11:50 PM   #20
newbie14
Member
 
Registered: Sep 2011
Posts: 646

Original Poster
Rep: Reputation: Disabled
Hi Yes,
I find this link https://www.digitalocean.com/communi...ck-on-centos-7 to be better but I tried to do this yum install php

Error: php71u-json conflicts with php-common-5.4.16-43.el7_4.x86_64
Error: php71u-common conflicts with php-common-5.4.16-43.el7_4.x86_64
Error: mod_php71u conflicts with php-5.4.16-43.el7_4.x86_64
You could try using --skip-broken to work around the problem
You could try running: rpm -Va --nofiles --nodigest
 
Old 12-30-2017, 09:52 AM   #21
YesItsMe
Member
 
Registered: Oct 2014
Posts: 915

Rep: Reputation: 313Reputation: 313Reputation: 313Reputation: 313
nginx plus is a commercial nginx. You won't need that.
nginx does not come with PHP support, neither does Apache. You will have to enable it in both web servers first!

Seems like you have PHP 5.6 installed. Uninstall it first. If it came as a dependency, check if you could fix that. Otherwise, you'll have to stick with PHP 5.6 for now - CentOS can be old.
 
Old 12-30-2017, 11:54 AM   #22
newbie14
Member
 
Registered: Sep 2011
Posts: 646

Original Poster
Rep: Reputation: Disabled
Hi Yes,
What is different on the commercial nginx it has special features is it? Actually I am version sure I have install php 7 previously that is why you read it says Error: php71u-json conflicts with php-common-5.4.16-43.el7_4.x86_64. But surprisingly when I run this command php -v
-bash: php: command not found. It gives me cant find the php but my pages on apache is running fine.
 
Old 12-30-2017, 11:58 AM   #23
YesItsMe
Member
 
Registered: Oct 2014
Posts: 915

Rep: Reputation: 313Reputation: 313Reputation: 313Reputation: 313
Quote:
Originally Posted by newbie14 View Post
What is different on the commercial nginx it has special features is it?
Have you even read the website before asking me about the contents of the official documentation? Seriously, please do.

Quote:
Originally Posted by newbie14 View Post
-bash: php: command not found. It gives me cant find the php but my pages on apache is running fine.
Apache does not require PHP to run correctly, nor does nginx.
 
Old 12-30-2017, 12:09 PM   #24
newbie14
Member
 
Registered: Sep 2011
Posts: 646

Original Poster
Rep: Reputation: Disabled
Hi Yes,
I saw the website I guess mainly is about support and I guess they are charging for that. Regarding the php I am quite sure I am running php7 but I dont now why its not showing with this command php -v? Ok I will try to figure out on how to install the php for nginx.
 
Old 12-30-2017, 12:11 PM   #25
YesItsMe
Member
 
Registered: Oct 2014
Posts: 915

Rep: Reputation: 313Reputation: 313Reputation: 313Reputation: 313
There is no "PHP for nginx" - both nginx and Apache can use the same php-fcgi installation.
 
Old 12-30-2017, 12:20 PM   #26
newbie14
Member
 
Registered: Sep 2011
Posts: 646

Original Poster
Rep: Reputation: Disabled
Hi Yes,
Since I am using centos 7 it only support up to php 5.4. So I remember going to this link https://www.digitalocean.com/communi...-7-on-centos-7 to upgrade it php7. Coincidently I saw there tips on how to link nginx with php7 too so hopefully it will helpful for other with similar issue. Ok I have follow the link and hopefully it works.
 
Old 01-01-2018, 04:02 AM   #27
newbie14
Member
 
Registered: Sep 2011
Posts: 646

Original Poster
Rep: Reputation: Disabled
Hi Yes,
I have managed to install and run nginx. I have tried comparing I dont find that nginx to be much faster than apache when I compare side by side. So what can I do in order further speed up nginx? Should I post my .conf here ?

Last edited by newbie14; 01-01-2018 at 04:05 AM.
 
Old 01-01-2018, 10:17 AM   #28
YesItsMe
Member
 
Registered: Oct 2014
Posts: 915

Rep: Reputation: 313Reputation: 313Reputation: 313Reputation: 313
As I said, you will notice the difference with a lot of traffic.
 
Old 01-01-2018, 09:49 PM   #29
sundialsvcs
LQ Guru
 
Registered: Feb 2004
Location: SE Tennessee, USA
Distribution: Gentoo, LFS
Posts: 10,649
Blog Entries: 4

Rep: Reputation: 3934Reputation: 3934Reputation: 3934Reputation: 3934Reputation: 3934Reputation: 3934Reputation: 3934Reputation: 3934Reputation: 3934Reputation: 3934Reputation: 3934
To my way of thinking, these days it's not so much a matter of what you deploy (what scripting language, what database, and so on), but how you deploy it.

It is often the case that it's more efficient to purchase resources from a hosting service, which runs your application(s) on computers that it owns, at secure data-centers which it controls. There are many ways to do this: "actual iron," "virtual machines," and various types of "containers." These deployment strategies will give you the isolation that you need (doing so in various ways), but they will also address concerns such as scalability.

Rackspace, when discussing some of their container-based strategies, trots out in their advertising the use-case of a client who sells a mobile app for soccer-moms. Most games are played on weekends, so most of the demand for service is at narrow slots of time ... but it apparently can be quite intense, when it hits. Their deployment strategies allow the client to add horsepower when it's needed and to avoid paying for it when it's not.
 
Old 01-02-2018, 02:11 AM   #30
newbie14
Member
 
Registered: Sep 2011
Posts: 646

Original Poster
Rep: Reputation: Disabled
Hi Yes,
So when there is a lot of traffic what will be the difference in terms of nginx and apache then ? So for now what else can I add on to harden and optimise up the box.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
LXer: Anatine (Pristine Twitter App) – Mobile web version of Twitter App for Linux Desktop LXer Syndicated Linux News 0 08-11-2016 07:00 AM
Web Monitoring Mobile App abhilashbsstabilix Linux - Mobile 2 08-09-2015 10:55 AM
When Deploying web app directory tomcat application server got hanged ? findnerd2 Linux - Software 1 06-20-2015 04:07 PM
How is splitting only a database server from the web server more secure? anthony01 Linux - Security 3 10-31-2012 02:12 PM
VPN access to web application from mobile workstations asphodel587 Linux - Networking 2 06-11-2010 09:22 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Security

All times are GMT -5. The time now is 07:28 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration