Categories
Uncategorized

Block bad bots in .htaccess file in cPanel / WordPress / Apache

Add below code in .htaccess file
RewriteEngine On
RewriteCond %{HTTP_USER_AGENT} ^.*(adscanner|AhrefsBot|archive.org_bot|Baiduspider|BehloolBot|bingbot|BLEXBot|coccocbot-image|coccocbot-web|compatible|contxbot|DotBot|DuckDuckGo-Favicons-Bot|DuckDuckBot|Exabot|facebot|facebookexternalhit|Slurp|GrapeshotCrawler|houzzbot|MJ12bot|MojeekBot|Nimbostratus-Bot|PaperLiBot|PlurkBot|Seekport|SemrushBot|SEOkicks|SeznamBot|stagefright|SurdotlyBot|Sogou|TinEye-bot|YaK|YandexBot|YandexImages).*$ [NC]
RewriteRule .* - [F,L]

List of Bots which you have just blocked
adscanner
AhrefsBot
archive.org_bot
Baiduspider
BehloolBot
bingbot
BLEXBot
coccocbot-image
coccocbot-web
contxbot
DotBot
DuckDuckGo-Favicons-Bot
DuckDuckBot
Exabot
Slurp
GrapeshotCrawler
houzzbot
MJ12bot
MojeekBot
Nimbostratus-Bot
PaperLiBot
PlurkBot
Seekport
SemrushBot
SEOkicks
SeznamBot
stagefright
SurdotlyBot
Sogou
TinEye-bot
YandexBot
YandexImages
Exabot
istellabot

Categories
Uncategorized

[Solved] R1soft build module issue for CentOS kernel 4.4.112 – hcpdriver-cki-4.4.112-1.el6_.elrepo.x86_64.ko

Solution:-

Download this kernel and install it then reboot to make it active.
Kernel
wget http://mirror.rc.usf.edu/compute_lock/elrepo/kernel/el6/x86_64/RPMS/kernel-lt-4.4.112-1.el6.elrepo.x86_64.rpm
Module
wget https://the-d2.com/wp-content/uploads/2019/06/hcpdriver-cki-4.4.112-1.el6_.elrepo.x86_64.ko_.zip

Unzip the module file
Place module here /lib/modules/r1soft/ then create a symlink to it having name hcpdriver.o
Like this.
ll /lib/modules/r1soft/
total 128
-rw------- 1 root root 124190 Jan 19 2018 hcpdriver-cki-4.4.112-1.el6.elrepo.x86_64.ko
lrwxrwxrwx 1 root root 64 May 28 09:16 hcpdriver.o -> /lib/modules/r1soft/hcpdriver-cki-4.4.112-1.el6.elrepo.x86_64.ko

Restart cdp service.
Check module
hcp -l

 

 

 

Error:-

Fix CDP r1soft error : Could not find a suitable hcpdriver module for your system
Checking if module needs updated
Checking for binary module
Waiting /
No binary module found
Gathering kernel information
Gathering kernel information complete.
Creating kernel headers package
Checking ‘/tmp/r1soft-cki.xxxxxxxxx’ for kernel headers
Found headers in ‘/tmp/r1soft-cki.xxxxxxx’
Compressing…
uploading kernel package 99% 6379KB 6.2MB/s 00:00 ETA
Starting module build…
Building / kernel module installer failed. (0):
Internal error encountered. Please contact support

Categories
Uncategorized

Install Kernel kernel-lt-4.4.180-2.el7.elrepo.x86_64 on CentOS without repo

mkdir kernel-lt-4.4.180 ; cd kernel-lt-4.4.180
wget http://mirror.imt-systems.com/elrepo/archive/kernel/el7/x86_64/RPMS/kernel-lt-4.4.180-2.el7.elrepo.x86_64.rpm http://mirror.imt-systems.com/elrepo/archive/kernel/el7/x86_64/RPMS/kernel-lt-devel-4.4.180-2.el7.elrepo.x86_64.rpm http://mirror.imt-systems.com/elrepo/archive/kernel/el7/x86_64/RPMS/kernel-lt-headers-4.4.180-2.el7.elrepo.x86_64.rpm http://mirror.imt-systems.com/elrepo/archive/kernel/el7/x86_64/RPMS/kernel-lt-tools-4.4.180-2.el7.elrepo.x86_64.rpm http://mirror.imt-systems.com/elrepo/archive/kernel/el7/x86_64/RPMS/kernel-lt-tools-libs-4.4.180-2.el7.elrepo.x86_64.rpm http://mirror.imt-systems.com/elrepo/archive/kernel/el7/x86_64/RPMS/kernel-lt-tools-libs-devel-4.4.180-2.el7.elrepo.x86_64.rpm
yum install -y kernel*
Categories
Uncategorized

Let’s Encrypt on CentOS 6/7 with Nginx/Apache

yum -y install yum-utils
yum install certbot -y
certbot certonly -d the-d2.com -d www.the-d2.com –dry-run –webroot –renew-by-default -w /home/the-d2/public_html –authenticator webroot

Now in the output you will see the geenrated certs path, use them in your virtualhost and reload the webserver nignx / apache

Setup renewel Cron:-
certbot certonly -d the-d2.com -d www.the-d2.com –webroot –renew-by-default -w /home/the-d2/public_html –authenticator webroot

Categories
Uncategorized

Install MySQL 5.7 On CentOS via Ansible Playbook

- name: Install MySQL
  hosts: test123
  become: true
  become_user: root
  gather_facts: true
  tasks:
    - name: "Installing Repo & Packages"
      yum: name=http://dev.mysql.com/get/mysql57-community-release-el6-7.noarch.rpm
    - name: Install MySQL 5.7
      yum: pkg={{ item }}
      with_items:
    - mysql-community-server
    - mysql-community-client
Categories
Uncategorized

How to check Magento Base URLs in Database with MySQL Query

select * from core_config_data where path like '%base%url%';

Categories
Jobs

Linux Jobs at Johns Hopkins University Applied Physics Laboratory, US – jhuapl.edu

Linux Jobs at Johns Hopkins University Applied Physics Laboratory, Laurel, Maryland, U.S
https://www.jhuapl.edu/Careers
Linux Job search > https://tas-jhuapl.taleo.net/careersection/2/jobsearch.ftl?lang=en

Categories
Jobs

Linux System Administrator – Jobs – Worldwide – Part 1

Jobs that i have applied to