Jump to content


 


Register a free account to unlock additional features at BleepingComputer.com
Welcome to BleepingComputer, a free community where people like yourself come together to discuss and learn how to use their computers. Using the site is easy and fun. As a guest, you can browse and view the various discussions in the forums, but can not create a new topic or reply to an existing one unless you are logged in. Other benefits of registering an account are subscribing to topics and forums, creating a blog, and having no ads shown anywhere on the site.


Click here to Register a free account now! or read our Welcome Guide to learn how to use this site.

Photo

Xp Format - Silent Format Of Drive Via Command Line Or Script


  • Please log in to reply
No replies to this topic

#1 hotshot309

hotshot309

  • Members
  • 29 posts
  • OFFLINE
  •  
  • Location:Central Illinois
  • Local time:05:10 AM

Posted 16 October 2006 - 12:19 PM

I'm backing up everything from my C: drive to drive F: using ntbackup, but first, I'm formatting the F: drive. For the formatting part, I want my script (simple batch file) to make it just happen--I don't want to respond to two prompts before formatting each time I run it. Any ideas?

When I do this:

format f: /fs:ntfs /v:"Backup_160"


It prompts me to enter the volume label for this drive. Then it asks if I really want to erase the thing. I am thinking a "/Y" tacked onto the end will suppress the prompting about whether I want to erase it. What about the volume label prompt? I thought the "/v:"Backup_160"" was supposed to answer this question, but it doesn't seem to. Whether I remove the "/v:" parameter or leave it there, it always prompts. (Note that in this case, "Backup_160" was both the old and new name of volume F:; that's what I want it to always be called when I backup.)

Also, what's the best way for me to overwrite the old backup file (Backup.bkf) each time with the new one, via batch file? Is this what the /T and /G switches are for--to overwrite an old backup file?

Here's what I used last night:


format f: /fs:ntfs /v:"Backup_160"
ntbackup backup c:\ /n "Backup.bkf created 10/16/2006 at 1:08 AM" /v:yes /r:no /rs:no /hc:off /SNAP:on /m normal /j "Weekly System Backup" /l:s /f "F:\Backup.bkf"


Thanks,
Hotshot309

Edited by hotshot309, 16 October 2006 - 12:52 PM.


BC AdBot (Login to Remove)

 





0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users