Review your favorite Linux distribution.
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!


  Search this Thread
Old 07-20-2010, 01:22 PM   #1
LQ Newbie
Registered: Jun 2009
Posts: 4

Rep: Reputation: 0
fdisk change patition system id _after_ mkfs.ext3 OK?


I've a new external usb drive that was shipped formatted fat32. I wanted to convert this to ext3; so I performed a mkfs.ext3. I then noticed that fdisk was still reporting the usb drive as fat32 (even after reboot), but mount was reporting ext3: so I fdisk'ed the drive and change the partition's system id to 83 (Linux).

Is this order OK? Will I run into problems?


Old 07-20-2010, 01:40 PM   #2
Registered: Jan 2005
Location: Summer Midwest USA, Central Illinois, Winter Central Florida
Distribution: SlackwareŽ
Posts: 13,099
Blog Entries: 28

Rep: Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322Reputation: 2322

Normal would be to use 'cfdisk' or 'fdisk' to delete the old partition(s) then create a new partition with the desired type. Write the partition table to the device then exit. You should update the partition table by the use of 'partprobe' to update from the changes;
excerpt from 'man partprobe';

partprobe - inform the OS of partition table changes

partprobe [-d] [-s] [devices...]

This manual page documents briefly the partprobe command.

partprobe is a program that informs the operating system kernel of partition table changes, by
requesting that the operating system re-read the partition table.

This program uses short UNIX style options.

-d Don't update the kernel.

-s Show a summary of devices and their partitions.

-h Show summary of options.

-v Show version of program.

You can then format the partition with the filesystem of choice with mkfs;

excerpt 'man mkfs';

mkfs - build a Linux file system SYNOPSIS

mkfs [ -V ] [ -t fstype ] [ fs-options ] filesys [ blocks ] DESCRIPTION

mkfs is used to build a Linux file system on a device, usually a hard disk partition. filesys is either the device name (e.g. /dev/hda1, /dev/sdb2) or the mount point (e.g. /, /usr, /home) for the file system. blocks is the number of blocks to be used for the file system. The exit code returned by mkfs is 0 on success and 1 on failure.
In actuality, mkfs is simply a front-end for the various file system builders (mkfs.fstype) available under Linux. The file system-specific builder is searched for in a number of directories like perhaps /sbin, /sbin/fs, /sbin/fs.d, /etc/fs, /etc (the precise list is defined at compile time but at least contains /sbin and /sbin/fs), and finally in the directories listed in the PATH enviroment variable. Please see the file system-specific builder manual pages for further details.
Please note the underlined information above.



Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
ext3 super block get modified after mkfs.ext3 amitpardesi Programming 1 04-25-2008 10:42 AM
The use of fdisk and mkfs lunlun Linux - Newbie 3 03-06-2006 03:40 AM
Help needed to recover data from ext3 file system where mkfs was issued accidentally kapilsampath Linux - General 4 04-26-2005 07:52 AM
mkfs after fdisk? blackzone Linux - Newbie 1 01-06-2005 11:50 PM > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 04:14 AM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration