LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
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!

Notices


Reply
  Search this Thread
Old 03-06-2009, 11:13 AM   #1
harsha101087
Member
 
Registered: Nov 2007
Distribution: Opensuse 11.0 , Fedora 9 , Ubuntu 8.04
Posts: 54

Rep: Reputation: 15
Unhappy Not a valid partition :(


Hi all !!
i have just now installed Fedora 10 on my system.I have plugged by usb drive ( 32GB ) and ran the following command :-

Code:
$ sudo /sbin/fdisk -l

Disk /dev/sda: 120.0 GB, 120034123776 bytes
255 heads, 63 sectors/track, 14593 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0xc3ffc3ff

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1   *           1        3952    31744408+   7  HPFS/NTFS
/dev/sda2            3953        8032    32768000    7  HPFS/NTFS
Partition 2 does not end on cylinder boundary.
/dev/sda3            8033       13038    40210695    5  Extended
/dev/sda4           13039       14593    12490537+  12  Compaq diagnostics
/dev/sda5            8033       10080    16450528+  83  Linux
/dev/sda6           10081       10262     1461883+  82  Linux swap / Solaris
/dev/sda7           10263       13038    22298188+  83  Linux

Disk /dev/sdb: 160.0 GB, 160041885696 bytes
255 heads, 63 sectors/track, 19457 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0xa4b57300

   Device Boot      Start         End      Blocks   Id  System
/dev/sdb1               1       19457   156288321    7  HPFS/NTFS

Disk /dev/sdd: 2063 MB, 2063597568 bytes
64 heads, 62 sectors/track, 1015 cylinders
Units = cylinders of 3968 * 512 = 2031616 bytes
Disk identifier: 0x00000000

   Device Boot      Start         End      Blocks   Id  System

Disk /dev/sdc: 34.3 GB, 34359738368 bytes
64 heads, 32 sectors/track, 32768 cylinders
Units = cylinders of 2048 * 512 = 1048576 bytes
Disk identifier: 0x62696c00

Disk /dev/sdc doesn't contain a valid partition table
Please help me what to do ..???

I tried to create partitions by following the earlier posts already posted ..but i am not getting it correctly ..

Can someone please tell me the step by step procedure to do this ...

This is really urgent ...
 
Old 03-06-2009, 11:25 AM   #2
Matey
Member
 
Registered: Jan 2009
Posts: 114

Rep: Reputation: 17
I didnt see your other post, what is it that is not working?
seems like you have 2 linux partitions to boot from (83), sda5 and 7, are there the files and folders on any of those drives?
sdc is not partitioned yet?
 
Old 03-06-2009, 11:26 AM   #3
Didier Spaier
LQ Addict
 
Registered: Nov 2008
Location: Paris, France
Distribution: Slint64-15.0
Posts: 11,044

Rep: Reputation: Disabled
Let me guess ... Does /dev/hdc represents your USB drive ?

If yes, is it supposed to be already formatted with useful data in it and no back-up ?

If not just create a new partition with fdisk or cfdisk then put a filesystem in it with mkfs.

Bur for now, please unplug it, then plug it in, wait 30 seconds, issue the command 'dmesg|tail' and send the results back here.
 
Old 03-06-2009, 12:05 PM   #4
harsha101087
Member
 
Registered: Nov 2007
Distribution: Opensuse 11.0 , Fedora 9 , Ubuntu 8.04
Posts: 54

Original Poster
Rep: Reputation: 15
Yeah sdc is not partitioned yet....
I tried to create 2 primary partitions in that device and was successful with fdisk ..

Now the problem is that when i use fdisk -l /dev/sdc, i get the same result .. ie this is not a valid partition......

Please tell me what to do
??
 
Old 03-06-2009, 12:24 PM   #5
Didier Spaier
LQ Addict
 
Registered: Nov 2008
Location: Paris, France
Distribution: Slint64-15.0
Posts: 11,044

Rep: Reputation: Disabled
Probably you forgot to write the partition table after having created the partitions. Try again; cfdisk is slightly ease to use. Do not forget to put a filesystem in every partition after that. You can use mkfs for that purpose.
 
Old 03-06-2009, 12:38 PM   #6
harsha101087
Member
 
Registered: Nov 2007
Distribution: Opensuse 11.0 , Fedora 9 , Ubuntu 8.04
Posts: 54

Original Poster
Rep: Reputation: 15
I tried using cfdisk , i think i have created a primary partition and wrote it to the partition table and the file system i have used is WIN95 FAT32..

but still the same output for fdisk -l ...
what to do ..??
shld i give u more information.. please let me .
 
Old 03-06-2009, 12:44 PM   #7
harsha101087
Member
 
Registered: Nov 2007
Distribution: Opensuse 11.0 , Fedora 9 , Ubuntu 8.04
Posts: 54

Original Poster
Rep: Reputation: 15
During cfdisk ( curses based one ) , it's showing some partition like sdc1 but it's not able to write it to the partition table .. properly even though it's saying it's writing it to the table......

I think when i m creating a partition , this shld be /dev/sdc comprising of /dev/sdc1 right ..??

Please tell me ..
 
Old 03-06-2009, 12:48 PM   #8
Didier Spaier
LQ Addict
 
Registered: Nov 2008
Location: Paris, France
Distribution: Slint64-15.0
Posts: 11,044

Rep: Reputation: Disabled
As already asked, please unplug the USB drive, plug it in, wait 30 seconds, issue the command 'dmesg|tail' and send the results back here.

And please give the output of 'lsusb' command when the USB drive is plugged in.

Then hopefully I will be able to see what doesn't go well.
 
Old 03-06-2009, 12:53 PM   #9
harsha101087
Member
 
Registered: Nov 2007
Distribution: Opensuse 11.0 , Fedora 9 , Ubuntu 8.04
Posts: 54

Original Poster
Rep: Reputation: 15
Code:
# dsmeg | tail

sd 7:0:0:0: [sdc] Write Protect is off
sd 7:0:0:0: [sdc] Mode Sense: 0b 00 00 08
sd 7:0:0:0: [sdc] Assuming drive cache: write through
sdc: unknown partition table
sd 7:0:0:0: [sdc] 67108864 512-byte hardware sectors (34360 MB)
sd 7:0:0:0: [sdc] Write Protect is off
sd 7:0:0:0: [sdc] Mode Sense: 0b 00 00 08
sd 7:0:0:0: [sdc] Assuming drive cache: write through
sdc: unknown partition table
usb 5-1.3: USB disconnect, address 8
Code:
$ lsusb

Bus 002 Device 004: ID 0bc2:2000 Seagate RSS LLC Storage Adapter V3 (TPP)
Bus 002 Device 003: ID 04f2:b008 Chicony Electronics Co., Ltd 
Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 007 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 006 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 005 Device 009: ID 2001:2008 D-Link Corp. [hex] 
Bus 005 Device 003: ID 062a:0003 Creative Labs 
Bus 005 Device 002: ID 03eb:0902 Atmel Corp. 
Bus 005 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 004 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 003 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
I hope this information is sufficient.....

Waiting for your reply ..
 
Old 03-06-2009, 01:16 PM   #10
Didier Spaier
LQ Addict
 
Registered: Nov 2008
Location: Paris, France
Distribution: Slint64-15.0
Posts: 11,044

Rep: Reputation: Disabled
I gues your disk is this one :

Bus 002 Device 004: ID 0bc2:2000 Seagate RSS LLC Storage Adapter V3 (TPP)


Let's try again. Please type exactly what follows, but anything after # -- it will be my comments:
Code:
su # to become root
fdisk /dev/sdc # be careful, /dev/sdc should represent your USB drive
p # to check what is in your partition table. My guess is "nothing" But if you find an existing partition ...
d # to delete the existing partition if needed
p # to check there is no more partition if you just deleted one
n # to add a new partition
p # to set the new partition as primary
1 # this will be partition number one
<hit return> # accept the first cylinder of the device beeing the first of the partition
<hit return> # accept the last cylinder of the device beeing the last of the partition
t # to modify the partition's type
b # to choose the type w95 fat32
p # to check your partition table
w # to write your partition table -- do not forget that command!
Then 'fdisk -l' should show something like that -- but the size and in English, of course!
Code:
Disque /dev/sdc: 129 Mo, 129499136 octets
4 heads, 62 sectors/track, 1019 cylinders
Units = cylindres of 248 * 512 = 126976 bytes
Disk identifier: 0x00000000

Périphérique Amorce    Début         Fin      Blocs    Id  Système
/dev/sda1               1        1019      126325    b  W95 FAT32
bash-3.1#

Last edited by Didier Spaier; 03-06-2009 at 01:20 PM.
 
Old 03-06-2009, 01:38 PM   #11
harsha101087
Member
 
Registered: Nov 2007
Distribution: Opensuse 11.0 , Fedora 9 , Ubuntu 8.04
Posts: 54

Original Poster
Rep: Reputation: 15
[code]

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


The number of cylinders for this disk is set to 32768.
There is nothing wrong with that, but this is larger than 1024,
and could in certain setups cause problems with:
1) software that runs at boot time (e.g., old versions of LILO)
2) booting and partitioning software from other OSs
(e.g., DOS FDISK, OS/2 FDISK)
Warning: invalid flag 0x0000 of partition table 4 will be corrected by w(rite)

Command (m for help): p

Disk /dev/sdc: 34.3 GB, 34359738368 bytes
64 heads, 32 sectors/track, 32768 cylinders
Units = cylinders of 2048 * 512 = 1048576 bytes
Disk identifier: 0x55ed5e5d

Device Boot Start End Blocks Id System

Command (m for help): d
No partition is defined yet!

Command (m for help): p

Disk /dev/sdc: 34.3 GB, 34359738368 bytes
64 heads, 32 sectors/track, 32768 cylinders
Units = cylinders of 2048 * 512 = 1048576 bytes
Disk identifier: 0x55ed5e5d

Device Boot Start End Blocks Id System

Command (m for help): n
Command action
e extended
p primary partition (1-4)
p
Partition number (1-4): 1
First cylinder (1-32768, default 1):
Using default value 1
Last cylinder, +cylinders or +size{K,M,G} (1-32768, default 32768):
Using default value 32768

Command (m for help): t
Selected partition 1
Hex code (type L to list codes): L

0 Empty 1e Hidden W95 FAT1 80 Old Minix bf Solaris
1 FAT12 24 NEC DOS 81 Minix / old Lin c1 DRDOS/sec (FAT-
2 XENIX root 39 Plan 9 82 Linux swap / So c4 DRDOS/sec (FAT-
3 XENIX usr 3c PartitionMagic 83 Linux c6 DRDOS/sec (FAT-
4 FAT16 <32M 40 Venix 80286 84 OS/2 hidden C: c7 Syrinx
5 Extended 41 PPC PReP Boot 85 Linux extended da Non-FS data
6 FAT16 42 SFS 86 NTFS volume set db CP/M / CTOS / .
7 HPFS/NTFS 4d QNX4.x 87 NTFS volume set de Dell Utility
8 AIX 4e QNX4.x 2nd part 88 Linux plaintext df BootIt
9 AIX bootable 4f QNX4.x 3rd part 8e Linux LVM e1 DOS access
a OS/2 Boot Manag 50 OnTrack DM 93 Amoeba e3 DOS R/O
b W95 FAT32 51 OnTrack DM6 Aux 94 Amoeba BBT e4 SpeedStor
c W95 FAT32 (LBA) 52 CP/M 9f BSD/OS eb BeOS fs
e W95 FAT16 (LBA) 53 OnTrack DM6 Aux a0 IBM Thinkpad hi ee GPT
f W95 Ext'd (LBA) 54 OnTrackDM6 a5 FreeBSD ef EFI (FAT-12/16/
10 OPUS 55 EZ-Drive a6 OpenBSD f0 Linux/PA-RISC b
11 Hidden FAT12 56 Golden Bow a7 NeXTSTEP f1 SpeedStor
12 Compaq diagnost 5c Priam Edisk a8 Darwin UFS f4 SpeedStor
14 Hidden FAT16 <3 61 SpeedStor a9 NetBSD f2 DOS secondary
16 Hidden FAT16 63 GNU HURD or Sys ab Darwin boot fb VMware VMFS
17 Hidden HPFS/NTF 64 Novell Netware b7 BSDI fs fc VMware VMKCORE
18 AST SmartSleep 65 Novell Netware b8 BSDI swap fd Linux raid auto
1b Hidden W95 FAT3 70 DiskSecure Mult bb Boot Wizard hid fe LANstep
1c Hidden W95 FAT3 75 PC/IX be Solaris boot ff BBT
Hex code (type L to list codes): b
Changed system type of partition 1 to b (W95 FAT32)

Command (m for help): p

Disk /dev/sdc: 34.3 GB, 34359738368 bytes
64 heads, 32 sectors/track, 32768 cylinders
Units = cylinders of 2048 * 512 = 1048576 bytes
Disk identifier: 0x55ed5e5d

Device Boot Start End Blocks Id System
/dev/sdc1 1 32768 33554416 b W95 FAT32

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

Calling ioctl() to re-read partition table.

WARNING: If you have created or modified any DOS 6.x
partitions, please see the fdisk manual page for additional
information.
Syncing disks.

[code]

Code:
[harsha@localhost ~]$ sudo /sbin/fdisk -l

Disk /dev/sda: 120.0 GB, 120034123776 bytes
255 heads, 63 sectors/track, 14593 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0xc3ffc3ff

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1   *           1        3952    31744408+   7  HPFS/NTFS
/dev/sda2            3953        8032    32768000    7  HPFS/NTFS
Partition 2 does not end on cylinder boundary.
/dev/sda3            8033       13038    40210695    5  Extended
/dev/sda4           13039       14593    12490537+  12  Compaq diagnostics
/dev/sda5            8033       10080    16450528+  83  Linux
/dev/sda6           10081       10262     1461883+  82  Linux swap / Solaris
/dev/sda7           10263       13038    22298188+  83  Linux

Disk /dev/sdb: 160.0 GB, 160041885696 bytes
255 heads, 63 sectors/track, 19457 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0xa4b57300

   Device Boot      Start         End      Blocks   Id  System
/dev/sdb1               1       19457   156288321    7  HPFS/NTFS

Disk /dev/sdc: 34.3 GB, 34359738368 bytes
64 heads, 32 sectors/track, 32768 cylinders
Units = cylinders of 2048 * 512 = 1048576 bytes
Disk identifier: 0x148f5aef

Disk /dev/sdc doesn't contain a valid partition table
This is what i m getting..after following your steps..
what shld i do ?
 
Old 03-06-2009, 02:21 PM   #12
Didier Spaier
LQ Addict
 
Registered: Nov 2008
Location: Paris, France
Distribution: Slint64-15.0
Posts: 11,044

Rep: Reputation: Disabled
I am running out of ideas

Not sure it will help but try issuing following command as root. Be very careful: after 'of=' you should make sure that what you type represents your USB drive and not another hard drive. This will "zero" the first sector of the disk:
Code:
dd if=/dev/zero of=/dev/sdc bs=512 count=1
Then follow instructions in my last post again to create the partition.

PS I tried that with a small (512 Mb) USB key, without the 'count=1' option, this 'zeroed' the entire key. Didn't hurt but took a lot of time.
 
Old 03-06-2009, 02:51 PM   #13
harsha101087
Member
 
Registered: Nov 2007
Distribution: Opensuse 11.0 , Fedora 9 , Ubuntu 8.04
Posts: 54

Original Poster
Rep: Reputation: 15
Hi Didier,

I tried the 'dd' command as follows:-

Code:
[harsha@localhost ~]$ sudo dd if=/dev/zero of=/dev/sd
sda   sda1  sda2  sda3  sda4  sda5  sda6  sda7  sdb   sdb1  sdc   
[harsha@localhost ~]$ sudo dd if=/dev/zero of=/dev/sdc bs=512 count=1
1+0 records in
1+0 records out
512 bytes (512 B) copied, 0.00876145 s, 58.4 kB/s
and followed the above steps you have told me ..
but the same o/p ..

Code:
[harsha@localhost ~]$ sudo /sbin/fdisk -l /dev/sdc

Disk /dev/sdc: 34.3 GB, 34359738368 bytes
64 heads, 32 sectors/track, 32768 cylinders
Units = cylinders of 2048 * 512 = 1048576 bytes
Disk identifier: 0x148f5aef

Disk /dev/sdc doesn't contain a valid partition table
 
Old 03-06-2009, 03:12 PM   #14
harsha101087
Member
 
Registered: Nov 2007
Distribution: Opensuse 11.0 , Fedora 9 , Ubuntu 8.04
Posts: 54

Original Poster
Rep: Reputation: 15
Just i downloaded gparted and gave a try , i got the same error in different meaning .. it stopped by saying /dev/sdc1 can't be created something like this ....

So, i think that the partitions /dev/sdc1 /dev/sdc2 are not created ... properly and thus not being updated in the partition table...

now what to do ?? Gparted says that this drive is unallocated ...
 
Old 03-06-2009, 03:23 PM   #15
Didier Spaier
LQ Addict
 
Registered: Nov 2008
Location: Paris, France
Distribution: Slint64-15.0
Posts: 11,044

Rep: Reputation: Disabled
Do you mean that you tried to partition the disk using gparted and it didn't work ?.

If you use the live cd you will find on it a recovery utility (can't remember its name -- check the menu) which can be handy. I did use it once successfully.

Last edited by Didier Spaier; 03-06-2009 at 03:28 PM.
 
  


Reply


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
Disk /dev/hdb doesn't contain a valid partition table LOLobo Linux - Hardware 11 11-06-2008 01:47 AM
Not valid partition table temm Linux - Hardware 5 07-23-2008 04:28 AM
need bigger swap partition but missing a valid partition table compused Linux - Hardware 3 07-02-2008 08:46 AM
Disk doesn't contain a valid partition table expatCM Linux - Hardware 9 10-01-2007 02:38 AM
fdisk said my HD didn't have valid partition table??? bombman Linux - Newbie 6 08-28-2006 11:53 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 12:25 AM.

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