≡ Menu

Snort: 5 Steps to Install and Configure Snort on Linux

Snort is a free lightweight network intrusion detection system for both UNIX and Windows.

In this article, let us review how to install snort from source, write rules, and perform basic testing.

[continue reading…]

Question: I have purchased Linux support for RHEL and OEL from Oracle corporation. How do I register my Linux system to Oracle support network to download and update packages? Can you explain me with step-by-step instruction?

Answer: After purchasing Linux support from Oracle, you should register your Linux system with Oracle’s Unbreakable Linux Network using up2date utility as explained in this article.
[continue reading…]

How To Create LVM Using vgcreate, lvcreate, and lvextend lvm2 Commands

LVM stands for Logical Volume Manager.

With LVM, we can create logical partitions that can span across one or more physical hard drives. First, the hard drives are divided into physical volumes, then those physical volumes are combined together to create the volume group and finally the logical volumes are created from volume group.

The LVM commands listed in this article are used under Ubuntu Distribution. But, it is the same for other Linux distributions.
[continue reading…]

As part of our on-going VMware series of articles, we earlier discussed about how to install VMware ESXi server, and  how to install vSphere Client.

In this article, let us see how to create a new datastore using vSphere client.
[continue reading…]

Bash has several commands that comes with the shell (i.e built inside the bash shell).

When you execute a built-in command, bash shell executes it immediately, without invoking any other program.

Bash shell built-in commands are faster than external commands, because external commands usually fork a process to execute it.

In this article let us review some useful bash shell builtins with examples.
[continue reading…]

You might find the following three Linux / Unix shell scripts helpful.

  • Display processes based on either %CPU or Memory Usage.
  • Display which user is utilizing the CPU the most.
  • Display system’s memory information – total, used and free.

[continue reading…]

Unix Shell Script to Execute Oracle SQL Query

Question: Can you provide me a shell script that will accept oracle credentials, sql query to be executed and displays the output?

Answer: The shell script given below prompts some basic information and displays the output of the SQL.

You can use the same concept and hard-code some of these values in the shell-script itself and even run this script in the background to generate the output of an oracle sql query automatically (or use the oracle shell script from cron job).

This script accepts following values from the user:

  • Oracle username
  • Oracle password
  • Oracle SQL Query to be executed.

Script validates the $ORACLE_HOME and $ORACLE_SID set in environment.
[continue reading…]

Log Effectively Using Custom Perl Logger Module

For any custom written user services and processes, you should maintain a log file to view the status of the service, or to troubleshoot any issues with the services/processes.

Perl CPAN offers few modules which provides the automated object interface for handling logging for services.

In this article, let us write our own Perl logger module which internally uses Perl CPAN modules: Log::Agent, Log::Agent::Driver::File and Log::Rotate.

This custom perl logger module will perform the following operations.
[continue reading…]