This is a discussion on take backup of all indiviudal user dirs seperately of /home within the Shell scripting forums, part of the Development/Scripting category; Hi! I want to write a shell script which will take the backup of individual user home dirs existing in ...
|
|||||||
| Register | FAQ | Members List | Calendar | Forgotten your password? | Mark Forums Read |
|
|||
|
Hi!
I want to write a shell script which will take the backup of individual user home dirs existing in /home partition. I am using the following script but it is continuing to be in loop and it is taking all the backup in a single tar file. #!/bin/sh # thsi script is used to take the backup of individual folders # this script is userd to take the complete backup of the /home users and /apps user # AUTHOR : - Veer Kumar clear cd /home/ for files in * do set $files OF=/data/home/`hostname`_$1_bkp_$(date +%d%m%Y).tar.gz #echo $OF tar -czvf $OF * done # exiting for loop unset $files # un setting set variables exit 0 # exititng shell script can any one help me to take the backup of all users in /home partition. Thanks, Veer Kumar. |
| Sponsored Links | ||
|
|
![]() |
| Bookmarks |
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) |
|
| Thread Tools | |
| Display Modes | |
|
|
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Jailing vsftpd user to home directory | grifs71 | CentOS / RHEL / Fedora | 2 | 12-26-2007 01:56 AM |
| pure-ftpd auto home dir problem | asim.mcp | Getting started tutorials | 0 | 11-17-2007 07:31 AM |
| sendmail and mysql/user without home directory | asim.mcp | Getting started tutorials | 0 | 07-07-2007 04:41 AM |
| UNIX ls only directories (display only dirs and no files) | chiku | Solaris/OpenSolaris | 1 | 10-21-2006 01:27 AM |
| FreeBSD putty home key problem | chiku | All about FreeBSD/OpenBSD/NetBSD | 2 | 02-03-2005 06:10 PM |