Archive for the ‘Shell scripting’ Category

Delete OLD files in linux

delete old files in linux
If you want to delete log files or folders in /var/log directory which are older than 200 days then you can follow the below steps To list the files which are older than 200 days #find /var/log -mtime +200 After verifying ,you can delete those files/folders #find /var/log -mtime +200 -exec rm {} \; Full story

Shellscript for mysql database backup

mysql1
Here is the sample shellscript to take backup of all batabase {code codetype=php} #!/bin/bash export DB_BACKUP="/backup/mysql_backup" Full story

How to synchronize data between two servers using rsync

rsync
Rsync: rsync is an application used in unix systems which synchronize files and directories between two machines.rsync behaves like rcp(remote file copy),but it much faster than rcp.because rsync sends the differences in the files instead of sending entire files. Full story
Copyright © 2012 CoreTimer.com|System Admin’s Reference. All rights reserved.

Switch to our mobile site