How to change master domain on cPanel server from command line
Run the following to change your master domain:
whmapi1 modifyacct user=USERNAME domain=NEWDOMAIN.COM
Enjoy!… Read the rest
Notes
Run the following to change your master domain:
whmapi1 modifyacct user=USERNAME domain=NEWDOMAIN.COM
Enjoy!… Read the rest
Find rmlist binary file under /usr/local/cpanel/3rdparty/mailman/bin folder
For more info run:
[email protected] [/usr/local/cpanel/3rdparty/mailman/bin]# ./rmlist --help
… Read the restUsage:
rmlist [-a] [-h] listnameWhere:
–archives
-a
Remove the list’s archives too, or if the list has already been
deleted, remove any residual archives.–help
-h
Print this help message and exit.
You need to update the following file:
/etc/wwwacct.conf
Output example:
… Read the restNS yournameservhere.com
CONTACTEMAIL
HOMEDIR /home
ETHDEV eth0
NS4
SCRIPTALIAS y
NSTTL 86400
ADDR6
TTL 14400
HOST yourhostnamehere.com
LOGSTYLE combined
CONTACTPAGER
DEFMOD paper_lantern
ADDR 11.22.33.44
NS2 yournameservhere2.com
DEFWEBMAILTHEME paper_lantern
HOMEMATCH home
NS3 yournameservhere3.com
Enter the path where you have Prestashop installed and run as the following:
cd cache/smarty/compile find . -maxdepth 1 -type d ! -path "." -exec rm -rf {} \; cd - cd cache/smarty/cache find . -maxdepth 1 -type d ! -path "."… Read the rest
Go to your WHM –> Home –> Software –> MultiPHP Manager
You should be able to resolve this by changing the domains to use an available version of PHP, or by installing the missing PHP versions.
You need to either install missed PHP version or set it to inherit
Command line solution:
Find main domain of account in issue and run:
whmapi1 php_set_vhost_versions version=inherit vhost=domainname.com… Read the rest
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
Please try to use one of the following
drush users:list drush user-list drush uinf $(drush sqlq "SELECT GROUP_CONCAT(name) FROM users_field_data") drush uinf $(drush sqlq "SELECT GROUP_CONCAT(uid) FROM users") drush uinf $(drush sqlq "SELECT GROUP_CONCAT(name) FROM users")
Don’t forget about mysql prefix if any
cat sites/default/settings.php… Read the rest
If you have a huge amount of spam users in your database you need to check this post https://alltime.pp.ua/blog/how-to-remove-wordpress-spam-users-using-mysql-command-line/ as the way below will take ‘forever’ 🙂
Supposed you’ve decided to leave just ‘administrator’
Using command below you found a pattern
wp user list
So, now run to remove them:
wp user delete $(wp user list --role=author --field=ID)
wp user delete $(wp user list --role=customer --field=ID)
wp user delete $(wp user list --role=subscriber --field=ID)
You should be asked and if you are sure just type ‘y‘
–reassign parameter not passed.… Read the rest
First of all backup your current website’s version (files/folders/database)
Supposed you have ZenCart on yourdomain.com pointed to /home/USERNAME/public_html
So, we will upgrade your ZenCart to /home/USERNAME/public_html/shop to prevent any issue with your current installation.
Create sub domain shop.yourdomain.com and point it to /home/USERNAME/public_html/shop
Create if needed shop folder under /home/USERNAME/public_html/
mkdir -p shop
cd shop/
Download the latest version
wget https://sourceforge.net/projects/zencart/files/CURRENT%20-%20Zen%20Cart%201.5.x%20Series/zen-cart-v1.5.5f-12312017b.zip… Read the rest