Questions tagged [apache2]
Use this tag for question related to configuring and using Apache on Ubuntu or one of Ubuntu's official derivatives.
398
questions
7
votes
2
answers
16k
views
How can I get Apache to use PHP 7.0 (not 7.1)?
When setting up a Ubuntu 16.04 vhost, Apache will use
PHP 7.0.22-2+ubuntu16.04.1+deb.sury.org+4.
However, after trying to resolve some conflicts by doing apt-get dist-upgrade (and failing), I ended ...
7
votes
1
answer
14k
views
Apache2.4.7 on Ubuntu 14.04 won't execute Python cgi file. The site displays python code instead
Description of problem:
When I load 127.0.0.1/cgi-bin/test.cgi in my browser my test.cgi is treated like a text file instead of a python file.
Ruling out the possibility of the error being related ...
7
votes
1
answer
20k
views
How to configure apache and iptables to allow incoming connections ubuntu server?
I am trying to configure my server to allow apache running on port 80 to allow incoming connections. I ran this command
sudo iptables -A INPUT -i eth0 -p tcp --dport 80 -j ACCEPT
But Still I can't ...
6
votes
2
answers
21k
views
How do I turn on SSL for test server?
I have a LAMP stack running. My the web root is /var/www.
So if I go to http://linux-server/some/page.php It renders the page located at /var/www/some/page.php
If I use https I get page not found.
...
6
votes
6
answers
105k
views
Forbidden You don't have permission to access /phpmyadmin on this server
I installed php, mysql, phpmyadmin on my Ubuntu 12.04 localhost in the following steps:
I try these steps:
sudo apt-get install apache2
sudo /etc/init.d/apache2 restart
sudo apt-get install php5 ...
6
votes
1
answer
20k
views
apache2-mpm-worker missing in Ubuntu 16.04
I would like to install apache2-mpm-worker on Ubuntu 16.04, but it looks that this package is not avalaible for ubuntu 16.04.
Do you have somebody any information why this important package is missing ...
6
votes
2
answers
29k
views
How to install php8.0-mbstring for php8.0? It keeps installing to php7.2
I am trying to install Laravel. I am on Ubuntu 18.04.5 LTS, have php 8.0.2, and running Apache2. My issue is that I can't install Laravel as it keeps giving the error that I don't have the 'mbstring' ...
6
votes
5
answers
24k
views
Apache not allowing PHP to create file
I am trying to save data using HTML and PHP in localhost in Ubuntu. My HTML & PHP files are working great but when I am using commands to open a file in the localhost using
$myfile = fopen("...
6
votes
1
answer
14k
views
How to give a specific user access only to a specific folder and its contents?
I used
adduser <name>
and created a new user, andrew. Now I want to give him read/write access only to /var/www/sitename.com and its contents.
How am I supposed to do this?
I tried sudo ...
6
votes
1
answer
7k
views
Apache and SSL Issues
I have my server set up to use SSL in a separate VirtualHost, but when I attempt to use https://my.domain, I get a connection refused error. The following is my config I'm using:
<VirtualHost 173....
6
votes
3
answers
14k
views
Disable SSLv3 in Apache2 on a clean install of ubuntu 14.04.1 Server
I have a new install of ubuntu server version 14.04.1
I have apache2 with SSL enabled.
I want to disable SSLv3
(I am aware this is a popular question but I have trawlled all other answers on multiple ...
6
votes
1
answer
26k
views
I always get "No such file or directory: apache2: could not open error log file /etc/apache2/$ apache_log_dir /error.log" how cat I fix this
I am using Ubuntu Studio 12.04 and when I am trying to start apache2, I get this error message:
No such file or directory: apache2: could not open error log file /etc/apache2/$ apache_log_dir /error....
6
votes
3
answers
28k
views
Force https:// and www. with virtual host apache2
I've been looking everywhere for a solution to be able to force https ://www in front of all my URL's using virtual host. This is what I currently have in my 000-default.conf file:
<VirtualHost *:...
5
votes
1
answer
5k
views
Opening a port to an application accessible outside of localhost?
Though I have researched this all day, I still can not find a solution to this issue.
On my Ubuntu Server I am trying to run a node.js application that simply prints out "Hello World" and runs on ...
5
votes
1
answer
110k
views
Failed to start The Apache HTTP Server
● apache2.service - The Apache HTTP Server
Loaded: loaded (/lib/systemd/system/apache2.service; enabled; vendor pres
Active: **failed** (Result: exit-code) since Sun 2018-07-08 22:32:36 SAST; 18
...
5
votes
1
answer
16k
views
Getting Errors while installing php on ubuntu16.04
Command: sudo apt-get install php7.0
Output:
Reading package lists... Done
Building dependency tree
Reading state information... Done
php7.0 is already the newest version (7.0.8-0ubuntu0.16....
5
votes
1
answer
12k
views
How to remove application in ufw app list Available applications?
I want to remove Apache, Apache Full, Apache Secure in this list.
I have Nginx server. But, when I install phpmyadmin on nginx server, I had a problem. After that I saw Apache, Apache Full, Apache ...
5
votes
2
answers
32k
views
PHP 7 and apache displays plain text and cannot be restarted
I just switched over to Ubuntu from Windows and am trying to get php 7 and Apache working.
I'm running php 7 and apache 2.4.18
PHP 7.0.4-7ubuntu2.1 (cli) ( NTS )
Server version: Apache/2.4.18 (...
5
votes
1
answer
3k
views
"loop involving service": apt-get install breaks dpkg
One apt-get install went bad, now every apt command fails.
Obligatory dump from sudo apt-get install apache2
Reading package lists... Done
Building dependency tree
Reading state information......
5
votes
2
answers
43k
views
Unable to start Apache2 with Error AH00526: Syntax error - Invalid command $
Recently I re-installed Apache because of some problem but since then this particular error is failing it to start.
There are related answers which I have tried like below but that too not effective:
...
5
votes
3
answers
23k
views
Portforwarding from host to guest using port 80, but it doesn't work
I installed ubuntu server inside a virtual box(11.04), then i configured apache.
Inside virtual box setting, i made a port forwarding from port 80(host) to 80(guest), i open my web browser on my ...
5
votes
2
answers
74k
views
Apache 2.4.10 giving 403 Forbidden issue on Ubuntu 14.04
I am setting up PHP environment. Now when I have started to add my sites from windows/xampp backup (mentioning so just in case any path related issue)
I have created new project (netbeans) and ...
5
votes
3
answers
363
views
How do I install and use Apache?
I have downloaded ubuntu Desktop. I want to create a web server to host Test Web Sites to show my potential clients. Any suggestions, tips, or good direction for me? My plan is to download Apache and ...
4
votes
4
answers
45k
views
Access forbidden 403 error in xampp
I am very new to xampp. I have made a fresh xampp install with the following commands.
sudo su
cd /tmp
wget bit.ly/1cmyrUo -O xampp-32bit.run
chmod 777 ./xampp-32bit.run
sudo ./xampp-32bit.run
Then ...
4
votes
1
answer
23k
views
AH00051: child pid XXXXX exit signal Segmentation fault (11), possible coredump in /etc/apache2
I have upgraded to mysql 5.7 using this MySQL 5.5 Update to MySQL 5.7
Since then we have been receiving 500 on all hosted websites and apache2 error log contains
[Thu Jul 07 03:52:24.807409 2016] [...
4
votes
1
answer
19k
views
apache2 is not a native service
I am trying to enable apache2 after installing it in my OS. My OS is Ubuntu 16.04 LTS. After installing, I'e given these orders in the console -
sudo systemctl start apache2
sudo systemctl restart ...
4
votes
2
answers
14k
views
403 Forbidden Error when accessing enabled virtual host
When accessing a site defined in my local dev environment, I can't seem to get past a 403 Forbidden error.
Under /etc/apache2/sites-available/ I have defined a file fun.local:
<VirtualHost *:80&...
4
votes
1
answer
6k
views
How to setup sudoers for Apache web service?
# User privilege specification
root ALL=(ALL:ALL) NOPASSWD: ALL
apache ALL=(ALL:ALL) NOPASSWD: ALL
me ALL=(ALL:ALL) NOPASSWD: ALL
In Fedora both works:
http://localhost/test
echo shell_exec("sudo ...
4
votes
5
answers
37k
views
Unable to start Apache Tomcat 8.5.4 on Ubuntu 16.04
I have installed the following distribution of Tomcat: http://mirror.its.dal.ca/apache/tomcat/tomcat-8/v8.5.4/bin/apache-tomcat-8.5.4.tar.gz
I have followed this instruction step by step: https://www....
4
votes
1
answer
3k
views
Apache not rendering Bugzilla cgi
I've just tried to install Bugzilla on my machine for test purposes. I'm going to evaluate the Bugzilla REST API for a company i'm currently interning at. The problem is that when I go to http://...
4
votes
2
answers
2k
views
Prevent user from viewing and editing /var/www folders
I need to be able to restrict a secondary user that I'm creating from even viewing /var/www as it contains some sensitive information in its PHP files.
Currently, the user is able to view the files (...
4
votes
2
answers
11k
views
Making Apache secure on Ubuntu 14.04
I am wanting to host a small site at home and have installed Apache etc like this :
sudo apt-get update
sudo apt-get install tasksel
sudo tasksel install lamp-server
That all worked and everything ...
4
votes
1
answer
2k
views
How to rebuild/reconfigure the HTTP Apache server after upgrading to PHP 7.0.* on 64-bit Ubuntu 14.04 LTS?
Previously I was using PHP 5.5.32 on my system, everything was working fine. All the PHP programs and projects were running successfully.
Today, I upgraded to PHP 7.0.4 and the trouble starts for me. ...
4
votes
2
answers
7k
views
Running Apache and Tomcat together on different subdomains?
Posted this on ServerFault but didn't get a response. Hoping I will have better luck on the Ubuntu site.
I have been trying to get this working the whole of today. I have a server which resolves to ...
4
votes
2
answers
10k
views
How can I reinstall redmine?
I have a redmine setup. today morning I saw that my redmine folder was empty and I was unable to access redmine, so I tried installing redmine again using:
sudo apt-get install redmine
I am getting ...
4
votes
1
answer
3k
views
How to give Public_html to each user?
I have a new installation of Ubuntu 12.04 and I want to have 2 or more users be able to test with apache/php/mysql.
Within default config at sites-available I added two different VirtualHosts, one ...
4
votes
3
answers
7k
views
Upgrading Apache to 2.2.23 on ubuntu 12.04 LTS
We had done a PCI scan on one of our servers running Ubuntu 12.04 LTS with apache 2.2.22.
The scan reported a vulnerability in apache 2.2.22 (Apache HTTP Server Zero-Length Directory Name in ...
3
votes
1
answer
2k
views
Is it safe to turn on unattended upgrades for a live Ubuntu Webserver (Nginx/Apache)?
I was wondering whether it is safe to have the unattended-upgrades package keep the system up to date on a live webserver.
Here I am specifically wondering whether issues might occur when packages ...
3
votes
2
answers
12k
views
phpmyadmin not working because i changed permissions and don't know how to change it back
I installed LAMPP and it worked fine, but i somehow managed to change the permission of the folder /opt/lampp/ to 777 by using this command
sudo chmod 777 -f /opt/lampp -R
My plans was to do:
sudo ...
3
votes
2
answers
6k
views
Why do I get a 403 error when accessing my apache server?
Im running Ubuntu 12.04 LTS on a system with 2 GB RAM and a 500 GB HDD.
My hard drive has 4 partitions:
Partition 1 = 40 gb Windows (NTFS, lable = win32)
Partition 2 = 320 gb Windows (FAT label = ...
3
votes
2
answers
44k
views
Apache 2: Syntax error on line 225 of /etc/apache2/apache2.conf
Can anyone help??
# This is the main Apache server configuration file. It contains the
# configuration directives that give the server its instructions.
# See http://httpd.apache.org/docs/2.4/ for ...
3
votes
1
answer
1k
views
I uninstalled my apache2 from Ubuntu, now I am unable to reinstall it
I Uninstall my apach2 from Ubuntu because it looks not working now I tried to install it again with the command sudo apt install apache2
and I can see the below errors
E: Failed to fetch http://...
3
votes
1
answer
2k
views
Cannot shutdown apache2 on 16.04 LTS
I'm trying to set up a small VPS. When it was provisioned for me I was given the ip address , which dispays an apache2 page. I'd prefer to set things up using nginx. I asked the host about switching ...
3
votes
1
answer
9k
views
Apache (and other services) work on localhost, but not IP address
My Apache server is working correctly on port 80.
When I try to enable SSL on port 443, I can connect via localhost (telnet localhost 443) but not via IP address (telnet xxx.xxx.xxx.xxx 443).
To ...
3
votes
1
answer
160
views
problem restarting apache2
When trying to restart apache2,
I type:
sudo /etc/init.d/apache2 restart
Response I get:
Could not reliably determine the server's fully qualified domain name
Can anyone tell me what I'm doing ...
3
votes
3
answers
10k
views
Why is Apache failing to restart? "review the situation by hand"
ubuntu@fast:~$ /etc/init.d/apache2 restart
* Restarting web server apache2 [fail]
* There are processes named 'apache2' running which do not match your
...
3
votes
1
answer
5k
views
The latest upgrade disables php7 for apache2 [closed]
Please let me know what logs you need to be able to solve this..
root@BudanParakeet:/etc/apache2/mods-enabled# uname -v
#19-Ubuntu SMP Wed Oct 11 18:33:49 UTC 2017
root@BudanParakeet:/etc/apache2/...
3
votes
1
answer
18k
views
How to add an html page in the apache2 root?
I've installed apache2 on ubuntu and I want to add an html page on it's root to see if it works. How can I do it?
3
votes
1
answer
2k
views
Using native connection while still connected to a vpn
I'm setting up a vpn server on a remote development server. The development server has websites that I'm developing and the vpn is in place so that I can tell apache to only accept local connections ...
3
votes
5
answers
9k
views
PHP FPM Working, but ignoring version from SetHandler
Our server is Ubuntu 18.04.5 LTS (GNU/Linux 4.15.0-135-generic x86_64).
We followed the directions from https://tecadmin.net/install-multiple-php-version-apache-ubuntu/ a while back and got PHP 5.6 ...