Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

RedHat disk partition

Posted on 2012-03-23
7
Medium Priority
?
730 Views
Last Modified: 2012-05-31
Can you explain what i am getting "doesn't contain a valid partition table" message below.
I just installed redhat 6. How do I fix this error.

[root@york pam.d]# fdisk -l

Disk /dev/sda: 26.8 GB, 26843545600 bytes
64 heads, 32 sectors/track, 25600 cylinders
Units = cylinders of 2048 * 512 = 1048576 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x000bcc2e

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1   *           2         501      512000   83  Linux
Partition 1 does not end on cylinder boundary.
/dev/sda2             502       25600    25701376   8e  Linux LVM
Partition 2 does not end on cylinder boundary.

Disk /dev/mapper/vg_york-lv_root: 24.2 GB, 24201134080 bytes
255 heads, 63 sectors/track, 2942 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000

Disk /dev/mapper/vg_york-lv_root doesn't contain a valid partition table

Disk /dev/mapper/vg_york-lv_swap: 2113 MB, 2113929216 bytes
255 heads, 63 sectors/track, 257 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000

Disk /dev/mapper/vg_york-lv_swap doesn't contain a valid partition table
0
Comment
Question by:ittechlab
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 3
7 Comments
 
LVL 11

Expert Comment

by:jgiordano
ID: 37759088
can you run the following and add the output

pvs


vgs

lvs
0
 
LVL 40

Expert Comment

by:noci
ID: 37759340
fdisk -l tries to show you ALL partition tables of ALL block volumes.

Now it also counts an LVM volume as such a disk.
But only real drives CAN have usable partition tables.
- The LVM volumes are valid filesystemns (try fsck on them).
 
fdisk is only valid for /dev/hdX or /dev/sdX, not for LVM volumes.


fsck /dev/mapper/vg_york-lv_root
can be done when the volue is read only, or unmounted, not on a r/w mounted disk.
the swap partition can not be checked btw.
0
 

Author Comment

by:ittechlab
ID: 37820343
[root@named]# pvs
  PV         VG       Fmt  Attr PSize  PFree
  /dev/sda2  vg_ittech lvm2 a-   39.51g    0
  /dev/sdc1  vg.learn lvm2 a-    5.00g    0
  /dev/sdc3  my_grp   lvm2 a-   10.00g 5.00g
  /dev/sdd   newvg    lvm2 a-    5.00g 3.00g

[root@named]# vgs
  VG       #PV #LV #SN Attr   VSize  VFree
  my_grp     1   1   0 wz--n- 10.00g 5.00g
  newvg      1   1   0 wz--n-  5.00g 3.00g
  vg.learn   1   1   0 wz--n-  5.00g    0
  vg_ittech 1   2   0 wz--n- 39.51g    0

[root@named]# lvs
  LV      VG       Attr   LSize  Origin Snap%  Move Log Copy%  Convert
  lvol0   my_grp   -wi-a-  5.00g
  lvname  newvg    -wi-ao  2.00g
  data    vg.learn -wi-a-  5.00g
  lv_root vg_ittech -wi-ao 35.57g
  lv_swap vg_ittech  -wi-ao  3.94g
0
Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

 
LVL 40

Expert Comment

by:noci
ID: 37822712
So you a disk (/dev/sda) has a partition table, /dev/sda2 is a lvm volume
disk c partition 1 and 3 are lvm volumes and the Whole sdd disk is one lvm volume
/dev/sdd apearantly has no Partition table.

All the logicals volumes:
 lvol0   my_grp     (partition /dev/sdc3)
  lvname  newvg   (disk /dev/sdd)
  data    vg.learn   (partition /dev/sdc1)
  lv_root vg_ittech  (partition /dev/sda2)
  lv_swap vg_ittech (partition /dev/sda2)
Have no partition table, just a file system, which one depends on you mount instructins in /etc/fstab.
0
 

Author Comment

by:ittechlab
ID: 37897304
let me print my table
0
 

Author Comment

by:ittechlab
ID: 37966931
Disk /dev/mapper/vg_york-lv_swap doesn't contain a valid partition table

why this happen
0
 
LVL 40

Accepted Solution

by:
noci earned 1500 total points
ID: 37967680
Well a swap device doesn't have a partition table, but a swap file header.
Same for the root device, it has a filesystem header.
So if you do a generic search (fdisk -l) over devices you will get an error like this.
Because it sees a device that has no partition table...

Fdisk scans all devices it sees, and LVM volumes behave like devices.
[ partitions in devices are not itself devices. ]

The partition table is not more than the first block of a device with a special format.
0

Featured Post

What is SQL Server and how does it work?

The purpose of this paper is to provide you background on SQL Server. It’s your self-study guide for learning fundamentals. It includes both the history of SQL and its technical basics. Concepts and definitions will form the solid foundation of your future DBA expertise.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Linux users are sometimes dumbfounded by the severe lack of documentation on a topic. Sometimes, the documentation is copious, but other times, you end up with some obscure "it varies depending on your distribution" over and over when searching for …
Join Greg Farro and Ethan Banks from Packet Pushers (http://packetpushers.net/podcast/podcasts/pq-show-93-smart-network-monitoring-paessler-sponsored/) and Greg Ross from Paessler (https://www.paessler.com/prtg) for a discussion about smart network …
Learn how to find files with the shell using the find and locate commands. Use locate to find a needle in a haystack.: With locate, check if the file still exists.: Use find to get the actual location of the file.:
Connecting to an Amazon Linux EC2 Instance from Windows Using PuTTY.
Suggested Courses
Course of the Month11 days, 17 hours left to enroll

636 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question