How to increase your Wi-Fi connection speed

Problem:

You have a slow Wi-Fi connection speed.

You want to increase your Wi-Fi connection speed.

Solution:

Execute below command on Windows:

netsh wlan show interface
  • If your Signal is less than 20% then try to increase your Wi-Fi signal strength by moving your device closer to your Wi-Fi router.
  • If you cannot change your device and Wi-Fi router location then try connecting your Wi-Fi router to another Wi-Fi router (Wi-Fi extender) that acts as a new access point using LAN cable.
  • If you cannot use a LAN cable then try connecting your router to a Wi-Fi repeater that is closer to your device.
  • If your Radio type is 802.11n then try to upgrade both your device and router to support 802.11ac.
  • Try to upgrade your Wi-Fi router to support 5 GHz band.
  • Try to upgrade your Wi-Fi router to support MU-MIMO (which stands for Multi-User, Muliple Input, Multiple Output).
  • Compare Receive rate (Mbps) and Transmit rate (Mbps) before and after making a change.
  • Use Speedtest to compare your Wi-Fi connection speed before and after making a change.

How to add multiple IPs to an Amazon EC2 virtual machine

Motivation:

You have a Server 2008 R2 machine on Amazon EC2.

You want to secure multiple domains using different  SSL/TLS certificates.

Server 2008 R2 does not support Server Name Indication (SNI). Therefore you need to add multiple IPs to the machine to use different SSL/TLS certificates.

Solution:
  1. Create an EC2 virtual machine.
  2. Create an EC2 network interface.
  3. Assign the network interface to the machine using the Attach feature in the Network Interfaces tab.
  4. Create multiple private IPs for the network interface using Manage IP Addresses feature.
  5. Allocate multiple elastic IPs in the Elastic IPs tab.
  6. Assign an elastic IP to a private IP of the network interface using the Associate Address feature in the Elastic IPs tab.
  7. Login Windows.
  8. View the network configuration using below command.
ipconfig /all

9. Manually configure the network adapter (Local Area Connection Network) using the information in the 8th step.

10. Add the private IPs in the 4th step to the machine in the Advanced TCP/IP Settings screen.

11. Restart the machine.

If you get any issue then try limit the number of private IPs of a network interface to 4 (including the default private IP)

How to move a WordPress instance from one server to another Linux server

Motivation:

You want to move a WordPress instance from one server to another to consolidate your websites to reduce cost.

Solution:

Install and use below Duplicator plugin to achieve your goal.

https://wordpress.org/plugins/duplicator/

User guide: https://snapcreek.com/duplicator/docs/quick-start/

If everything goes well for you then congratulation!

Otherwise, please review below possible problems and corresponding solutions.


Problem 1:

You don’t have a website on the new server.

Solution 1:

1. Create a new virtual host in the /etc/httpd/conf/httpd.conf

<VirtualHost *:80>
ServerName example.com
ServerAlias www.example.com
DocumentRoot "/var/www/www.example.com"
</VirtualHost>

2. Set 775 permission for /var/www/www.example.com

3. Restart httpd service

sudo systemctl restart httpd

Problem 2:

You are using Amazon Linux 2 server.

You are logged in as ec2-user.

You use WinSCP to upload files and edit configuration files.

You cannot modify /etc/httpd/conf/httpd.conf and /etc/php.ini.

Solution 2:

1 View permission settings for the file

ls -ld /etc/httpd/conf/httpd.conf

The result indicates that the file owner is root user and root group, not ec2-user.

2. View groups of a user

groups ec2-user

The result indicates that the ec2-user does not belong to root group.

3. Add a user to root group

sudo usermod -a -G root ec2-user

4. Grant Read-Write permission against a file to root group

sudo chmod g+rwx /etc/httpd/conf/httpd.conf
sudo chmod g+rwx /etc/php.ini

5. Logout and login to the server again.


Problem 3:

You are using Amazon Linux 2 server. The ZipArchive feature is missing.

Solution 3:

1. Execute below commands:

sudo amazon-linux-extras install php7.2
sudo yum install php-pear php-devel gcc libzip-devel zlib-devel
sudo pecl install zip-1.13.5 # we must specify a slightly older version due due to compatibility

2. Add “extension=zip.so” to /etc/php.ini

3. Restart the server

sudo reboot

Problem 4:

You don’t have a WordPress database on the new Linux server.

Solution 4:

Execute below MySQL commands:

CREATE USER 'username'@'localhost' IDENTIFIED BY 'password';
CREATE DATABASE `wp_database`;
GRANT ALL PRIVILEGES ON `wp_database`.* TO "username"@"localhost";
FLUSH PRIVILEGES;

Problem 5:

An database error occurs while restoring a website.

Solution 5:

1. Execute below commands to remove the website:

sudo chown -R ec2-user:apache /var/www/example.com
sudo chmod 2775 /var/www/example.com && find /var/www/example.com -type d -exec sudo chmod 2775 {} \;
find /var/www/example.com -type f -exec sudo chmod 0664 {} \;
rm -r /var/www/example.com

2. Upload the Duplicator files again, and restore the website again.


Problem 6:

No write access against /var/www/example.com is available for Duplicator.

Solution 6:

1. Execute below commands:

sudo chown -R ec2-user:apache /var/www/example.com
sudo chmod 2775 /var/www/example.com && find /var/www/example.com -type d -exec sudo chmod 2775 {} \;
find /var/www/example.com -type f -exec sudo chmod 0664 {} \;

2. Run http://example.com/installer.php again.