php fpm error after upgrading - apache

I decided to do a aptitude safe upgrade today on my debian and it replaced my version of php with the latest.
It asked me if i want to keep my www.conf and i selected yes.
By this time, i see these errors in the error.log:
(13)Permission denied: FastCGI: failed to connect to server "/home/john/domains/test.net/php5-fpm": connect() failed
FastCGI: incomplete headers (0 bytes) received from server "/home/john/domains/test.net/php5-fpm"
And website is not accessible (php versions).
/home/john/domains/test.net/php5-fpm is not a directory at all.
I tried adding these lines to www.conf and restarting the service, with no luck:
listen.owner = www-data
listen.group = www-data
listen.mode = 0666
Please advise.

When you upgrade the Apache, the worker sometimes changes, execute apachectl -V and see what worker do you have installed.
For example in my local server i have MPM worker, and when i update via aptitude, the worker changes to prefork (don't know why), so i need to:
Executes apachectl -V and see what worker i have installed.
Executes sudo apt-get install apache2-mpm-worker if i detect i have prefork installed
In your case you will need to reinstall php5-fpm

Related

Why won't my systemd REDIS service start in RHEL 7.9?

So I'm not sure how to even figure out what's happening. Running redis-server version 6.2.5 on RHEL 7.9. I can start REDIS with the user I want to run it as from the command line. But when I try to start it as a systemd service with the REDIS.service file:
[Unit]
Description=REDIS Service
After=syslog.target network.target remote-fs.target nss-lookup.target
[Service]
Type=simple
User=myuser
Group=myuser
WorkingDirectory=/app/redis
ExecStart=/bin/redis-server /app/redis/primary.conf
Restart=on-failure
[Install]
WantedBy=multi-user.target
It fails. The journalctl entry shows:
Aug 27 08:57:18 computerName redis-server[119338]: 119338:C 27 Aug 2021
08:57:18.981 # Fatal error, can't open config file
'/app/redis/primary.conf': Permission denied
The redis directory and all of it's files are owned by the user I'm telling to run the service. I even went to the extent of putting 777 on the directory and files. Thanks for any help you can give me!
Eric
This server was a mess. There was previous install of redis on the server, the rpm database was corrupt, there were old services that weren't running but were still there. I had to do a lot of cleanup and perform a clean install and it started working.

XAMPP apache will not start

I had to reinstall my max with El capitan, and I had XAMPP working with mysql and apache able to start servers. Now my apache server isn't able to start so I can't get to phpmyadmin to do some schoolwork.
I've looked around and saw that it could be a port 80 or 81 issue, so I checked and saw that no applications were currently using the port, either way I still got a no go.
I tried through terminal to see an error message,
Starting XAMPP for Mac OS X 5.6.30-0...
XAMPP: Starting Apache...fail.
XAMPP: Starting diagnose...
XAMPP: Sorry, I've no idea what's going wrong.
XAMPP: Please contact our forum http://www.apachefriends.org/f/
Last 10 lines of "/Applications/XAMPP/xamppfiles/logs/error_log":
tail: /Applications/XAMPP/xamppfiles/logs/error.log: No such file or directory
XAMPP: Starting MySQL...ok.
Contents of "/Applications/XAMPP/xamppfiles/var/proftpd/start.err":
C02L58UUFFT1.corp.proofpoint.com proftpd[1780]: warning: unable to determine IP address of 'C02L58UUFFT1.corp.proofpoint.com'
C02L58UUFFT1.corp.proofpoint.com proftpd[1780]: error: no valid servers configured
C02L58UUFFT1.corp.proofpoint.com proftpd[1780]: Fatal: error processing configuration file '/Applications/XAMPP/xamppfiles/etc/proftpd.conf'
C02L58UUFFT1:~ sblomquist$ lsof -i ':80'
C02L58UUFFT1:~ sblomquist$ lsof -i ':81'
Thought I would post my problem here while I browse around for more possible solutions.
Update your system and install net-tools
On ubuntu, sudo apt update then sudo apt install net-tools -y restart your server

Redis "Fatal error, can't open config file 'restart'" after a crash

So after restarting my httpd redis crashed (due to the number of sudden requests sent via httpd and written on redis) and now when I try to restart redis on my centos 6.5 server I get the following error:
[root#host /]# /usr/sbin/redis-server restart
[1705] 17 Apr 00:30:49 # Fatal error, can't open config file 'restart'
I have also tried to login to redis using redis-cli and I get an error stating the connection to the server failed.
What options do I have to safely restart the server?
From the /src directory where you downloaded and unzipped your redis source, run the following. This is for RHEL based systems.
make install
# (OR)
sudo cp src/redis-server /usr/local/bin/
sudo cp src/redis-cli /usr/local/bin/

Can't add Apache to start at boot with chkconfig (opensuse 13.1)

I'm running opensuse 13.1, and I installed Apache2 as part of LAMP.
Apache2 works just fine, except I can't make it start automatically with boot.
I used "chkconfig -a apache2" command (as described here)
which gives an error "apache2: unknown service".
Appreciate any hints.
Apache2 has been migrated to systemd. chkconfig works only for SysV services.
The following command (apparently) worked for me:
systemctl enable apache2.service
It seems that the OpenSUSE doc is out of sync.
Find the name of the service:
ls -al /etc/init.d/
(Look for apache or httpd)
Then use that name in chkconfig.

Unable to write files in virtual host setup in NGINX / PHP-FPM running on Fedora 20

I have just made a new setup of Fedora 20 on my laptop, earlier I was using Linux Mint, running NGINX / PHP-FPM.
I have been trying to run php scripts that write files or upload files to server, but I am unable to do so, everything else seems to work fine.
I have already tried the obvious "chmod 777" and "chown -R nginx", etc. but the problem still persists.
Got it working with SELinux enabled,
Last command was:
setsebool -P httpd_can_network_connect 1
Referred to this blog: http://blog.frag-gustav.de/2013/07/21/nginx-selinux-me-mad/