Finding a SPAM Script in the Hosted Website.

Published December 12, 2016 by Siva

Linux Malware Detect (http://www.rfxn.com/projects/linux-malware-detect/) installation is quite easy :).

download via the link, http://www.rfxn.com/downloads/maldetect-current.tar.gz.

Unzip the file # tar zxvf maldetect-current.tar.gz
change the directory to extracted one.

sudo ./install.sh

which will install the scanner to your system. To perform the scanning itself you are to run

maldet -a

Eg: maldet -a /var/www/html

-a option here means that you want ro scan all the files.
Use -r instead to scan only recent ones.

Yout will get an scanned report in screen, use maldet -q to view the reports.

Nice tool.

Thank you

LVS (Load balancer) Error Fix : nanny[2687]: READ returned error 104:Connection reset by peer

Published August 6, 2014 by Siva

I have updated the centos 6.2 -> 6.5. After the My LVS(Linux Virtual server) load balancer throwing a below error in /var/log/messages/ frequently.
I have spent 2 days to resolve this issue. I would like to share this to everyone.

Aug 6 02:28:07 lb01 nanny[2687]: READ returned error 104:Connection reset by peer
Aug 6 02:28:07 lb01 nanny[2685]: READ returned error 104:Connection reset by peer
Aug 6 02:28:09 lb01 nanny[2686]: READ returned error 104:Connection reset by peer
Aug 6 02:28:12 lb01 nanny[2688]: READ returned error 104:Connection reset by peer
Aug 6 02:28:13 lb01 nanny[2687]: READ returned error 104:Connection reset by peer
Aug 6 02:28:13 lb01 nanny[2685]: READ returned error 104:Connection reset by peer
Aug 6 02:28:15 lb01 nanny[2686]: READ returned error 104:Connection reset by peer

Solution: 1) Simple check you hosts file.
Make sure the loopback entry in /etc/hosts.
127.0.0.1 localhost.localdomain localhost

2) Check both LB servers having same timezone.

Once verified, reload your config,

1) service ipvsadm reload
2) service pulse reload

Thank you.

Export PUTTY Sessions list to Another Computer – Simple

Published January 27, 2014 by Siva

Here we are going to see, How to Export PUTTY Sessions list to Another Computer,

    Run the below command on a source system ( to taking backup / export existing session list)

regedit /e “%userprofile%\desktop\putty-sessions.reg” HKEY_CURRENT_USER\Software\SimonTatham\PuTTY\Sessions

    Do the below taskson a remote system ( Importing from reg file)

to copy the putty-sessions.reg file on remote system.

then right click on a file & merge it.

reg2

Thats it.

Apache – “Client denied by server configuration” – Resolved

Published January 3, 2014 by Siva

Linux and Windows System Administrators Stuffs

Having problems with displaying your site and getting error 403 in your web-browser?

does the log-file for apache errors contain lines like tis?
“client denied by server configuration: /path/to/files”

Then you probably have denied access to the directory in the httpd.conf file.

Allow access by adding:
<directory /path/to/files>
allow from all
</directory>

If your are using VirtualHosts then add the directory-block inside the <virtualhost> block.

View original post

HTOP – Finding memory utilazation

Published January 2, 2014 by Siva

HTOP

Htop is a text-mode, interactive process viewer for Linux run via console/ssh, and to install htop in CentOS / Ubuntu is a pretty simple task.
Among other things,

This way you will notice what programs is using most RAM.

htop allows you to:

quickly view key performance statistics such as CPU(multi-core layout) and Memory/Swap usage;
scroll the process list vertically and horizontally to see all processes and complete command lines;
kill processes by selection rather than entering process number;
use mouse to select list items.

Installation

Centos / Redhat

yum install rpm

Ubuntu / Centos

sudo apt-get install htop

How to Use htop

in the terminal

# htop

also there are some other options for example the delay time that is -d

# htop -d 2

That the above will delay the refresh time to 2 seconds

Compiling & Installing RRDtool – Error Fix

Published December 21, 2013 by Siva

RRDtoool:

Round Robin Database Tool(RRD) data analysis part of RRDtool is based on the ability to quickly generate graphical representations of the data values collected over a definable time period.

tar -xvf rrdtool-1.4.8.tar.gz

[local]# cd rrdtool-1.4.8
[rrdtool-1.4.8]#
./configure –enable-shared –prefix=/usr/local/rrdtool

I got the below error,

Then i found the following packages are dependencis..

configure: error: Please fix the library issues listed above and try again.

yum -y install zlib zlib-devel libpng libpng-devel freetype freetype-devel libart_lgpl libart_lgpl-devel libxml2 libxml2-devel gd gd-devel cairo cairo-devel pango pango-devel

Then compile then

#make && make install

Enjoy with open source…. !!

DynDNS Client configuration on Linux systems

Published December 16, 2013 by Siva

What is DynDNS:

As you know any domain should be pointed to an IP in order to be seen in browsers. If you don’t have a connection to the internet with static IP (cable, DSL, etc.), then it becomes tedious to set an A record for your domain every time your IP changes. Dynamic DNS is a feature that will allow you to point a domain name to any IP and the changes are almost immediate.

For example, you have a server at home and host a website on your computer. But you don’t have a static IP, that is the IP changes each time you reconnect to the Internet, you can setup Dynamic DNS for the domain.

Download from the below link:

http://sourceforge.net/projects/ddclient/

INSTALLATION:

1)   cp ddclient /usr/sbin/
2) mkdir /etc/ddclient
3)  cp sample-etc_ddclient.conf /etc/ddclient/ddclient.conf
 4)  vi /etc/ddclient/ddclient.conf
  — and change hostnames, logins, and passwords appropriately

Example :

  ## For those using Redhat style rc files and using daemon-mode:
  cp sample-etc_rc.d_init.d_ddclient /etc/rc.d/init.d/ddclient
  ## enable automatic startup when booting
  /sbin/chkconfig –add ddclient
  ## start the first time by hand
  /etc/rc.d/init.d/ddclient start

  ## If you are not using daemon-mode, configure cron and dhcp or ppp
  ## as described below.
protocol=namecheap
use=web, web=checkip.dyndns.com/, web-skip=’IP Address’
server=dynamicdns.park-your-domain.com
login=mydomain.com
password=’XXXXXXXXXXXXXXXXXXXXXX’

# I need to update for my subdomain
mysubdomain

Debug :

ddclient -daemon=0 -debug -verbose -noquiet

Cache file location :

/var/cache/ddclient/ddclient.cache

Force update:

ddclient –force

API:

http://dynamicdns.park-your-domain.com/update?host=Mysubdomain&domain=mydomain.com&password=XXXXXXXXXXXX&ip=100.1.1.1

 

—– End —