Question Auto-backup Network Server files to USB Flash Drive when Drive Plugged in

MrElektric

Reputable
Jul 11, 2020
3
0
4,510
Hello,

I have a need to back-up the files I keep on shared network drive; Lets call it G:\. My goal being when I plug in my flash drive to my computer connected to that network, it automatically copies the files in question on the network drive to my flash drive; Lets call it D:\.

This link details the directions I used to make the files that execute the commands on my USB Flash Drive. I thought it would work the way I did it but obviously......

Before you ask, I cannot use 3rd party software or the windows 10 utility that is pre-existing to aide in my task.

How should I go about getting this to do what I need it to do?

Thanks in advance


Below is the code for each file:

Autorun.inf -

[autorun]

icon=drive.ico

open=launch.bat

action=Click ok to Run game for Windows

shell\open\command=launch.bat

_

file.bat -

@Echo off

:: variables

/min

SET odrive=%odrive:~0,2%

set backupcmd=xcopy /s /c /d /e /h /i /r /y

echo off

%backupcmd% "%rjg00005%\G:\Engineering\AB Programs" "%D:\%\AB Programs"



@Echo off

cls

_

invisible.vbs -

CreateObject("Wscript.Shell").Run """" & WScript.Arguments(0) & """", 0, False

_

launch.bat -

wscript.exe \invisible.vbs file.bat
 

MrElektric

Reputable
Jul 11, 2020
3
0
4,510
My purposes are to back up Programmable Logic Control files automatically when I get to my workstation. My work setup currently does not give me admin rights to run new executables such as 3rd party software, and I already tried the Back Up Settings > Back up File History in Windows 10 with my flash drive and it would not work.

The reason I would like it done in this manner is due to almost losing my PLC file library from the Network drive last month. Obviously I don't want this to happen and would like to streamline the process.

Thanks
 

USAFRet

Titan
Moderator
Any admin person that allows a random USB flash drive to execute an autorun simply by being plugged in is totally incompetent.

I absolutely see the need to back up your data and procedures.
But what you are proposing is not the way to do it. This absolutely needs to be done in conjunction with your IT staff.
 

MrElektric

Reputable
Jul 11, 2020
3
0
4,510
I have already reached out to my IT team and backing up my important files is not something they are willing to help with. Our company has a corporate IT department and is not local to me, only remote. I understand the threat possibilities with this action, however I am a manager, project engineer, and logic programmer within the facility I work in. This means I work on this network every day. There isn't any substantial or potentially dangerous information on this network drive, really it's just my PLC files and some other department specific information that is all password protected anyway.

My only purpose is to make my job easier and redundantly backing up my files to a flash drive I can keep on my person. My files can be large and many.

I get that I'm the dumb dumb here asking for help to a first world problem, so If there is a better way to accomplish my task, I'm all ears.
 

kanewolf

Titan
Moderator
I have already reached out to my IT team and backing up my important files is not something they are willing to help with. Our company has a corporate IT department and is not local to me, only remote. I understand the threat possibilities with this action, however I am a manager, project engineer, and logic programmer within the facility I work in. This means I work on this network every day. There isn't any substantial or potentially dangerous information on this network drive, really it's just my PLC files and some other department specific information that is all password protected anyway.

My only purpose is to make my job easier and redundantly backing up my files to a flash drive I can keep on my person. My files can be large and many.

I get that I'm the dumb dumb here asking for help to a first world problem, so If there is a better way to accomplish my task, I'm all ears.
The answer is your boss. If IT doesn't want to help you, then you need YOUR management to stick up for you.
 
D

Deleted member 14196

Guest
You could store all of your stuff oneone drive automatically because let me tell you backing up to a flash drive isn’t very good or very reliable because they break all the time. Backing up to a cloud is what you wanna do