How do I count and print particular character (say D or digit 7) in a string or variable under Bash UNIX / Linux shell?

You can use UNIX / Linux command such as sed, grep, wc or bash shell itself to count number of characters in a string or word or shell variable.

grep Command To Count Number of Characters

Use the following syntax to count ‘s’ character in a variable called $x:
Read the rest of this entry

ow can I find all the file descriptors used by a process such as httpd (Apache web server) or mysqld (MySQL Database server)?

You can use /proc file system or the lsof command to find all the file descriptors used by a process.
Read the rest of this entry

1.0 Introduction

In this current changing world of unified communication, organizations and support teams require some form of communication to improve efficiency and possibly customer satisfaction. In this document, we will look at how to setup an Instant Messaging server on CentOS 5.6 using a free and open source XMPP based IM server. To continue we can say the following about XMPP:

Extensible Messaging and Presence Protocol (XMPP) is an open-standard communications protocol for message-oriented middleware based on XML (Extensible Markup Language).[1] The protocol was originally named Jabber,[2] and was developed by the Jabber open-source community in 1999 for, originally, near-real-time, extensible instant messaging (IM), presence information, and contact list maintenance. Designed to be extensible, the protocol today also finds application in VoIP and file transfer signaling.
Source: http://en.wikipedia.org/wiki/Extensible_Messaging_and_Presence_Protocol
Read the rest of this entry

sysctl -p

root@xxxxxx:~# sysctl -p /etc/sysctl.conf
got an error:

error: “net.bridge.bridge-nf-call-iptables” is an unknown key
error: “net.bridge.bridge-nf-call-arptables” is an unknown key

Fix:

sudo modprobe bridge

Disable suhosin

Suhosin for a domain can be disabled by 2 methods.

1) Using php.ini

2) Using .htaccess.

Following are the steps in order to
Read the rest of this entry