Re: [BackupPC-users] Backing up laptop as available
2008-06-18 18:40:29
Curtis Vaughan wrote:
> I was wondering if there was a way to make backuppc backup laptops as the
> become available on the network.
I thought about the same procedure and as an enhancement backup Laptops
when they are connected via (Open-)VPN.
While I had not enough time to explore this in detail a solution for
your problem might be:
1) Check if your client-laptop has a certain IP
2) connects to the BackupPC-server vis SSH and request a backup from the
command line (I think there is an option to make BackupPC starting a
backup from the command line)
Assuming that your laptops are running Windows, you can use this batch
file to run command based on the IP the client-PC has.
You could run this script in taskplaner or start it when after you made
a connection to network. IBM Access Connections offers this feature.
- - 8< - -
@echo off
:: for error tracking, you should set echo on
:: This Script can be found at (german language):
:: http://www.supportnet.de/fresh/2005/12/id1211340.asp
IPCONFIG | FINDSTR "IP-Adress" >ip.tmp
FOR /F "tokens=2,3,4 delims=:. " %%a IN (ip.tmp) DO SET SubNet=%%a.%%b.%%c
DEL ip.tmp
IF %SubNet% == 192.168.178 GOTO F1
IF %SubNet% == 192.168.2 GOTO F2
GOTO ERR
:F1
:: Assuming that Subnet 192.168.178.* is your company address
ssh backuppc@BACKUPPC-SERVER COMMAND-TO-START-BACKUP-OF-CLIENT
GOTO END
:F2
:: Assuming that subnet 192.168.2.* is another subnet
echo ANOTHER COMMAND THAT SHOULD BE RUN, IN THIS SUBNET
GOTO END
:ERR
echo There has been an error, or your client is in another subnet.
GOTO END
:END
pause
:: You can also delete the line above
- Kurt
-------------------------------------------------------------------------
Check out the new SourceForge.net Marketplace.
It's the best place to buy or sell services for
just about anything Open Source.
http://sourceforge.net/services/buy/index.php
_______________________________________________
BackupPC-users mailing list
BackupPC-users AT lists.sourceforge DOT net
List: https://lists.sourceforge.net/lists/listinfo/backuppc-users
Wiki: http://backuppc.wiki.sourceforge.net
Project: http://backuppc.sourceforge.net/
|
|
|