How to fix exim Could not complete sender verify

Check if you can reach a remote server

dig a gmail.com

If this timeouts then try over one of dns resolver directly

[~]# dig @8.8.8.8 a gmail.com

; <<>> DiG 9.11.4-P2-RedHat-9.11.4-26.P2.el7_9.2 <<>> @8.8.8.8 a gmail.com
; (1 server found)
;; global options: +cmd
;; connection timed out; no servers could be reached

Timeout means DNS resolver is dead

[~]# cat /etc/resolv.conf
Read the rest

How to change WordPress site URL and home URL using wp-cli tool

To check site url:

wp option get siteurl

To update your website’s URL:

wp option update home 'https://alltime.pp.ua'
wp option update siteurl 'https://alltime.pp.ua'

This will update to MySQL records “home” and “siteurl

To run in-deep updates read the following article:

https://alltime.pp.ua/blog/how-to-change-wordpress-main-url-to-new-one/Read the rest

How to install/reinstall mailman on cPanel server

Check Tweak Settings, should be ‘0’

cat /var/cpanel/cpanel.config |grep skipmailman

skipmailman=0

Deprecated scripts

/scripts/reinstallmailman
/usr/local/cpanel/bin/mailman-install --force

Deprecated scripts:

/usr/local/cpanel/scripts/update_local_rpm_versions --edit target_settings.mailman installed
/usr/local/cpanel/scripts/check_cpanel_rpms --fix --targets=mailman

The latest way to reinstall mailman on cPanel server:

rpm -e --nodeps cpanel-mailman
/usr/local/cpanel/scripts/check_cpanel_rpms --fix --targets=mailman

Run upcp:

/scripts/upcp --force
systemctl start mailman.service
Read the rest

How to create a post using wp-cli

Install wp-cli and run something like the following:

wp post create --post_type=page --post_status=publish --post_title='Home' 
wp post create --post_type=page --post_status=publish --post_title='About'
wp post create --post_type=page --post_status=publish --post_title='News'
wp post create --post_type=page --post_status=publish --post_title='Contact'
Read the rest

How to reset MySQL root password

Stop MySQL server

service mysqld stop

Start in safe mode

mysqld_safe --skip-grant-tables &

Login mysql server

mysql

Reset your root password

UPDATE mysql.user SET Password=PASSWORD('strong-password-here') WHERE User='root';
FLUSH PRIVILEGES;
exit;

Shutdown your mysql server

mysqladmin -u root -p shutdown

Start your mysql server again

service mysqld start
Read the rest

How to fix “Sorry, you are not allowed to access this page.”

Using WP-CLI

If you see an empty ROLES then it is

wp user list
+----+------------+--------------+--------------------------------+---------------------+---------------+
| ID | user_login | display_name | user_email            | user_registered                | roles |
+----+------------+--------------+--------------------------------+---------------------+---------------+
| 1  | admin1     | admin1           | [email protected] | 2018-06-19 17:00:02 |         |
+----+------------+--------------+--------------------------------+---------------------+---------------+

So add admin right for this user:

wp user set-role 1 administrator

Check it, should be good now:

wp user list
+----+------------+--------------+--------------------------------+---------------------+---------------+
| ID | user_login | display_name | user_email            | user_registered                | roles |
+----+------------+--------------+--------------------------------+---------------------+---------------+
| 1  | admin1     | admin1           | [email protected]
Read the rest