Hi all,
I want to format a drive in a fixed disk using NTFS type.
i am unable to write a c++ program to format a drive.
i want to use low Level disk formation.
Can some tell me how to write a program in c++/vc++ to fromat a drive in NTFS?
I am also thinking to make a FS level driver to format a disk.
is it feasible to make such a driver?
thankx,
regards,
Rakesh
Do you Yahoo!?
Read only the mail you want - Yahoo! Mail SpamGuard.
Hi Rakesh,
— Rakesh Yadav wrote:
> Hi all,
>
> I want to format a drive in a fixed disk using NTFS
> type.
Take a look at this article.
http://www.sysinternals.com/ntw2k/source/fmifs.shtml
> I am also thinking to make a FS level driver to
> format a disk.
> is it feasible to make such a driver?
I don’t think it is a filesystem driver’s job to
format a disk.
A user mode program should be able to mount it as a
RAW volume to format it. Or, it should just write to
the disk partition.
Regards,
Manoj
__________________________________
Do you Yahoo!?
Yahoo! Mail - now with 250MB free storage. Learn more.
http://info.mail.yahoo.com/mail_250
>I want to format a drive in a fixed disk using NTFS type.
Execute “FORMAT /FS:NTFS” from CreateProcess. This is the only reliable way.
Another way is to rev.eng. the interface to UNTFS.DLL and call it. Probably you
will have a month or so dealing with subtle moments of this DLL.
Another way is to use Linux’s rev.enged NTFS on-disk description, but again -
good luck if it is incomplete (and nobody guarantees its completeness).
So, CreateProcess + “FORMAT” is the only reliable way.
i want to use low Level disk formation.
Forget the words “low level disk format” about the hard disks manufactured
after 1992. There is no such a thing.
“Full format” in Windows is just VERIFY command sent to each disk’s sector,
followed by new FS volume formation. “Quick format” is only new FS volume
formation.
Note some OSes like FreeBSD cannot do VERIFY at all. They only have “newfs”,
which is a parallel to Windows Quick Format.
I am also thinking to make a FS level driver to format a disk.
No need at all. This is surely a user-mode task.
Maxim Shatskih, Windows DDK MVP
StorageCraft Corporation
xxxxx@storagecraft.com
http://www.storagecraft.com