Hot answers tagged

31 votes
Accepted

How to enable use of .htaccess in Apache on Ubuntu?

First Step Open file as sudo vim /etc/apache2/apache2.conf Second Step remove comment sign (#) if you find it before this line ( line number 187 approx.) AccessFileName .htaccess Third Step ...
user avatar
  • 426
9 votes
Accepted

CheckCaseOnly doesn't work, while CheckSpelling does

Here is the mod_speling documentation. The CheckCaseOnly directive does not enable the module on its own. You would need to both turn on mod_speling and also put in the check case only directive: ...
user avatar
8 votes

How to enable use of .htaccess in Apache on Ubuntu?

Activate ModRewrite: sudo a2enmod rewrite sudo /etc/init.d/apache2 restart
user avatar
6 votes
Accepted

How to stop domains from pointing to my server IP address and duplicating my site using nginx

To improve security, prevent host header attacks, and preserve your search rankings, here is what I recommend: No default site Simply drop all traffic not matching your genuine website. Before using ...
user avatar
  • 2,241
5 votes
Accepted

Updated Apache from 2.2 to 2.4 and now my sub domains are broken

One of the biggest changes from Apache 2.2 to 2.4 is the way that permissions for directories are granted. The allow from and deny from syntax is now deprecated in favor of the new require syntax. ...
user avatar
5 votes
Accepted

HTTP2 is enabled and working, but PHP $_SERVER['SERVER_PROTOCOL'] still says "HTTP/1.1"

This has to do with how Cloudflare connects to servers. Although it does serve the client via HTTP2 (or HTTP3), it still connects to the server itself via HTTP1.1. Cloudflare only uses HTTP/1.x ...
user avatar
4 votes

Do I need to change the host file of each computer to share a web page on a local network using a hostname?

This depends on how your network is setup. If you have a central DNS server on your network (as many enterprise business networks have) then you can add a zone record for whatever domain you wish for ...
user avatar
4 votes

How to stop domains from pointing to my server IP address and duplicating my site using nginx

It looks to me like your server is set up to redirect to HTTPS, which causes a certificate mismatch error when a visitor tries to load one of these other domains that's pointing at your IP. This is a ...
user avatar
4 votes
Accepted

Vulnerability in /boaform/admin/formLogin?

This appears to be related to a cluster of exploits that target fiber optic routers. If you are running a simple HTTP website and you are not maintaining fiber optic router equipment, I believe you ...
user avatar
3 votes
Accepted

How to create user in phpmyadmin to connect two servers?

Create the remote connection To create a remote connection: On your database server, as a user with root privileges, open your MySQL configuration file. To locate it, enter the following command: ...
user avatar
3 votes
Accepted

Magento Backup using mysqldump

Doesn't matter what directory you run the command in, however it will save the sql dump file into the folder your currently in if using SSH to run the command. If you would like to save the file in an ...
user avatar
  • 32.6k
3 votes
Accepted

Amazon EC2 Ubuntu instance setting up domain name

Your host name also needs to be added to /etc/hosts in 127.0.0.1 section. If you haven't rebooted since editing /etc/hostname you also need to set the hostname using the hostname command. This ...
user avatar
3 votes
Accepted

Do you need to set your network profile as Public or Private when creating your own hosting?

I could not find any other resource about it but I found answer in the comments of my question. I would like to post it as an answer below: This setting does not impact TCP/IP access to your computer, ...
user avatar
  • 149
2 votes

Can't change HTTP Vary header from PHP

Check if you have the environment force-no-vary set to TRUE in your configuration, or simply try to set it to FALSE in your virtual host configuration. More details about this and how you should ...
user avatar
2 votes
Accepted

Add domain to VPS (DNS?)

To get a website up at a domain name you need to follow these steps: Register the domain name. At the registrar, point the NameServer (NS) records to the domain name server (DNS) that will be ...
user avatar
2 votes
Accepted

php5-fpm ping and status pages error out? LimitInternalRecursion error?

Credit to Harold Snel on Ask Ubuntu for answering this for me... He said: I had the same problem. With lots of Google-ing and trying I figured it out. You need to match what you setup in your ...
user avatar
2 votes
Accepted

How do I get a better PHP version to work with Plesk?

I've run into this issue myself, and would recommend not using apt-get and instead installing PHP according to the directions here from Parallels for Multiple PHP Versions in Plesk on Linux: Be sure ...
user avatar
  • 15k
2 votes

Fix OpenSSL CCS vulnerability on Ubuntu 14.04

You can check if your SSL is patched against the OpenSSL CCS vulnerability (CVE-2014-0224): sudo apt-get changelog openssl | grep CVE-2014-0224 If no results are displayed then your server requires ...
user avatar
  • 32.6k
2 votes

Subdomains getting redirected to root directory of virtualhost

As mentioned in comments, I don't see any spurious redirects that you appear to be reporting and the two URLs do appear to return different content (although they "look similar"). So this appears to ...
user avatar
  • 40.9k
2 votes

Not able to see public_html from the AWS EC2 instance when accessed via PuTTY

Using putty terminal using SSH will automatically log you in with the top level directory structure while using FTP will be bound to whatever is set within your config. You will normally find ...
user avatar
  • 32.6k
2 votes
Accepted

Where To Configure SSL On Nginx Reverse Proxy or on Apache2 on Ubuntu 18.04 Server?

Nginx is a reverse proxy in your example, which means it terminates the HTTP exchange. Clients do not know that there is anything after Nginx, for them, Nginx is the webserver and the source of the ...
user avatar
2 votes

HTTP2 is enabled and working, but PHP $_SERVER['SERVER_PROTOCOL'] still says "HTTP/1.1"

Thank you, the QA here helped me to solve my issue. Here are specifics in case others run into similar issues with PHP "detection" incorrectly displaying the protocol behind a proxy such as ...
user avatar
  • 121
2 votes
Accepted

Subdomain folder content returns 404, but root level works

The problem is in a default configuration file that is included with Apache2 from Debian and Ubuntu: /etc/apache2/mods-available/alias.conf which has: # We include the /icons/ alias for FancyIndexed ...
user avatar
1 vote

Can uploaded files override Apache permissions?

"Option 1." Write a script. Something like create_account <student name> will do well. In the script do your create the directory(ies) and then make sure permissions are right. More or less, ...
user avatar
  • 2,153
1 vote

Domains hosted on Ubuntu Server(Plesk) can only send outgoing mails

If you are using Postfix, make sure that you are not trying to send from a send-only SMTP server: How to Install and Configure Postfix as a Send-Only SMTP Server on Ubuntu 16.04 Navigate to /etc/...
user avatar
  • 1,183
1 vote

Apache2 Ubuntu 16.04 Impossible To Get CORS Working

The mod_headers module could be disabled. Try enabling it and reload Apache. sudo a2enmod headers sudo service apache2 reload If you still don't see the header try adding this to your .htaccess file:...
user avatar
1 vote

Apache2 Ubuntu 16.04 Impossible To Get CORS Working

Get rid of the CORS declaration in your .htaccess file as it is only needed in one spot and since you have access to a vhost file it is better off there. A check of the vhost file you provided shows ...
user avatar
1 vote
Accepted

How can I copy files from my machine to Amazon EC2?

As noted in comments, try with scp -v -r -i node.pem /Users/path/to/file/gametest ubuntu@35.164.71.227: so the gametest directory is created in the server. the folder called gametest is ...
user avatar
  • 2,614
1 vote

ErrorDocument Not Working

Thanks to w3dk's questions I was able to work through why my page re-directs weren't working. I was using let's encrypt for my security certificate, and because of (or perhaps my lack of knowledge), ...
user avatar
  • 131
1 vote
Accepted

How do you isolate/silo websites on an Ubuntu w/ LEMP stack?

My answer for NGINX was to create php-fpm pools for each site/virtual host. These pools each have their own user, and that use has no access to any files outside of the pool. So they are totally ...
user avatar
  • 183

Only top scored, non community-wiki answers of a minimum length are eligible