Wednesday, October 17, 2007

Required CPAN Modules for Mon

#perl -MCPAN -e shell
cpan>install Time::Period
cpan>install Time::HiRes
cpan>install Convert::BER
cpan>install Mon::Protocol
cpan>install Mon::SNMP
cpan>install Mon::Client

And, depending upon what you want to monitor, you may also wish to install the following optional modules:
cpan>install Filesys::DiskSpace
cpan>install Net::Telnet
cpan>install Net::LDAPapi
cpan>install Net::DNS
cpan>install SNMP

Friday, September 28, 2007

Creating GSM files with SOX

# sox inputfile.wav -r 8000 -c 1 output.gsm resample -ql

Wednesday, September 26, 2007

Null Modem for High Availability

Null modem cable pin mapping
This is one very common mapping which will work with software that relies on proper assertion of the CD signal.
Signal Name DB-25 Pin DE-9 Pin
DE-9 Pin DB-25 Pin
FG (Frame Ground) 1 - X - 1 FG
TD (Transmit Data) 2 3 - 2 3 RD
RD (Receive Data) 3 2 - 3 2 TD
RTS (Request To Send) 4 7 - 8 5 CTS
CTS (Clear To Send) 5 8 - 7 4 RTS
SG (Signal Ground) 7 5 - 5 7 SG
DSR (Data Set Ready) 6 6 - 4 20 DTR
CD (Carrier Detect) 8 1 - 4 20 DTR
DTR (Data Terminal Ready) 20 4 - 1 8 CD
DTR (Data Terminal Ready) 20 4 - 6 6 DSR

#Use 1-4 & 4-1 for 9 pin HA null modem.

File Descriptors vs Linux Performance

To increase OS system-wide file descriptors limit

http://bloggerdigest.blogspot.com/2006/10/file-descriptors-vs-linux-performance.html

  1. Set both the hard limit and soft limit of file descriptors, to as maximum as possible, to either all (the asterisk in first column) or individual user login account (replace the asterisk in the first column to the user login account)

    • Modify /etc/security/limits.conf by appending or amending these line

    • @root soft nofile 1024
      @root hard nofile 4096
      to
      @root soft nofile 100000
      @root hard nofile 102400

      Refer to the topic of Linux ulimit command

Friday, September 21, 2007

Zimbra: Daily mail report always reports "No messages found"

http://www.zimbra.com/forums/installation/3332-daily-mail-report-always-reports-no-messages-found.html
http://www.zimbra.com/forums/27508-post20.html

zmloggerinit is probably not what you wanted to do. In either case you'll most likely need to run it again, but first remove the logger db files.

Code:
% su - zimbra
% rm -rf logger/db
% zmloggerinit
That will get you back to a functioning state.
The logger db was either not competely initialized or the database got corrupted somehow (did your disk fill up?). You can reset it with the above commands or try to recover the raw_logs table by logging into the logger db and running repair table raw_logs; You'll need the logger_root_passwd from zmlocalconfig.

Friday, August 10, 2007

Ghostscript

Most Linux users have Ghostscript, and Ghostscript is supposed to be
able to append PDFs. The way it works is that it "prints" the files in
sequence, but directs them to a loopback type of printer driver that
actually generates a new PDF. Here's the command:

gs -q -sPAPERSIZE=letter -dNOPAUSE -dBATCH -sDEVICE=pdfwrite
-sOutputFile=out.pdf in1.pdf in2.pdf in3.pdf ...

Make appropriate substitutions for different paper sizes (apparently
nobody in North America has ever wanted to do this, because other
examples on the Web invariably specify A4 paper), filenames, etc. I've
found this technique to work quite well. Unfortunately, it caused
Ghostscript to die with a segfault on some of the input I wanted to run
it with, and nothing I could do would get it to process some of those files.

Thursday, August 2, 2007

Cannot Load Zaptel module because crc_ccitt table not found

This is because you are missing the crc_ccitt library routine.
Go to /lib/modules/$(uname -r)/build
type:

#>make menuconfig

In the ncurses utility,
Go to Library routines
Include:
CRC-CCITT functions
(save) and (exit)

to build modules, type:
make modules

This will rebuild all your modules, including crc-ccitt. After you are done, the crc-ccitt module will be located in ./lib

copy the crc-ccitt.ko (for 2.6 kernels) or crc-ccitt.o (for 2.4 kernels)to /lib/modules/$(uname -r)/kernel/lib/