Page 1 of 1

batch file to spam a removable drive with partitions?

Posted: 26 Oct 2020 16:39
by kidney bean
I have tried this:

Code: Select all

@echo off
diskpart /s script.txt
diskpart /s script.txt
diskpart /s script.txt
diskpart /s script.txt
diskpart /s script.txt
diskpart /s script.txt
diskpart /s script.txt
diskpart /s script.txt
diskpart /s script.txt
diskpart /s script.txt
diskpart /s script.txt
diskpart /s script.txt
diskpart /s script.txt
and heres the txt:

Code: Select all

SELECT DISK 1
CREATE PARTITION PRIMARY
SELECT PARTITION 1
ACTIVE
FORMAT QUICK
ASSIGN LETTER=E
EXIT
but it wont work, i just stay with 1 non-functioning partition. please help.

Re: batch file to spam a removable drive with partitions?

Posted: 27 Oct 2020 16:25
by aGerman
I don't understand the reason for something like that. But at a brief look you're trying to assign drive letter E again and again. How many drives with the same letter have you ever seen?

Steffen

Re: batch file to spam a removable drive with partitions?

Posted: 27 Oct 2020 18:37
by Eureka!
You forgot to create a VOLUME in your diskpart script :)