473,322 Members | 1,409 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,322 software developers and data experts.

format (command) syntax...

19
hi!!! i cannot find the proper SYNTAX of the command FORMAT in linux....help!!!
Feb 14 '07 #1
9 9989
Motoma
3,237 Expert 2GB
hi!!! i cannot find the proper SYNTAX of the command FORMAT in linux....help!!!
What type (a.k.a. file format) of partition are you trying to format to?
Feb 14 '07 #2
cess
19
What type (a.k.a. file format) of partition are you trying to format to?
ALL i NEED IS ITS SYNTAX, sample in cp syntax:
cp [OPTION]... SOURCE DEST
cp [OPTION]... SOURCE... DIRECTORY
cp [OPTION]... --target-directory=DIRECTORY SOURCE...
Feb 14 '07 #3
Motoma
3,237 Expert 2GB
I don't make it a habit of asking useless questions; the desired format (i.e. ext2, ext3, reiserfs, fat32) changes the tool you use to format (i.e. the command line tool: mke2fs, mke2fs -j, mkreiserfs, mkdosfs) and the command line arguments.
Feb 14 '07 #4
cassbiz
202 100+
I am trying to understand your question.

You are asking for a format command in 'cp'?

If you just want to know how to copy the take a look at this thread

If that is not the case, please be a little more specific as in what you are trying to accomplish (in detail).
Feb 14 '07 #5
Motoma
3,237 Expert 2GB
I am trying to understand your question.

You are asking for a format command in 'cp'?

If you just want to know how to copy the take a look at this thread

If that is not the case, please be a little more specific as in what you are trying to accomplish (in detail).
I think he was just using cp as an example of the response he was looking for from us. He doesn't realize that Linux does not have a flat 'format' command; rather, each partition type has it's own command with it's own (albeit similar) flags.
Feb 14 '07 #6
cess
19
I think he was just using cp as an example of the response he was looking for from us. He doesn't realize that Linux does not have a flat 'format' command; rather, each partition type has it's own command with it's own (albeit similar) flags.
oh yah!! i am just using cp as an example.. thanks for the answers!.. next time, I'll try my best to ask USEFUL QUESTIONS...
Feb 15 '07 #7
Motoma
3,237 Expert 2GB
oh yah!! i am just using cp as an example.. thanks for the answers!.. next time, I'll try my best to ask USEFUL QUESTIONS...
If you would simply answer my question, (what format you need) I would happily give you the command and it's usage.
Feb 15 '07 #8
cess, if you want a Linux equivalent to the DOS/Windows "FORMAT" command for formatting disks, then Motoma and cassbiz are both correct, that you need to know what you are trying to format and how.

If you mean what are the parameters and options to a command (such as mkfs, the linux equiv of FORMAT) then you need to say which command.

An example of formatting a disk in Linux, to the ext3 filesystem format (compare to NTFS) would be:

mkfs -t ext2 /dev/hda1

Wheras to format the same partition to FAT32, you would use:

mkfs -t vfat /dev/hda1

You need to bear in mind that you need to be ROOT to execute those commands, because they can seriously hose your system.

Alternatively, if you need to format a floppy disk, it's easier to use the mformat command, which is an analogue to the dos/win format command, and takes largely the same parameters. This tool is not always installed - you may have to install your distro's mtools package to get this to work.

In all cases, you can use the "man" command to read the online manual docu on all system commands:

man mkfs
man mke2fs
man mformat

If you're not sure what the command is, you can use a keyword search with man, like:

man -k format

The man program is interactive, based on the vi editor. You can search through the text with the '/' command, use the cursor keys and page-up/dn to scroll, and quit the program with 'q'

hth,
-cybervegan
Feb 15 '07 #9
cess
19
cess, if you want a Linux equivalent to the DOS/Windows "FORMAT" command for formatting disks, then Motoma and cassbiz are both correct, that you need to know what you are trying to format and how.

If you mean what are the parameters and options to a command (such as mkfs, the linux equiv of FORMAT) then you need to say which command.

An example of formatting a disk in Linux, to the ext3 filesystem format (compare to NTFS) would be:

mkfs -t ext2 /dev/hda1

Wheras to format the same partition to FAT32, you would use:

mkfs -t vfat /dev/hda1

You need to bear in mind that you need to be ROOT to execute those commands, because they can seriously hose your system.

Alternatively, if you need to format a floppy disk, it's easier to use the mformat command, which is an analogue to the dos/win format command, and takes largely the same parameters. This tool is not always installed - you may have to install your distro's mtools package to get this to work.

In all cases, you can use the "man" command to read the online manual docu on all system commands:

man mkfs
man mke2fs
man mformat

If you're not sure what the command is, you can use a keyword search with man, like:

man -k format

The man program is interactive, based on the vi editor. You can search through the text with the '/' command, use the cursor keys and page-up/dn to scroll, and quit the program with 'q'

hth,
-cybervegan
okkkk!! I got it!!!! thanks!!!!
Feb 16 '07 #10

Sign in to post your reply or Sign up for a free account.

Similar topics

5
by: S.Patten | last post by:
Hi, I have a problem with updating a datetime column, When I try to change the Column from VB I get "Incorrect syntax near '942'" returned from '942' is the unique key column value ...
2
by: addi | last post by:
What getdate() syntax command can give me time in the following format: 10:41:55 AM Regards, Addi
6
by: Danny Lesandrini | last post by:
I'm using an Access database to drive a web site and the colors of various table backgrounds are stored in Access. I want users of the Access database to be able to select colors for the site, but...
6
by: Stuart McGraw | last post by:
I am looking for a VBA "format" or "template" function, that is, a function that takes a format string and a varying number of arguments, and substitutes the argument values into the format string...
5
by: Tim Marsden | last post by:
Hello, I am building a parameterised query in vb.net for execution against a SQL server database. I am using a OLEDB command and OLEDB parameters. If one of the parameters is a date I sometimes...
8
by: jcrouse | last post by:
I am trying to run a command from a command prompt using the shell command. Here is the syntax I want to execute: Shell(lblMameExePath.Text & " -listinfo >" & Application.StartupPath &...
4
by: Johnny Ruin | last post by:
What do you think of a query that generates a System.Data.SqlClient.SqlException when submitted via a application, but when run through QueryAnalyzer or EnterpriseManager doesn't generate a error?...
5
by: mabond | last post by:
Hi VB.NET 2005 Express edition Microsoft Access 2000 (SP-3) Having trouble writing an "insert into" command for a Microsoft table I'm accessing through oledb. I've tried to follow the same...
19
by: Neil Cerutti | last post by:
Where can I find documentation of what Python accepts as the filename argument to the builtin function file? As an example, I'm aware (through osmosis?) that I can use '/' as a directory...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.