Failed batch file

blockie

New member
Member
VIP
Local time
5:17 AM
Messages
605
Location
in Assisted Care facility, Calif
Attached is a jpeg picture of the command window when I attempt to make an image of my System drive. Why can't the shared drive be found?
 

Attachments

  • Capture.JPG
    Capture.JPG
    37.9 KB · Views: 79

My Computer

Computer type
Laptop
Computer Manufacturer/Model Number
Asus
OS
W7 Ultimate
CPU
2.2 bh Intel Core i3-2330M
Motherboard
Asustek Computer Inc. P53E 1.0
Memory
4MB
Graphics Card(s)
On Board
Sound Card
On Board
Monitor(s) Displays
On Board
Screen Resolution
1366 X 768
Hard Drives
ST9500423AS
ST2000DM USB Backup Drive External
Are you sure you have the right path for it?
 

My Computer

Computer type
PC/Desktop
Computer Manufacturer/Model Number
Custom built Desktop(Myself) Specs below - Also Asus G53SW-A1 laptop
OS
Windows 10 Pro / OpenSUSE
CPU
Intel Core i7 4790K
Motherboard
Asus Z97-A
Memory
32GB DDR3
Graphics Card(s)
EVGA GTX 1070
Sound Card
OnBoard
Monitor(s) Displays
3 X 1080P 24" displays
Screen Resolution
1280x1050 & 1920x1080
Hard Drives
SSD: Crucial M500 128GB
HD 1: WD Caviar Black 1TB
HD 2: WD Caviar Black 2TB
HD 3: WD Caviar Blue 500GB
PSU
Corsair CX650M
Case
Corsair Obisidian 450D
Cooling
Noctua NH-D14
Keyboard
Corsair K70 Vengeance (blue switches)
Mouse
Logitech M500
Internet Speed
65/10
Antivirus
Kaskersky Internet Securty
Browser
Opera
I believe it to be correct. However, I understand it should be run in "elevated command mode". How do I execute a batch file in elevated mode. Eventually i wish to use the scheduler.
 

My Computer

Computer type
Laptop
Computer Manufacturer/Model Number
Asus
OS
W7 Ultimate
CPU
2.2 bh Intel Core i3-2330M
Motherboard
Asustek Computer Inc. P53E 1.0
Memory
4MB
Graphics Card(s)
On Board
Sound Card
On Board
Monitor(s) Displays
On Board
Screen Resolution
1366 X 768
Hard Drives
ST9500423AS
ST2000DM USB Backup Drive External
Click Start, click All Programs, click Accessories, right-click Command Prompt, and then click Run as administrator.
 

My Computer

Computer type
PC/Desktop
Computer Manufacturer/Model Number
Lenovo IdeaCenter 450
OS
Windows 10 Pro X64
CPU
Intel Quad Core i7-4770 @ 3.4Ghz
Memory
16.0GB PC3-12800 DDR3 SDRAM 1600 MHz
Graphics Card(s)
Intel Integrated HD Graphics
Sound Card
Realtek HD Audio
Monitor(s) Displays
HP 22" LCD
Screen Resolution
1680 x 1050
Hard Drives
250GB Samsung EVO SATA-3 SSD
2TB Seagate ST2000DM001 SATA-2
1.5TB Seagate ST3150041AS SATA
Keyboard
Dell USB
Mouse
Lenovo USB
Internet Speed
Cable via Road Runner 3MB Upload, 30MB Download
Antivirus
Windows Defender, MBAM Pro, MBAE
Browser
Seamonkey
Other Info
UEFI/GPT
PLDS DVD-RW DH16AERSH
Or just right-click on the batch file and run as administrator.
 

My Computer

Computer type
PC/Desktop
Computer Manufacturer/Model Number
Custom built Desktop(Myself) Specs below - Also Asus G53SW-A1 laptop
OS
Windows 10 Pro / OpenSUSE
CPU
Intel Core i7 4790K
Motherboard
Asus Z97-A
Memory
32GB DDR3
Graphics Card(s)
EVGA GTX 1070
Sound Card
OnBoard
Monitor(s) Displays
3 X 1080P 24" displays
Screen Resolution
1280x1050 & 1920x1080
Hard Drives
SSD: Crucial M500 128GB
HD 1: WD Caviar Black 1TB
HD 2: WD Caviar Black 2TB
HD 3: WD Caviar Blue 500GB
PSU
Corsair CX650M
Case
Corsair Obisidian 450D
Cooling
Noctua NH-D14
Keyboard
Corsair K70 Vengeance (blue switches)
Mouse
Logitech M500
Internet Speed
65/10
Antivirus
Kaskersky Internet Securty
Browser
Opera
Hmmm, you could also right click on the batch file, select Properties then click on the Compatibility tab. Check the box that says Run this program as administrator. Then any time you ran it it was run with Administrator privileges. That would also allow you to schedule it to run, but there I think you can specify how to run it.
 

My Computer

Computer type
PC/Desktop
Computer Manufacturer/Model Number
Lenovo IdeaCenter 450
OS
Windows 10 Pro X64
CPU
Intel Quad Core i7-4770 @ 3.4Ghz
Memory
16.0GB PC3-12800 DDR3 SDRAM 1600 MHz
Graphics Card(s)
Intel Integrated HD Graphics
Sound Card
Realtek HD Audio
Monitor(s) Displays
HP 22" LCD
Screen Resolution
1680 x 1050
Hard Drives
250GB Samsung EVO SATA-3 SSD
2TB Seagate ST2000DM001 SATA-2
1.5TB Seagate ST3150041AS SATA
Keyboard
Dell USB
Mouse
Lenovo USB
Internet Speed
Cable via Road Runner 3MB Upload, 30MB Download
Antivirus
Windows Defender, MBAM Pro, MBAE
Browser
Seamonkey
Other Info
UEFI/GPT
PLDS DVD-RW DH16AERSH
The Run as Administrator is grayed out I can't check it. However when I do run it as admin. it still can't find drive D:.
 

My Computer

Computer type
Laptop
Computer Manufacturer/Model Number
Asus
OS
W7 Ultimate
CPU
2.2 bh Intel Core i3-2330M
Motherboard
Asustek Computer Inc. P53E 1.0
Memory
4MB
Graphics Card(s)
On Board
Sound Card
On Board
Monitor(s) Displays
On Board
Screen Resolution
1366 X 768
Hard Drives
ST9500423AS
ST2000DM USB Backup Drive External
Does the Images folder already exist? If not that is perhaps what it is complaining about.

From a Command Prompt, enter:

dir \\william-pc\d\images

Does that work? What about:

dir \\william-pc\d
 

My Computer

Computer type
PC/Desktop
Computer Manufacturer/Model Number
Lenovo IdeaCenter 450
OS
Windows 10 Pro X64
CPU
Intel Quad Core i7-4770 @ 3.4Ghz
Memory
16.0GB PC3-12800 DDR3 SDRAM 1600 MHz
Graphics Card(s)
Intel Integrated HD Graphics
Sound Card
Realtek HD Audio
Monitor(s) Displays
HP 22" LCD
Screen Resolution
1680 x 1050
Hard Drives
250GB Samsung EVO SATA-3 SSD
2TB Seagate ST2000DM001 SATA-2
1.5TB Seagate ST3150041AS SATA
Keyboard
Dell USB
Mouse
Lenovo USB
Internet Speed
Cable via Road Runner 3MB Upload, 30MB Download
Antivirus
Windows Defender, MBAM Pro, MBAE
Browser
Seamonkey
Other Info
UEFI/GPT
PLDS DVD-RW DH16AERSH
I get the error that the network name cannot be found.
 

My Computer

Computer type
Laptop
Computer Manufacturer/Model Number
Asus
OS
W7 Ultimate
CPU
2.2 bh Intel Core i3-2330M
Motherboard
Asustek Computer Inc. P53E 1.0
Memory
4MB
Graphics Card(s)
On Board
Sound Card
On Board
Monitor(s) Displays
On Board
Screen Resolution
1366 X 768
Hard Drives
ST9500423AS
ST2000DM USB Backup Drive External
What do you see if you issue

net view \\william-pc

That should return the list of shares defined for the computer named william-pc.
 

My Computer

Computer type
PC/Desktop
Computer Manufacturer/Model Number
Lenovo IdeaCenter 450
OS
Windows 10 Pro X64
CPU
Intel Quad Core i7-4770 @ 3.4Ghz
Memory
16.0GB PC3-12800 DDR3 SDRAM 1600 MHz
Graphics Card(s)
Intel Integrated HD Graphics
Sound Card
Realtek HD Audio
Monitor(s) Displays
HP 22" LCD
Screen Resolution
1680 x 1050
Hard Drives
250GB Samsung EVO SATA-3 SSD
2TB Seagate ST2000DM001 SATA-2
1.5TB Seagate ST3150041AS SATA
Keyboard
Dell USB
Mouse
Lenovo USB
Internet Speed
Cable via Road Runner 3MB Upload, 30MB Download
Antivirus
Windows Defender, MBAM Pro, MBAE
Browser
Seamonkey
Other Info
UEFI/GPT
PLDS DVD-RW DH16AERSH
Hi blockie,

The Run as Administrator is grayed out

If you create a shortcut, you can then make it run as administrator on the shortcut tab (advanced options). This also has the added advantage of running in a separate memory space, so it is more secure and safer.

Re: the path
I believe it to be correct.
You can check this, by opening Windows Explorer (Windows+E on your keyboard)
and then typing the path \\William-PC\D\Images into the address bar an pressing enter. If it works (and the shared folder opens) then your path should be correct. Alternatively you can check it through an elevated command prompt by mapping it to a spare drive letter. E.g. Typing net use M: \\William-PC\D\Images will map it to the M: drive letter.

Some other thoughts:
- It's hard to tell from the screen print if your path is being read correctly. If you attach the script I'm happy to take a look for you. Also if there are any spaces in it, you may need to use quotes around the path. What is the correct path?
- Try mapping the shared location to a drive letter first, depending on the command you use in the script a UNC path may not be possible.


Good luck

-Tim
 

Attachments

  • shortcut.png
    shortcut.png
    25.9 KB · Views: 12
  • explorer -path.png
    explorer -path.png
    11.8 KB · Views: 4
Last edited:

My Computer

Computer Manufacturer/Model Number
Custom Hack job
OS
Windows 7 Ultimate 64 bit
CPU
Intel(R) Core(TM)2 Quad CPU Q8200 @ 2.33GHz
Motherboard
GigaByte EP45-UD3
Memory
8 GB Kingston
Graphics Card(s)
Nvidia GeForce 9600GT
Sound Card
Soundblaster Audigy
Monitor(s) Displays
AOC x2 22"
Hard Drives
2 x Samsung 500GB (RAID)
2 x Samsung 2TB
1 x WD Green 2TB
1 x Seagate 1TB
1 x Samsung 500GB
PSU
Thermaltake QFan 750W
Case
CM Scout Gaming
Cooling
Coolermaster V10
Keyboard
Microsoft Wireless Keyboard 1000
Mouse
Microsoft Wireless Optical 2000
Internet Speed
320
Other Info
Winfast PVR2000CP
LG DVD-RAM DVD/RW/DL Super Multi
Linksys WMP300Nx2 Wireless Adapter
My backup drive d: was not on the network. Went to the drive properties and shared it. Now it is in there when I do a net view. Thanks. Now I'll go back and reevaluate a lot of my concerns regarding this drive
 

My Computer

Computer type
Laptop
Computer Manufacturer/Model Number
Asus
OS
W7 Ultimate
CPU
2.2 bh Intel Core i3-2330M
Motherboard
Asustek Computer Inc. P53E 1.0
Memory
4MB
Graphics Card(s)
On Board
Sound Card
On Board
Monitor(s) Displays
On Board
Screen Resolution
1366 X 768
Hard Drives
ST9500423AS
ST2000DM USB Backup Drive External
Now that I shared and fooled around with users the original batch file works. However, the Restore image still cannot find an image. The image is in the root of D: drive. I point to D and the folder WindowsImageBackup is there, but cannot be found.

I then booted to the "Repair Disk" and it could not find the image. Tried to connect to the network and couldn't connect.

Now what?
 
Last edited:

My Computer

Computer type
Laptop
Computer Manufacturer/Model Number
Asus
OS
W7 Ultimate
CPU
2.2 bh Intel Core i3-2330M
Motherboard
Asustek Computer Inc. P53E 1.0
Memory
4MB
Graphics Card(s)
On Board
Sound Card
On Board
Monitor(s) Displays
On Board
Screen Resolution
1366 X 768
Hard Drives
ST9500423AS
ST2000DM USB Backup Drive External
Congrats on getting a few of your issues solved.

It's really hard to say what is happening with out more information. Perhaps you can post the script that you have written.

I'd look to ensure that any spaces paths are covered by putting the path in quotes and to include file extensions.

Also what format is the backup in?

RE: WindowsImageBackup is there, but cannot be found
- You said it's on the D drive, is that a local or network drive (from the computer that you are running the restore from)?
- Can you find this through the network under the same user?
- Also check the folder permissions and run the batch as an elevated admin user.

RE: The repair disk
- What are you using for this? is it a custom job? What OS is it?
- Is networking enabled on the repair disk? (it looks like it's not)
 

My Computer

Computer Manufacturer/Model Number
Custom Hack job
OS
Windows 7 Ultimate 64 bit
CPU
Intel(R) Core(TM)2 Quad CPU Q8200 @ 2.33GHz
Motherboard
GigaByte EP45-UD3
Memory
8 GB Kingston
Graphics Card(s)
Nvidia GeForce 9600GT
Sound Card
Soundblaster Audigy
Monitor(s) Displays
AOC x2 22"
Hard Drives
2 x Samsung 500GB (RAID)
2 x Samsung 2TB
1 x WD Green 2TB
1 x Seagate 1TB
1 x Samsung 500GB
PSU
Thermaltake QFan 750W
Case
CM Scout Gaming
Cooling
Coolermaster V10
Keyboard
Microsoft Wireless Keyboard 1000
Mouse
Microsoft Wireless Optical 2000
Internet Speed
320
Other Info
Winfast PVR2000CP
LG DVD-RAM DVD/RW/DL Super Multi
Linksys WMP300Nx2 Wireless Adapter
I found that D drive was not shared. Once shared it showed up in net--view.
Thanks.
 

My Computer

Computer type
Laptop
Computer Manufacturer/Model Number
Asus
OS
W7 Ultimate
CPU
2.2 bh Intel Core i3-2330M
Motherboard
Asustek Computer Inc. P53E 1.0
Memory
4MB
Graphics Card(s)
On Board
Sound Card
On Board
Monitor(s) Displays
On Board
Screen Resolution
1366 X 768
Hard Drives
ST9500423AS
ST2000DM USB Backup Drive External
I found that D drive was not shared. Once shared it showed up in net--view.
Thanks.

It looks like your slowly getting through it.

It's always helpful to check your permissions and sharing through a good old \\TARGETPC\TARGETFOLDER in explorer.

Good luck with the rest of your project. Let us know if you're stuck again.
:D
 

My Computer

Computer Manufacturer/Model Number
Custom Hack job
OS
Windows 7 Ultimate 64 bit
CPU
Intel(R) Core(TM)2 Quad CPU Q8200 @ 2.33GHz
Motherboard
GigaByte EP45-UD3
Memory
8 GB Kingston
Graphics Card(s)
Nvidia GeForce 9600GT
Sound Card
Soundblaster Audigy
Monitor(s) Displays
AOC x2 22"
Hard Drives
2 x Samsung 500GB (RAID)
2 x Samsung 2TB
1 x WD Green 2TB
1 x Seagate 1TB
1 x Samsung 500GB
PSU
Thermaltake QFan 750W
Case
CM Scout Gaming
Cooling
Coolermaster V10
Keyboard
Microsoft Wireless Keyboard 1000
Mouse
Microsoft Wireless Optical 2000
Internet Speed
320
Other Info
Winfast PVR2000CP
LG DVD-RAM DVD/RW/DL Super Multi
Linksys WMP300Nx2 Wireless Adapter
As soon as I got D drive shared net view saw it.
 

My Computer

Computer type
Laptop
Computer Manufacturer/Model Number
Asus
OS
W7 Ultimate
CPU
2.2 bh Intel Core i3-2330M
Motherboard
Asustek Computer Inc. P53E 1.0
Memory
4MB
Graphics Card(s)
On Board
Sound Card
On Board
Monitor(s) Displays
On Board
Screen Resolution
1366 X 768
Hard Drives
ST9500423AS
ST2000DM USB Backup Drive External
net share is another good command to remember. It allows you to see exactly what shares are setup on a computer. That makes it easy to see if teh folder or drive you are trying to access from another computer is actually shared on the target computer.
 

My Computer

Computer type
PC/Desktop
Computer Manufacturer/Model Number
Lenovo IdeaCenter 450
OS
Windows 10 Pro X64
CPU
Intel Quad Core i7-4770 @ 3.4Ghz
Memory
16.0GB PC3-12800 DDR3 SDRAM 1600 MHz
Graphics Card(s)
Intel Integrated HD Graphics
Sound Card
Realtek HD Audio
Monitor(s) Displays
HP 22" LCD
Screen Resolution
1680 x 1050
Hard Drives
250GB Samsung EVO SATA-3 SSD
2TB Seagate ST2000DM001 SATA-2
1.5TB Seagate ST3150041AS SATA
Keyboard
Dell USB
Mouse
Lenovo USB
Internet Speed
Cable via Road Runner 3MB Upload, 30MB Download
Antivirus
Windows Defender, MBAM Pro, MBAE
Browser
Seamonkey
Other Info
UEFI/GPT
PLDS DVD-RW DH16AERSH
Back
Top