FAQ Search Today's Posts Mark Forums Read
» Video Reviews

» Linux Archive

Linux-archive is a website aiming to archive linux email lists and to make them easily accessible for linux users/developers.


» Sponsor

» Partners

» Sponsor

Go Back   Linux Archive > Debian > Debian User

 
 
LinkBack Thread Tools
 
Old 09-18-2012, 04:27 AM
Kamaraju S Kusumanchi
 
Default Disk /dev/sdb doesn't contain a valid partition table

I am trying to parition a new "Western Digital WD Scorpio Black 750 GB SATA
3 GB/s 7200 RPM 16 MB Cache Internal Bulk/OEM 2.5-Inch Mobile Hard Drive"
but with no success.

$sudo fdisk -l /dev/sdb

Disk /dev/sdb: 750.2 GB, 750156372992 bytes
255 heads, 63 sectors/track, 91201 cylinders, total 1465149166 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000

Disk /dev/sdb doesn't contain a valid partition table


When I tried gparted, it gives the following error
$sudo gparted /dev/sdb
======================
libparted : 2.3
======================
/dev/sdb: unrecognised disk label

In particular, I tried
gparted -> Device -> Create Parition Table -> I chose "msdos" as the new
partition table type -> Apply

After a minute or so, it prints

/dev/sdb: unrecognised disk label

on the command line.

1) What am I doing wrong?
2) Is "msdos" a valid option to choose for this hard drive?
3) Here I connected the hard drive via a USB connection. Could that be a
problem? Should I connect the drive directly via SATA cable in order to
partition?

thanks
raju
--
Kamaraju S Kusumanchi
http://malayamaarutham.blogspot.com/


--
To UNSUBSCRIBE, email to debian-user-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
Archive: http://lists.debian.org/k38tdf$ibf$1@ger.gmane.org
 
Old 09-18-2012, 05:22 AM
Ralf Mardorf
 
Default Disk /dev/sdb doesn't contain a valid partition table

On Tue, 2012-09-18 at 00:27 -0400, Kamaraju S Kusumanchi wrote:
> /dev/sdb: unrecognised disk label

> 2) Is "msdos" a valid option to choose for this hard drive?

Yes it is.

Is there some output if you run

# parted /dev/sdb
mklabel msdos

?

Regards,
Ralf





--
To UNSUBSCRIBE, email to debian-user-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
Archive: http://lists.debian.org/1347945779.1112.41.camel@localhost.localdomain
 
Old 09-18-2012, 05:24 PM
lee
 
Default Disk /dev/sdb doesn't contain a valid partition table

Kamaraju S Kusumanchi <raju.mailinglists@gmail.com> writes:

> I am trying to parition a new "Western Digital WD Scorpio Black 750 GB SATA
> 3 GB/s 7200 RPM 16 MB Cache Internal Bulk/OEM 2.5-Inch Mobile Hard Drive"
> but with no success.
>
> $sudo fdisk -l /dev/sdb
>
> Disk /dev/sdb: 750.2 GB, 750156372992 bytes
> 255 heads, 63 sectors/track, 91201 cylinders, total 1465149166 sectors
> Units = sectors of 1 * 512 = 512 bytes
> Sector size (logical/physical): 512 bytes / 512 bytes
> I/O size (minimum/optimal): 512 bytes / 512 bytes
> Disk identifier: 0x00000000
>
> Disk /dev/sdb doesn't contain a valid partition table

That is to be expected for a new disk. IIRC, fdisk (or was that
cfdisk?) has an option to start over with an empty partition table.

Depending on which version of fdisk you have, there are options you can
use to turn off msdos compatibility and to turn on something else --- I
don't remember what these options were, and my version of fdisk doesn't
have them anymore ("fdisk -n" or "fdisk -nc" maybe?), so I forgot about
them.

Anyway, make a new empty partition table and create a partition and see
if you can write that to disk. Always reboot after creating partitions;
I've seen it going wrong when not rebooting and only re-reading
partition tables.

> 2) Is "msdos" a valid option to choose for this hard drive?

Is "msdos" a useful partition type for you? Try "Linux", and if it
works, you can try to change it to msdos.

> 3) Here I connected the hard drive via a USB connection. Could that be a
> problem? Should I connect the drive directly via SATA cable in order to
> partition?

You should be able to partition it while it's connected to an USB port.
However, there are some operations not supported with USB, so if
everything else fails, connecting the disk to an SATA port might help.


--
Debian testing amd64


--
To UNSUBSCRIBE, email to debian-user-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
Archive: 87obl3tfaa.fsf@yun.yagibdah.de">http://lists.debian.org/87obl3tfaa.fsf@yun.yagibdah.de
 
Old 09-18-2012, 08:55 PM
Andrei POPESCU
 
Default Disk /dev/sdb doesn't contain a valid partition table

On Ma, 18 sep 12, 19:24:45, lee wrote:
>
> > 2) Is "msdos" a valid option to choose for this hard drive?
>
> Is "msdos" a useful partition type for you? Try "Linux", and if it
> works, you can try to change it to msdos.

Partition *table*, not *type*

Kind regards,
Andrei
--
Offtopic discussions among Debian users and developers:
http://lists.alioth.debian.org/mailman/listinfo/d-community-offtopic
 
Old 09-18-2012, 09:46 PM
lee
 
Default Disk /dev/sdb doesn't contain a valid partition table

Andrei POPESCU <andreimpopescu@gmail.com> writes:

> On Ma, 18 sep 12, 19:24:45, lee wrote:
>>
>> > 2) Is "msdos" a valid option to choose for this hard drive?
>>
>> Is "msdos" a useful partition type for you? Try "Linux", and if it
>> works, you can try to change it to msdos.
>
> Partition *table*, not *type*

Are you sure there is such a thing as an "msdos" partition table? There
seem to be a couple types of partition tables, and "msdos" doesn't seem
to be amongst them[1]. Then there are "partition types" and "partition
type codes", see [2].

The OP probably refers to the "partition type code", more commonly
referred to as partition type. IIRC fdisk does that. If it does,
perhaps we should file a bug against fdisk to have that changed to
"partition type code"?


[1]: http://en.wikipedia.org/wiki/Partition_table
[2]: http://en.wikipedia.org/wiki/Disk_partition


--
Debian testing amd64


--
To UNSUBSCRIBE, email to debian-user-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
Archive: 87392fqa0e.fsf@yun.yagibdah.de">http://lists.debian.org/87392fqa0e.fsf@yun.yagibdah.de
 
Old 09-18-2012, 10:20 PM
Tom H
 
Default Disk /dev/sdb doesn't contain a valid partition table

On Tue, Sep 18, 2012 at 5:46 PM, lee <lee@yun.yagibdah.de> wrote:
> Andrei POPESCU <andreimpopescu@gmail.com> writes:
>> On Ma, 18 sep 12, 19:24:45, lee wrote:
>>>
>>> > 2) Is "msdos" a valid option to choose for this hard drive?
>>>
>>> Is "msdos" a useful partition type for you? Try "Linux", and if it
>>> works, you can try to change it to msdos.
>>
>> Partition *table*, not *type*
>
> Are you sure there is such a thing as an "msdos" partition table? There
> seem to be a couple types of partition tables, and "msdos" doesn't seem
> to be amongst them[1]. Then there are "partition types" and "partition
> type codes", see [2].
>
> The OP probably refers to the "partition type code", more commonly
> referred to as partition type. IIRC fdisk does that. If it does,
> perhaps we should file a bug against fdisk to have that changed to
> "partition type code"?

d-i refers to an msdos partition table.

fdisk refers to a dos partition table.

You can choose from a few different partition tables in d-i. The only
other that I remember, that I've used, and that I prefer is gpt.

In fdisk, you can only choose dos (you can also choose a bsd label but
I think that it's in addition to dos but might be wrong...). In gdisk,
you can choose gpt. AFAIK, there are more options in parted.


--
To UNSUBSCRIBE, email to debian-user-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
Archive: http://lists.debian.org/CAOdo=SxxYdjZ0kz8+tpsxoiCub_OFFgk-6zBAwfakHAk0UuHuA@mail.gmail.com
 
Old 09-19-2012, 12:40 AM
Mark Allums
 
Default Disk /dev/sdb doesn't contain a valid partition table

On 9/18/2012 4:46 PM, lee wrote:

Andrei POPESCU <andreimpopescu@gmail.com> writes:


On Ma, 18 sep 12, 19:24:45, lee wrote:



2) Is "msdos" a valid option to choose for this hard drive?


Is "msdos" a useful partition type for you? Try "Linux", and if it
works, you can try to change it to msdos.


Partition *table*, not *type*


Are you sure there is such a thing as an "msdos" partition table? There
seem to be a couple types of partition tables, and "msdos" doesn't seem
to be amongst them[1]. Then there are "partition types" and "partition
type codes", see [2].

The OP probably refers to the "partition type code", more commonly
referred to as partition type. IIRC fdisk does that. If it does,
perhaps we should file a bug against fdisk to have that changed to
"partition type code"?


[1]: http://en.wikipedia.org/wiki/Partition_table
[2]: http://en.wikipedia.org/wiki/Disk_partition





There is confusion here between partition table type and partition type.
The partition table holds information about the different partitions.
An msdos partition *table* can hold a linux partition.


Use msdos, gpt, or nothing: LVM over a physical volume, for a partition
*table* type. gpt has the advantage over msdos (or just 'dos') that it
supports partitions over 2TB in size.


Use linux for partitition type if you don't go for LVM.

Step one: INitialize the disk with a partition table.
Step two: Add some partitions.

At least one partition for the system (root---/), and probably a small
one for swap. Maybe a separate one for /boot, maybe a separate one for
/home.


(I use LVM, so to keep things simple, I put LVM logical volumes inside a
partition (rather than on a bare disk), and put /boot on an 8GB separate
partition.)





--
To UNSUBSCRIBE, email to debian-user-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org

Archive: 50591462.2000903@allums.com">http://lists.debian.org/50591462.2000903@allums.com
 
Old 09-20-2012, 03:15 AM
Kamaraju S Kusumanchi
 
Default Disk /dev/sdb doesn't contain a valid partition table

Ralf Mardorf wrote:

> On Tue, 2012-09-18 at 00:27 -0400, Kamaraju S Kusumanchi wrote:
>> /dev/sdb: unrecognised disk label
>
>> 2) Is "msdos" a valid option to choose for this hard drive?
>
> Yes it is.
>
> Is there some output if you run
>
> # parted /dev/sdb
> mklabel msdos
>

So, I did

$sudo parted /dev/sdb
GNU Parted 2.3
Using /dev/sdb
Welcome to GNU Parted! Type 'help' to view a list of commands.
(parted) mklabel msdos
(parted) quit
Information: You may need to update /etc/fstab.

Even after this, I get the following error if I go back to gparted and try
to create a new partition.

$sudo gparted /dev/sdb
======================
libparted : 2.3
======================
/dev/sdb: unrecognised disk label


I also upgraded to the latest kernel but that did not solve much.

$uname -a
Linux kusumanchi.mae.cornell.edu 3.2.0-3-686-pae #1 SMP Mon Jul 23 03:50:34
UTC 2012 i686 GNU/Linux

thanks
raju

--
Kamaraju S Kusumanchi
http://malayamaarutham.blogspot.com/


--
To UNSUBSCRIBE, email to debian-user-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
Archive: http://lists.debian.org/k3e1su$1jm$1@ger.gmane.org
 
Old 09-20-2012, 03:28 AM
Kamaraju S Kusumanchi
 
Default Disk /dev/sdb doesn't contain a valid partition table

lee wrote:

> Kamaraju S Kusumanchi <raju.mailinglists@gmail.com> writes:
>
>> I am trying to parition a new "Western Digital WD Scorpio Black 750 GB
>> SATA 3 GB/s 7200 RPM 16 MB Cache Internal Bulk/OEM 2.5-Inch Mobile Hard
>> Drive" but with no success.
>>
>> $sudo fdisk -l /dev/sdb
>>
>> Disk /dev/sdb: 750.2 GB, 750156372992 bytes
>> 255 heads, 63 sectors/track, 91201 cylinders, total 1465149166 sectors
>> Units = sectors of 1 * 512 = 512 bytes
>> Sector size (logical/physical): 512 bytes / 512 bytes
>> I/O size (minimum/optimal): 512 bytes / 512 bytes
>> Disk identifier: 0x00000000
>>
>> Disk /dev/sdb doesn't contain a valid partition table
>
> That is to be expected for a new disk. IIRC, fdisk (or was that
> cfdisk?) has an option to start over with an empty partition table.
>
> Depending on which version of fdisk you have, there are options you can
> use to turn off msdos compatibility and to turn on something else --- I
> don't remember what these options were, and my version of fdisk doesn't
> have them anymore ("fdisk -n" or "fdisk -nc" maybe?), so I forgot about
> them.

There are some warnings when I tried to use fdisk to create a new empty DOS
partition table. Do you know how to eliminate the warning?

$fdisk -v
fdisk (util-linux 2.20.1)

$sudo fdisk /dev/sdb
Device contains neither a valid DOS partition table, nor Sun, SGI or OSF
disklabel
Building a new DOS disklabel with disk identifier 0x14879ac2.
Changes will remain in memory only, until you decide to write them.
After that, of course, the previous content won't be recoverable.

Warning: invalid flag 0x0000 of partition table 4 will be corrected by
w(rite)

Command (m for help): p

Disk /dev/sdb: 750.2 GB, 750156372992 bytes
255 heads, 63 sectors/track, 91201 cylinders, total 1465149166 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x14879ac2

Device Boot Start End Blocks Id System

Command (m for help): m
Command action
a toggle a bootable flag
b edit bsd disklabel
c toggle the dos compatibility flag
d delete a partition
l list known partition types
m print this menu
n add a new partition
o create a new empty DOS partition table
p print the partition table
q quit without saving changes
s create a new empty Sun disklabel
t change a partition's system id
u change display/entry units
v verify the partition table
w write table to disk and exit
x extra functionality (experts only)

Command (m for help): o
Building a new DOS disklabel with disk identifier 0xe3c60b5a.
Changes will remain in memory only, until you decide to write them.
After that, of course, the previous content won't be recoverable.

Warning: invalid flag 0x0000 of partition table 4 will be corrected by
w(rite)

Command (m for help): w
The partition table has been altered!

Calling ioctl() to re-read partition table.
Syncing disks.


So, I wrote the partition table but the warning keeps coming back if I run
fdisk again.

$sudo fdisk /dev/sdb
Device contains neither a valid DOS partition table, nor Sun, SGI or OSF
disklabel
Building a new DOS disklabel with disk identifier 0x2c2ba04d.
Changes will remain in memory only, until you decide to write them.
After that, of course, the previous content won't be recoverable.

Warning: invalid flag 0x0000 of partition table 4 will be corrected by
w(rite)

Command (m for help): q


>
> Anyway, make a new empty partition table and create a partition and see
> if you can write that to disk. Always reboot after creating partitions;
> I've seen it going wrong when not rebooting and only re-reading
> partition tables.
>

What do you mean reboot after creating partitions? This is an external hard
drive that does not have any OS. So how can I reboot from it? Do you mean
disconnect and reconnect?

>> 2) Is "msdos" a valid option to choose for this hard drive?
>
> Is "msdos" a useful partition type for you? Try "Linux", and if it
> works, you can try to change it to msdos.
>

There is no "Linux" option. In gparted -> Device -> Create Partition Table -
> Advanced -> Select new partition table type, the available choices are

msdos, aix, amiga, bsd, dvh, gpt, mac, pc98, sun, loop

thanks
raju
--
Kamaraju S Kusumanchi
http://malayamaarutham.blogspot.com/


--
To UNSUBSCRIBE, email to debian-user-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
Archive: http://lists.debian.org/k3e2lo$6dv$1@ger.gmane.org
 
Old 09-20-2012, 05:44 AM
lee
 
Default Disk /dev/sdb doesn't contain a valid partition table

Kamaraju S Kusumanchi <raju.mailinglists@gmail.com> writes:

> lee wrote:
>
> There are some warnings when I tried to use fdisk to create a new empty DOS
> partition table. Do you know how to eliminate the warning?
>
> $fdisk -v
> fdisk (util-linux 2.20.1)
>
> $sudo fdisk /dev/sdb
> Device contains neither a valid DOS partition table, nor Sun, SGI or OSF
> disklabel
> Building a new DOS disklabel with disk identifier 0x14879ac2.
> Changes will remain in memory only, until you decide to write them.
> After that, of course, the previous content won't be recoverable.
>
> Warning: invalid flag 0x0000 of partition table 4 will be corrected by
> w(rite)
>
> Command (m for help): p
>
> Disk /dev/sdb: 750.2 GB, 750156372992 bytes
> 255 heads, 63 sectors/track, 91201 cylinders, total 1465149166 sectors
> Units = sectors of 1 * 512 = 512 bytes
> Sector size (logical/physical): 512 bytes / 512 bytes
> I/O size (minimum/optimal): 512 bytes / 512 bytes
> Disk identifier: 0x14879ac2
>
> Device Boot Start End Blocks Id System
>
> Command (m for help): m
> Command action
> a toggle a bootable flag
> b edit bsd disklabel
> c toggle the dos compatibility flag
> d delete a partition
> l list known partition types
> m print this menu
> n add a new partition
> o create a new empty DOS partition table
> p print the partition table
> q quit without saving changes
> s create a new empty Sun disklabel
> t change a partition's system id
> u change display/entry units
> v verify the partition table
> w write table to disk and exit
> x extra functionality (experts only)
>
> Command (m for help): o
> Building a new DOS disklabel with disk identifier 0xe3c60b5a.
> Changes will remain in memory only, until you decide to write them.
> After that, of course, the previous content won't be recoverable.
>
> Warning: invalid flag 0x0000 of partition table 4 will be corrected by
> w(rite)
>
> Command (m for help): w
> The partition table has been altered!
>
> Calling ioctl() to re-read partition table.
> Syncing disks.
>
>
> So, I wrote the partition table but the warning keeps coming back if I run
> fdisk again.
>
> $sudo fdisk /dev/sdb
> Device contains neither a valid DOS partition table, nor Sun, SGI or OSF
> disklabel
> Building a new DOS disklabel with disk identifier 0x2c2ba04d.
> Changes will remain in memory only, until you decide to write them.
> After that, of course, the previous content won't be recoverable.
>
> Warning: invalid flag 0x0000 of partition table 4 will be corrected by
> w(rite)
>
> Command (m for help): q

Now that's interesting. It looks like either the new partition you have
been writing hasn't actually been written to the disk, or the kernel
didn't realise that the partition table has changed.

> What do you mean reboot after creating partitions? This is an external hard
> drive that does not have any OS. So how can I reboot from it? Do you mean
> disconnect and reconnect?

What I mean is "reboot the computer" (not boot from the new disk you're
trying to partition, just reboot it "normally"). So:


1.) write the new partition table
2.) reboot the computer and run fdisk again and see if it still says the
same

If it still says the same, I'd try to connect the disk to an SATA port
and try it again. If it still doesn't work, return it. Or don't go the
lengths of connecting it to SATA and just return it ...

>>> 2) Is "msdos" a valid option to choose for this hard drive?
>>
>> Is "msdos" a useful partition type for you? Try "Linux", and if it
>> works, you can try to change it to msdos.
>>
>
> There is no "Linux" option. In gparted -> Device -> Create Partition Table -
>> Advanced -> Select new partition table type, the available choices are
>
> msdos, aix, amiga, bsd, dvh, gpt, mac, pc98, sun, loop

Hmmm, I don't know --- I found I need to read up about partition table
types and didn't get to do it yet. What I had in mind is the partition
type code which applies to partitions and not to partition tables.


--
Debian testing amd64


--
To UNSUBSCRIBE, email to debian-user-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
Archive: 87boh1i6zh.fsf@yun.yagibdah.de">http://lists.debian.org/87boh1i6zh.fsf@yun.yagibdah.de
 

Thread Tools




All times are GMT. The time now is 04:40 AM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright 2007 - 2008, www.linux-archive.org