Solving the “Autoload error” when installing Magento

Once installed Magento in Ubuntu and noticed in the browser the following error:

Autoload error

There were also pieces of code, depending on the open page.

In my case, the error occurred because of the uninstalled libapache2-mod-php, installed it with the command:

sudo apt-get install libapache2-mod-php

After that the error did not appear and I continued the installation of Magento.

Installing Remmina on Linux

Remmina – remote desktop client, supports SSH, VNC, RDP, NX, SFTP, XDMCP.

You can install Remmina in Ubuntu/Debian using the command:

sudo apt-get install remmina

Install in CentOS:

yum install remmina

Run with the command:

remmina

After launching it is enough to specify the address of the node and enter the login/password.
On the test through the Remmina client, I successfully connected to the remote desktop of Windows 10.

See also:
Installing xrdp on Ubuntu

Installing xrdp on Ubuntu

xrdp – RDP server for Linux

It is installed in Ubuntu with the following command:

sudo apt-get install xrdp

To connect to an xrdp server from Windows, you can use the standard Remote Desktop client by typing mstsc.exe at the command prompt.
The configuration is located here /etc/xrdp/, logs are written here – /var/log/xrdp-sesman.log

You can restart xrdp like this:

sudo /etc/init.d/xrdp restart

You can also install the Xfce graphical shell:

sudo apt-get -y install xfce4

And specify it by default.

echo xfce4-session >~/.xsession

I recommend not using root user to work in a graphical environment, but create an individual user.
See my article – Administering Ubuntu Users

Create email aliases in iCloud Mail

Mail aliases allow you to hide the current mail address.

To create them, you need to open the “Mail” application on iCloud.com, select “Settings”, “Accounts” and “Add aliaas”.
Incoming messages for the created alias will be highlighted with the color that was specified when adding.
The created aliases can be disabled or deleted.

On the phone or computer to send messages from the created alias, you must select it in the mail settings.

Installing and Configuring Zabbix Server on Linux Ubuntu

Zabbix — system monitoring, tracking servers and network equipment.

Below I will give an example of installing Zabbix Server and Zabbix Agent from the official Ubuntu repository, if you need to install the latest version, you must first install Zabbix repositories, for example, see my article – Installing Zabbix Server 3.4 on Ubuntu 16.04

Install the server, web interface and agent:

sudo apt-get install zabbix-server-mysql zabbix-frontend-php zabbix-agent traceroute fping

If during the installation did not configure the mysql parameters, then manually create the MySQL user and complete the rights to the database:

mysql -uroot -p
create database zabbix character set utf8 collate utf8_bin;
grant all privileges on zabbix.* to zabbix@localhost identified by 'PASSWORD';
exit

We import tables into the database:

cd /usr/share/zabbix-server-mysql
sudo gunzip schema.sql.gz
sudo gunzip images.sql.gz
sudo gunzip data.sql.gz
mysql -uroot -p zabbix < schema.sql
mysql -uroot -p zabbix < images.sql
mysql -uroot -p zabbix < data.sql

Configs are located at /etc/zabbix/

The web interface configuration is located at /etc/apache2/conf-available/zabbix
If it does not exist, you can copy the template and configure:

sudo cp /etc/zabbix/apache.conf /etc/apache2/sites-enabled/zabbix.conf

Or we will make a symbolic link to the web server directory on the zabbix files:

sudo ln -s /usr/share/zabbix/ /var/www/html/

Open the configuration file PHP for example in the editor nano (CTRL+X for exit, y/n for saving or canceling the changes):

sudo nano /etc/php5/apache2/php.ini

And change some of the minimum parameters:

date.timezone = Europe/Kiev
max_execution_time 300
memory_limit 128M
post_max_size 16M
upload_max_filesize 2M
max_input_time 300

For the changes to take effect, you must restart the web server:

sudo /etc/init.d/apache2 restart

Open the web interface at http://SERVER/zabbix/ and follow the prompts for further installation.
By default, the user name for logging in through the web interface is admin, the password is zabbix.
When saving the configuration file zabbix.conf.php there will be a message that there is no write permission, so we will temporarily allow them:

sudo chmod 777 /etc/zabbix

When the configuration file is saved back:

sudo chmod 755 /etc/zabbix

Also, in the second configuration file zabbix_server.conf, the login and password for connecting to the MySQL database (same as in zabbix.conf.php):

sudo nano /etc/zabbix/zabbix_server.conf

If the message appears in the web interface that the zabbix server is not running, then you need to change the START=no parameter to START=yes in the /etc/default/zabbix-server file and execute the start command:

sudo service zabbix-server start

After installation, I recommend changing the password to admin and disabling the guest user.

Installing Zabbix Server 3.4 on Ubuntu 16.04

On the test I will install Zabbix Server 3.4 in Ubuntu Server 16.04.

First of all, we will install a repository with Zabbix 3.4 version for Ubuntu 16.04, as the old version is available in the official Ubuntu repository:

sudo wget http://repo.zabbix.com/zabbix/3.4/ubuntu/pool/main/z/zabbix-release/zabbix-release_3.4-1+xenial_all.deb
sudo dpkg -i zabbix-release_3.4-1+xenial_all.deb
sudo apt update

Now run the Zabbix Server and Zabbix Agent installation command:

sudo apt install zabbix-server-mysql zabbix-frontend-php zabbix-agent

Connect to MySQL:

mysql -uroot -p

Create the database and the user:

create database zabbix character set utf8 collate utf8_bin;
grant all privileges on zabbix.* to zabbix@localhost identified by 'PASSWORD';
quit;

I import the tables into the created database:

zcat /usr/share/doc/zabbix-server-mysql*/create.sql.gz | mysql -uzabbix -p zabbix

Open the configuration file in a text editor and where “DBPassword” is the password for the database:

sudo nano /etc/zabbix/zabbix_server.conf

Open the configuration file in a text editor and where “DBPassword” write the password to the database:

systemctl restart zabbix-server zabbix-agent
systemctl enable zabbix-server zabbix-agent

To restart it is still possible so:

sudo service zabbix-server start

In php.ini, specify the date.timezone, for example Europe/Kiev, or uncomment it in /etc/zabbix/apache.conf if it is copied to the web server configuration:

sudo cp /etc/zabbix/apache.conf /etc/apache2/sites-enabled/zabbix.conf

Or we will make the link where we need:

sudo ln -s /usr/share/zabbix/ /var/www/html/

Open the web interface at http://SERVER/zabbix/ and follow the prompts for further installation.
By default, the user name for logging in through the web interface is admin, the password is zabbix.

See also my article:
Installing and Configuring Zabbix Server on Linux Ubuntu

Updating phpBB 3.1.x to phpBB 3.2.x

On the test, I will update the phpBB 3.1.9 forum to the version of phpBB 3.2.2.

System requirements phpBB 3.2 if necessary, you can see here https://www.phpbb.com/support/docs/en/3.2/ug/

Be sure to make a backup copy of the database and forum files.

I recommend that you perform an update on the test virtual server, running a copy of the forum from the backups, because in my case there were errors and it took them a while to fix them, and then you can update them to the main one in a similar way quickly.

We proceed to update, download the archive with the new version of phpBB 3.2.x and unpack it:

wget https://www.phpbb.com/files/release/phpBB-3.2.2.zip
unzip phpBB-3.2.2.zip

In the unpacked forum data, delete the file config.php and these directories: files/, images/, store/.

In the phpBB data, what’s on the web server will be deleted except for the ext/, files/, images/, store/ and config.php file.

Move the remaining downloaded data to the directory with the forum data, agree to overwrite the file in the ext/ directory.

If the rights to files and owner change, for example, you can specify them as follows:

sudo chown -R www-data:www-data /var/www/forum/

If the database of the forum is large, then you can execute the command in the root directory of the forum:

php ./bin/phpbbcli.php db:migrate --safe-mode

Open the forum address in the browser by adding /install/app.php/update or /install/database_update.php at the end, select the “Update” tab, select “Update database only”, start the update process and wait for the completion.

After the successful update, delete the install directory:

rm install

See also my articles:
Solution of error “A module already exists” and “The installer detected a timeout” when updating phpBB
Import and export MySQL databases
Updating phpBB 3.1.8 to phpBB 3.1.9
Updating phpBB 3.0.x to phpBB 3.1.x
Other about phpBB

Solution of error “A module already exists” and “The installer detected a timeout” when updating phpBB

I updated phpBB 3.1.9 once to phpBB version 3.2.2 and noticed the following error:

The installer detected a timeout
The installer has detected a timeout, you may try to refresh the page, which may lead to data corruption. We suggest that you either increase your timeout settings or try to use the CLI.

Cleaned the table “phpbb_migrations” in the forum database:

TRUNCATE TABLE phpbb_migrations;

And again launched the update, but got another error:

A module already exists: UCP_AUTH_LINK_MANAGE

The standard Profile module was naturally installed, it could be disabled, but not deleted.
Therefore, I found it in the “phpbb_modules” table and deleted it, thus causing the update script to think that it is not installed:

SELECT * FROM `phpbb_modules` WHERE `module_langname` LIKE 'UCP_AUTH_LINK_MANAGE';

After continuing the update noticed another error:

A module already exists: ACP_CONTACT_SETTINGS

The Contact module was not even installed, after that I also found it in the table and deleted it, and also found and deleted “UCP_AUTH_LINK_MANAGE” once again, because the update script restored it:

SELECT * FROM `phpbb_modules` WHERE `module_langname` LIKE 'ACP_CONTACT_SETTINGS';
SELECT * FROM `phpbb_modules` WHERE `module_langname` LIKE 'UCP_AUTH_LINK_MANAGE';

After removing the modules from the “phpbb_modules” table, I cleared the “phpbb_migrations” table:

TRUNCATE TABLE phpbb_migrations;

I launched the phpBB update and it was successful.

See also:
Updating phpBB 3.0.x to phpBB 3.1.x

The solution to the warning “mismatch_cnt is not 0 on /dev/md*”

Replaced once the junk drive in the software RAID1, added it to the raid, it successfully synchronized, installed GRUB.
After a while I received an email message:

Subject: Cron <root@server> /usr/sbin/raid-check
WARNING: mismatch_cnt is not 0 on /dev/md2

In my case, raid-check found that the mismatch_cnt counter is not equal to 0 for /dev/md2, which means that there may be broken sectors on the disk, or it simply needs to be resynchronized. Since I installed GRUB after adding the disk to the raid, this is probably the cause.

Example of viewing the counters of all arrays:

cat /sys/block/md*/md/mismatch_cnt

Or each in turn:

cat /sys/block/md0/md/mismatch_cnt
cat /sys/block/md1/md/mismatch_cnt
cat /sys/block/md2/md/mismatch_cnt

View the status of raids:

cat /sys/block/md*/md/sync_action

If mismatch_cnt is not 0 for any array, then you can try to resynchronize it:

echo 'repair' >/sys/block/md2/md/sync_action

And check:

echo 'check' >/sys/block/md2/md/sync_action

If you want to cancel the action:

echo 'idle' >/sys/block/md2/md/sync_action

Let’s see the synchronization status and other data of the array:

cat /proc/mdstat

If errors appear due to a bad disk, I recommend that you look at SMART and check it as I wrote in these articles:
Diagnostics HDD using smartmontools
Linux disk test for errors and broken sectors

See also:
How to fix the problem with mdadm disks