SFTP to remote system using Virtual-IP

SFTP programmatically without interruption to a remote-system that uses Virtual-IP (physical box is subjected to change) with the following options.

sftp -o PasswordAuthentication=no -o StrictHostKeyChecking=no

This will add the remote hostname to ~/.ssh/known_hosts file automatically without interruption.

Posted bySeshu Karthick at 1:44 PM 0 comments  

Grep text recursively in Unix

Using the pattern keyword:
grep pattern * */* */*/* 2>/dev/null

The simplistic approach using find is:
find /startdir -exec grep whatever {} dev/null \;

That's not necessarily very efficient. Using xargs can help
find . -name *.xml | xargs grep whatever

Posted bySeshu Karthick at 8:56 AM 0 comments