NixUser

NixUser.com | Unix User | Linux User | NixUser

force https 301 redirect using htaccess

  To force your website with SSL using htaccess and mod_rewrite, use the following rule in the website’s .htaccess. RewriteEngine On RewriteCond %{HTTP_HOST} ^yourwebsite\.com [NC] RewriteCond %{SERVER_PORT} 80 RewriteRule ^(.*)$ https://yourwebsite.com/$1 [R=301,L] If it’s a subdomain, use this. RewriteEngine On RewriteCond %{SERVER_PORT} 80 RewriteCond %{REQUEST_URI} sub RewriteRule ^(.*)$ https://yourwebsite.com/sub/$1 [R=301,L] Note: Replace yourwebsite.com with the More

cPanel backup error mysqldump: Got error: 1049: Unknown database when selecting the database

  Sometimes cPanel full backup fails with the following error. Storing mysql dbs…mydatabase……… /usr/bin/mysqlcheck: Got error: 1049: Unknown database ‘mydatabase’ when selecting the database (755 bytes) mydatabase_db(1031138 bytes) mydatabase_tab Check in cPanel that if you have any 0kb or empty database by the database name in error message. If you have it, delete it from More

Previous Posts