April 2025
M T W T F S S
 123456
78910111213
14151617181920
21222324252627
282930  

Categories

April 2025
M T W T F S S
 123456
78910111213
14151617181920
21222324252627
282930  

Install RabbitMQ

wget http://www.rabbitmq.com/releases/rabbitmq-server/current/rabbitmq-server-3.5.7-1.noarch.rpm rpm –import http://www.rabbitmq.com/rabbitmq-signing-key-public.asc yum install rabbitmq-server-3.5.7-1.noarch.rpm chkconfig rabbitmq-server on /sbin/service rabbitmq-server start /sbin/service rabbitmq-server status rabbitmq-plugins enable rabbitmq_management rabbitmqctl add_user test test rabbitmqctl add_user guest test123 rabbitmqctl set_user_tags test administrator rabbitmqctl set_permissions -p / test “.*” “.*” “.*”

GRUB PASSWORD ON CENTOS 7 FEDORA RHEL ORACLE LINUX 7

RHEL 7 / CentOS 7.

This post is to Secure Single User Mode / Rescue Mode / Emergency mode on RHEL 7 / CentOS 7 in Grub2, By performing this Article you will able to secure your Grub2 Edits with Username and Password, It is always a good idea to protect your Grub2.

In This […]

Increasing Linux server security with nodev, nosuid and no exec options

Expertise level: Advanced Hackers can use temporary storage directories such as /tmp to store and execute unwanted programs and hack into a server. Other temporary storage directories that can be used for malicious activities are /var/tmp and /dev/shm. Follow these steps to secure your Linux server against this vulnerability: Add nodev, nosuid, and noexec options […]

Remove Old Kernels on RHEL, CentOS, Fedora

Remove Old Kernels on RHEL, CentOS, Fedora This is quick guide howto delete/remove/clean old kernels on Fedora, CentOS, Red Hat (RHEL). I use here two kernel as example, if you want to keep other more or less, then adjust amount of installed kernels as you wish. Normally reason why you maybe want remove kernels is […]

DRBD setup on Centos 6.7

CentOS 6.7 DRBD installation and configuration notes

DRDB or Distributed Replicated Block Device is nice for HA situations of distributed block devices. This can be used for NAS, SAN, and a number of other use cases.

** NOTE THIS SETUP IS FOR ACTIVE/PASSIVE, NOT ACTIVE

Primary: 192.168.1.60 (cluster1.rmohan.com)

Secondary: 192.168.1.61 (cluster2.rmohan.com) Requirements

– Two disks […]

IP address with ifconfig and sed

Well, my new favorite approach is to pipe ifconfig into a single sed command 🙂

ifconfig | sed -n -e ‘s/:127\.0\.0\.1 //g’ -e ‘s/ *inet addr:\([0-9.]\+\).*/\1/gp’

 

So, how does it work? Well, there are two filters (aka scripts, ie the parameters after the -e flags). The first one, s/:127\.0\.0\.1 //g’, simply strips out all […]

CentOS – ssh-copy-id: command not found

CentOS – ssh-copy-id: command not found yum -y install openssh-clients

Searching and File Operations in linux

TOP 10 largest file # find /var -type f -ls | sort -k 7 -r -n | head -10

FIND FILES MORE THAN 5Gb # find /var/log/ -type f -size +5120M -exec ls -lh {} \;

Find all temp files older than a month and delete: # find /usr/home/admin/Maildir/new -mtime +30-type f | xargs /bin/rm […]

INCREMENTAL BACKUP USING rsync COMMAND

SIMPLE INCREMENTAL BACKUP USING rsync COMMAND

Backups can be classified to two types.They are

1)Full backup The entire data will be backup will be taken every time

2)Incremental backup

Incremental backup take the full backup at the first time ,from the second time it will compare the files in first backup and the files in […]

linux log files, location and description

linux log files, location and description Linux stores logs of almost everything from user accounting to system halts. These logs are always useful to debug problems or track the loophole of any configurations. Logs are the records of system activity to assure the faults, traffic activities, configuration logs, user activity logs. Main Linux log files […]