Need to make sure program is closed on all machines before backup runs

PatrickGSR94

New member
Member
VIP
Local time
6:00 PM
Messages
182
I work in an architecture office using Quickbooks to track hours, expenses, billing, etc. The company QB files reside on the server in a shared directory that is mapped as drive Z: on all machines through a domain logon script that runs when each person logs on to their machine. The company file runs in multi-user mode so that everyone can access the file and enter their hours at the same time.

The problem is that if anyone happens to leave Quickbooks open at night, the server backup process (running BackupExec) will skip the files that are in use, usually either 2 or 3 files. This is potentially bad news because if anything happened to the server the following day after those files were skipped, we would not have the file from the night before to restore, which could potentially mean lots of information lost (sometimes lots of info is entered in one day, especially on "billing" days).

Sometimes people will leave in the afternoon for a meeting, thinking they'll be back later and leave their programs open. But then the meeting ends up running long and they don't come back until the next day. That's usually why Quickbooks ends up getting left open on a machine overnight.

What I'm wondering is if there's a way to make the program automatically close, if it's open on any machine, perhaps just before the backup process starts on the server. Or, make the program close if the computer has been idle a certain amount of time.

Is there any way to make this happen? All machines in our office that have Quickbooks on it run Windows 7, except for one machine that still runs XP.
 

My Computer My Computer

At a glance

Windows 7 Professional x64Core i7-4790K Devil's Canyon Quad Core 4.0 GHzG.SKILL Ripjaws X Series 32 GB DDR3-1866 (4x ...EVGA (nVIDIA) GTX 960 4 GB GDDR5
Computer type
PC/Desktop
Computer Manufacturer/Model Number
Custom-built PC workstation
OS
Windows 7 Professional x64
CPU
Core i7-4790K Devil's Canyon Quad Core 4.0 GHz
Motherboard
ASUS Z97-E/USB3.1 ATX
Memory
G.SKILL Ripjaws X Series 32 GB DDR3-1866 (4x 8GB)
Graphics Card(s)
EVGA (nVIDIA) GTX 960 4 GB GDDR5
Sound Card
on-board
Monitor(s) Displays
2x Dell Ultrasharp 24" U2415
Screen Resolution
2x 1920x1200
Hard Drives
Crucial MX200 500GB 2.5" SSD SATA III 6 GB/sec
PSU
Rosewill Glacier 700M 700-watt
Case
Fractal Design Define R4 Silent PC mid-tower
Cooling
OEM PSU cooler, 3x 140mm case fans (2 intake, 1 exhaust)
Keyboard
Logitech
Mouse
Logitech
Internet Speed
100+ Mbps
Antivirus
BitDefender
Browser
Firefox/Chrome
Find the process name of Quickbooks, then kill it from the command-line on end users' machines via psexec, task scheduler, or something of the like:

Taskkill /IM quickbooks.exe /F
 

My Computer My Computer

At a glance

XP / Win7 x64 ProIntel Quad-Core Q9450 @ 3.2GHz2x2GB GSkill DDR2NVIDIA GeForce 8600 GTS (EVGA)
OS
XP / Win7 x64 Pro
CPU
Intel Quad-Core Q9450 @ 3.2GHz
Motherboard
Asus P5-E
Memory
2x2GB GSkill DDR2
Graphics Card(s)
NVIDIA GeForce 8600 GTS (EVGA)
Monitor(s) Displays
Dell 2408WFP
Screen Resolution
1920x1200

My Computer My Computer

At a glance

Windows 10 Pro (x64)Intel Core i7-3930K (3.2GHz - 4.5GHz)4x Samsung 4GB PC3-12800 DDR3 (16GB 1600MHz)Nvidia Geforce GTX 690
Computer type
PC/Desktop
Computer Manufacturer/Model Number
Alienware Aurora ALX R4
OS
Windows 10 Pro (x64)
CPU
Intel Core i7-3930K (3.2GHz - 4.5GHz)
Motherboard
Alienware Aurora-R4 x79
Memory
4x Samsung 4GB PC3-12800 DDR3 (16GB 1600MHz)
Graphics Card(s)
Nvidia Geforce GTX 690
Sound Card
SteelSeries Siberia Elite
Monitor(s) Displays
Dell UltraSharp U3011
Screen Resolution
2560x1600
Hard Drives
Samsung 850 Pro 256 GB, Seagate 1TB Desktop Hybrid HDD, 2x Western Digital 4TB Green HDD
PSU
875W Some Dell PSU <.<
Case
Alienware Aurora ALX
Cooling
Custom Liquid Cooling (EK CPU & GPU blocks) dual EK 480RAD
Keyboard
Logitech G710+ Mechanical
Mouse
Logitech G700s
Internet Speed
Verizon Fios (50 mbps average)
Other Info
Server: Intel NUC D54250WYK: i5-4250U, 16GB, 256 GB mSATA, Windows Server 2012 R2
Shame, if you used a backup service that took advantage of the Volume Shadow Copy Service you wouldn't have this problem.

I'm not sure I understand what you mean. Can you go into a bit more detail?

I created a simple 2-line batch script that I have set up on all our workstations to run 5 minutes before the backup process starts, and only if the workstation has been idle for at least 10 minutes. Simple solution.
 

My Computer My Computer

At a glance

Windows 7 Professional x64Core i7-4790K Devil's Canyon Quad Core 4.0 GHzG.SKILL Ripjaws X Series 32 GB DDR3-1866 (4x ...EVGA (nVIDIA) GTX 960 4 GB GDDR5
Computer type
PC/Desktop
Computer Manufacturer/Model Number
Custom-built PC workstation
OS
Windows 7 Professional x64
CPU
Core i7-4790K Devil's Canyon Quad Core 4.0 GHz
Motherboard
ASUS Z97-E/USB3.1 ATX
Memory
G.SKILL Ripjaws X Series 32 GB DDR3-1866 (4x 8GB)
Graphics Card(s)
EVGA (nVIDIA) GTX 960 4 GB GDDR5
Sound Card
on-board
Monitor(s) Displays
2x Dell Ultrasharp 24" U2415
Screen Resolution
2x 1920x1200
Hard Drives
Crucial MX200 500GB 2.5" SSD SATA III 6 GB/sec
PSU
Rosewill Glacier 700M 700-watt
Case
Fractal Design Define R4 Silent PC mid-tower
Cooling
OEM PSU cooler, 3x 140mm case fans (2 intake, 1 exhaust)
Keyboard
Logitech
Mouse
Logitech
Internet Speed
100+ Mbps
Antivirus
BitDefender
Browser
Firefox/Chrome
Volume Shadow Copy Service (VSS), is the under lying technology used by System Restore, and Previous Versions. VSS allows them to function without taking the computer offline to copy files in use or being written to. In other words, an application could be writing to the file and you can still back it up with VSS.

https://secure.wikimedia.org/wikipedia/en/wiki/Shadow_Copy
Snapshots have two primary purposes: they allow the creation of consistent backups of a volume, ensuring that the contents cannot change while the backup is being made; and they avoid problems with file locking...backup programs are able to access every file without interfering with other programs writing to those same files.
 

My Computer My Computer

At a glance

Windows 10 Pro (x64)Intel Core i7-3930K (3.2GHz - 4.5GHz)4x Samsung 4GB PC3-12800 DDR3 (16GB 1600MHz)Nvidia Geforce GTX 690
Computer type
PC/Desktop
Computer Manufacturer/Model Number
Alienware Aurora ALX R4
OS
Windows 10 Pro (x64)
CPU
Intel Core i7-3930K (3.2GHz - 4.5GHz)
Motherboard
Alienware Aurora-R4 x79
Memory
4x Samsung 4GB PC3-12800 DDR3 (16GB 1600MHz)
Graphics Card(s)
Nvidia Geforce GTX 690
Sound Card
SteelSeries Siberia Elite
Monitor(s) Displays
Dell UltraSharp U3011
Screen Resolution
2560x1600
Hard Drives
Samsung 850 Pro 256 GB, Seagate 1TB Desktop Hybrid HDD, 2x Western Digital 4TB Green HDD
PSU
875W Some Dell PSU <.<
Case
Alienware Aurora ALX
Cooling
Custom Liquid Cooling (EK CPU & GPU blocks) dual EK 480RAD
Keyboard
Logitech G710+ Mechanical
Mouse
Logitech G700s
Internet Speed
Verizon Fios (50 mbps average)
Other Info
Server: Intel NUC D54250WYK: i5-4250U, 16GB, 256 GB mSATA, Windows Server 2012 R2
Volume Shadow Copy Service (VSS), is the under lying technology used by System Restore, and Previous Versions. VSS allows them to function without taking the computer offline to copy files in use or being written to. In other words, an application could be writing to the file and you can still back it up with VSS.

https://secure.wikimedia.org/wikipedia/en/wiki/Shadow_Copy
Snapshots have two primary purposes: they allow the creation of consistent backups of a volume, ensuring that the contents cannot change while the backup is being made; and they avoid problems with file locking...backup programs are able to access every file without interfering with other programs writing to those same files.

Wouldn't that mean that if the file was in use, the backup software would copy the most recent shadow copy, which could be 12 or more hours old? In our workflow that could still mean loss of quite a bit of data if something happened to the server. I would prefer to have it back up the file with everything through the end of that day, so I think the script to make sure it's closed on everyone's machine will work best.
 

My Computer My Computer

At a glance

Windows 7 Professional x64Core i7-4790K Devil's Canyon Quad Core 4.0 GHzG.SKILL Ripjaws X Series 32 GB DDR3-1866 (4x ...EVGA (nVIDIA) GTX 960 4 GB GDDR5
Computer type
PC/Desktop
Computer Manufacturer/Model Number
Custom-built PC workstation
OS
Windows 7 Professional x64
CPU
Core i7-4790K Devil's Canyon Quad Core 4.0 GHz
Motherboard
ASUS Z97-E/USB3.1 ATX
Memory
G.SKILL Ripjaws X Series 32 GB DDR3-1866 (4x 8GB)
Graphics Card(s)
EVGA (nVIDIA) GTX 960 4 GB GDDR5
Sound Card
on-board
Monitor(s) Displays
2x Dell Ultrasharp 24" U2415
Screen Resolution
2x 1920x1200
Hard Drives
Crucial MX200 500GB 2.5" SSD SATA III 6 GB/sec
PSU
Rosewill Glacier 700M 700-watt
Case
Fractal Design Define R4 Silent PC mid-tower
Cooling
OEM PSU cooler, 3x 140mm case fans (2 intake, 1 exhaust)
Keyboard
Logitech
Mouse
Logitech
Internet Speed
100+ Mbps
Antivirus
BitDefender
Browser
Firefox/Chrome
Wouldn't that mean that if the file was in use, the backup software would copy the most recent shadow copy, which could be 12 or more hours old?

No, it means it takes snapshots when you tell it, then one saves the snapshot. VSS takes snapshots without interrupting or being interrupted. That is the point. The built in backup solution in Windows 7 and Windows Server 2008 use VSS to overcome the issue of files in use by using VSS to take a snapshot.

Do not confuse VSS with System Restore. I'm not even sure where you got the 12 hours old deal.
 

My Computer My Computer

At a glance

Windows 10 Pro (x64)Intel Core i7-3930K (3.2GHz - 4.5GHz)4x Samsung 4GB PC3-12800 DDR3 (16GB 1600MHz)Nvidia Geforce GTX 690
Computer type
PC/Desktop
Computer Manufacturer/Model Number
Alienware Aurora ALX R4
OS
Windows 10 Pro (x64)
CPU
Intel Core i7-3930K (3.2GHz - 4.5GHz)
Motherboard
Alienware Aurora-R4 x79
Memory
4x Samsung 4GB PC3-12800 DDR3 (16GB 1600MHz)
Graphics Card(s)
Nvidia Geforce GTX 690
Sound Card
SteelSeries Siberia Elite
Monitor(s) Displays
Dell UltraSharp U3011
Screen Resolution
2560x1600
Hard Drives
Samsung 850 Pro 256 GB, Seagate 1TB Desktop Hybrid HDD, 2x Western Digital 4TB Green HDD
PSU
875W Some Dell PSU <.<
Case
Alienware Aurora ALX
Cooling
Custom Liquid Cooling (EK CPU & GPU blocks) dual EK 480RAD
Keyboard
Logitech G710+ Mechanical
Mouse
Logitech G700s
Internet Speed
Verizon Fios (50 mbps average)
Other Info
Server: Intel NUC D54250WYK: i5-4250U, 16GB, 256 GB mSATA, Windows Server 2012 R2
I've used VSS on my Win7 machine many times before to get back files that were accidentally deleted from our server. I just right-click on the folder and go to Restore Previous Versions. The list shows a "snapshot" of that folder and its contents from twice each previous day for a couple of weeks back, which is what I was referring to by the 12 hours. Actually ours shows snapshots at 7 AM and 12 PM each day. Not sure where those times came from. However I'm not sure if that's Win7's VSS on my workstation that's taking those "snapshots" or if it's on the server itself. Our server runs Windows Server 2003.

Anyway, I went ahead and set up the batch file on everyone's machine to be sure Quickbooks is closed each night before the backup starts. For additional protection, our office manager's copy of QB is set up to automatically create its own backup file in completely separate folder on the server, each time she closes out of QB. That folder is then also backed up by BackupExec each night.

Add all that to our 3 other on-site and off-site backup locations and I think we're pretty well protected. :)
 

My Computer My Computer

At a glance

Windows 7 Professional x64Core i7-4790K Devil's Canyon Quad Core 4.0 GHzG.SKILL Ripjaws X Series 32 GB DDR3-1866 (4x ...EVGA (nVIDIA) GTX 960 4 GB GDDR5
Computer type
PC/Desktop
Computer Manufacturer/Model Number
Custom-built PC workstation
OS
Windows 7 Professional x64
CPU
Core i7-4790K Devil's Canyon Quad Core 4.0 GHz
Motherboard
ASUS Z97-E/USB3.1 ATX
Memory
G.SKILL Ripjaws X Series 32 GB DDR3-1866 (4x 8GB)
Graphics Card(s)
EVGA (nVIDIA) GTX 960 4 GB GDDR5
Sound Card
on-board
Monitor(s) Displays
2x Dell Ultrasharp 24" U2415
Screen Resolution
2x 1920x1200
Hard Drives
Crucial MX200 500GB 2.5" SSD SATA III 6 GB/sec
PSU
Rosewill Glacier 700M 700-watt
Case
Fractal Design Define R4 Silent PC mid-tower
Cooling
OEM PSU cooler, 3x 140mm case fans (2 intake, 1 exhaust)
Keyboard
Logitech
Mouse
Logitech
Internet Speed
100+ Mbps
Antivirus
BitDefender
Browser
Firefox/Chrome
I've used VSS on my Win7 machine many times before to get back files that were accidentally deleted from our server. I just right-click on the folder and go to Restore Previous Versions. The list shows a "snapshot" of that folder and its contents from twice each previous day for a couple of weeks back, which is what I was referring to by the 12 hours. Actually ours shows snapshots at 7 AM and 12 PM each day. Not sure where those times came from. However I'm not sure if that's Win7's VSS on my workstation that's taking those "snapshots" or if it's on the server itself. Our server runs Windows Server 2003.

Anyway, I went ahead and set up the batch file on everyone's machine to be sure Quickbooks is closed each night before the backup starts. For additional protection, our office manager's copy of QB is set up to automatically create its own backup file in completely separate folder on the server, each time she closes out of QB. That folder is then also backed up by BackupExec each night.

Add all that to our 3 other on-site and off-site backup locations and I think we're pretty well protected. :)

What your talking about is system restore that will allow you to restore those files.

The way backups use VSS is, the moment you start the backup, a shadow copy is made of t he volume. Once a Volume shadow is created, instead of overwriting blocks of a file on disk, they are written to a different location (this is referred to as "copy on write"). Similarly, if you delete a file, the blocks belonging to the file are not overwritten. The backup uses the old copies of modified and delete blocks while the running system access the modified blocks. When the backup is complete, the old copies of blocks are freed for reuse.

So, with a backup that uses VSS, your backup contains a self consistent snaphot of the system at the time you started the backup. All files are backed up - none are skipped.

System restore also uses VSS to make restore points.
 

My Computer My Computer

At a glance

Windows 10 Pro. EFI boot partition, full EFI ...i7 4770k 4.4GHz (44-44-43-43 turbo) @ 1.248V16GB (8GBx2) @2200 MHz G.skill Sniper 10-11-1...MSI GTX 970 Gaming 4G
Computer type
PC/Desktop
Computer Manufacturer/Model Number
Home built (GeneO industries)/Model 4
OS
Windows 10 Pro. EFI boot partition, full EFI boot
CPU
i7 4770k 4.4GHz (44-44-43-43 turbo) @ 1.248V
Motherboard
ASUS Maximus VI Hero
Memory
16GB (8GBx2) @2200 MHz G.skill Sniper 10-11-10-30-1, 1.6V
Graphics Card(s)
MSI GTX 970 Gaming 4G
Sound Card
Onboard SupremeFX Audio
Monitor(s) Displays
NEC Spectraview 2490WUXi-SV
Screen Resolution
1920 x 1200
Hard Drives
Samsung 850 Pro 256GB (OS), Samsung 2x 128GB 840 Pro SSD in RAID0, 3x WD Blue 6Gb/s 1TB RAID0, WD 2TB Black external USB 3.0, 2TB WD20EARS Green external USB 3.0, 2x 500GB Seagate and 1 750 GB external USB, 1x 350GB external USB3
PSU
Seasonic X-850 (2012 KM3 model)
Case
Fractal Design Define R4
Cooling
NH-D14, NF-F12, NF-A15; NF-P14, NF-P12,NF-A14, S12A PWM
Keyboard
Cooler Master Storm Quickfire Rapid - Brown
Mouse
Logitech G602
Internet Speed
126.4 Mb/s down, 24.3 Mb/s up
Other Info
USB 3.0 x8 , SATA III x8, eSATA, USB 2.0 x6. Samsung DVD R/W drive.

WEI: CPU 7.8, Memory 7.9, Graphics 7.9, Disk 7.9
Back
Top