≡ Menu

July 2010

You may want to disable ping replies for many reasons, may be for a security reason, or to avoid network congestion. Someone can flood the network with ping -f as shown in “Ping Example 5” in our earlier Ping Tutorial article. If ping reply is disabled we can avoid this flooding. Disable ping reply Temporarily [...]

{ 3 comments }

8 PostgreSQL Date and Time Function Examples

In this article, let us review following PostgreSQL date and time functions with practical examples. now() now()::date now()::time date_part() age() extract() date_trunc() to_char() to_timestamp() 1. Get Current Date and Time using PostgreSQL now() Get current date and time using the following query. dbase=# select now(); now ------------------------------ 2010-06-19 09:28:43.98216-07 (1 row) Use the ::time as [...]

{ 7 comments }

RPM command is used for installing, uninstalling, upgrading, querying, listing, and checking RPM packages on your Linux system. RPM stands for Red Hat Package Manager. With root privilege, you can use the rpm command with appropriate options to manage the RPM software packages. In this article, let us review 15 practical examples of rpm command. [...]

{ 40 comments }

Screen command offers the ability to detach a long running process (or program, or shell-script) from a session and then attach it back at a later time. When the session is detached, the process that was originally started from the screen is still running and managed by the screen. You can then re-attach the session [...]

{ 13 comments }

Fail2ban scans log files for various services ( SSH, FTP, SMTP, Apache, etc., ) and bans the IP that makes too many password failures. It also updates the firewall rules to reject these ip addresses. Fail2ban is an intrusion prevention framework written in the Python programming language. Main purpose of Fail2ban is to prevent brute [...]

{ 8 comments }

We are Vim editor fans. Vim editor is the most popular editor for UNIX / Linux platform, followed by emacs editor. If you talk to emacs editor fans, they might think otherwise. In the spirit of learning, we’ve decided to explore emacs editor in detail and we’ll be posting several emacs articles in the upcoming [...]

{ 3 comments }

How To: Perl TCP / UDP Socket Programming using IO::Socket::INET

In this article, let us discuss how to write Perl socket programming using the inbuilt socket modules in Perl. Perl socket modules provides an object interface that makes it easier to create and use TCP / UPD sockets. This article covers the following topics: Perl example code for TCP client and server Perl example code [...]

{ 10 comments }