Search

Blogroll

Meta:

Mytop error “long|!”

November 17th, 2009 by vicky

If you run mytop on RHEL server (or CentOS 5.x) you may get error message saying

Error in option spec: “long|!”

You should edit file /usr/bin/mytop and comment out this line

“long|!” => \$config{long_nums},

after that, run mytop and all should work fine.

Enjoy! :-)

Posted in Mysql | No Comments »

Audit still logging even when stoped

November 10th, 2009 by vicky

I had strange problem on one of my CentOS 5.4 servers. I stoped auditd service and disables SElinux, the server, however, was still logging all those annoying things like

Nov 10 18:27:01 server kernel: type=1105 audit(1257874021.909:87975): user pid=27986 uid=0 auid=0 msg=’PAM: session open acct=”root” : exe=”/usr/sbin/crond” (hostname=?, addr=?, terminal=cron res=success)’
Nov 10 18:27:02 server kernel: type=1104 audit(1257874022.828:87976): user pid=27986 uid=0 auid=0 msg=’PAM: setcred acct=”root” : exe=”/usr/sbin/crond” (hostname=?, addr=?, terminal=cron res=success)’

into /var/log/messages log, filling it up with garbage.

After some time spent investigating IĀ  fixed it. I edited /etc/audit/audit.rulesĀ  and replaced line

-D

with this line

-e 0

After that I started auditd service, stopped it and no more logs in /var/log/messages

Posted in General linux admin | 1 Comment »

Show line numbers in vi or vim

November 5th, 2009 by vicky

Have you ever wondered how to show line numbers in vi or vim while editing file? I do that always when I patch some software or install MODs that come with “go to line xxx and rewrite this…”. And the solution is really simple.

In vi/vim type :set number to show line numbers and :set nonumber to hide line numbers.

Posted in General linux admin | No Comments »