Skip to contentSkip to conversation

disappearing xfs partition

DISCUSSION Jeff Breidenbach 5 participants 7 messages Mar 3, 2008 – Mar 11, 2008 4 messages not in the archive

lore
Share & tools
lore
#0 lore raw

I have no special reason to believe this is xfs specific, but is it common for partitions to vanish from the face of the earth, at least as far as mount is concerned? I usually mount by UUID, but here's a sightly interesting transcript by drive letters. If this is not xfs relevant, any suggestions where to start digging?

This is a standard format XFS partition, created with an xfsprogs that I compiled a couple weeks ago from a source code download. Note that other xfs partitions are mounting fine on the same machine.

-- after a fresh reboot ---

# cfdisk /dev/sde

Name Flags Part Type FS Type [Label] Size (MB)
------------------------------------------------------------------------------
sde1 Primary Linux XFS 1000202.28

# mount /dev/sde1 /mnt
mount: special device /dev/sde1 does not exist
# xfs_check /dev/sde1
/dev/sde1: No such file or directory

fatal error -- couldn't initialize XFS library

# fdisk /dev/sde

The number of cylinders for this disk is set to 121601. 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)

Command (m for help): p

Disk /dev/sde: 1000.2 GB, 1000204886016 bytes
255 heads, 63 sectors/track, 121601 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0x00000000

   Device Boot      Start         End      Blocks   Id  System
/dev/sde1               1      121601   976760001   83  Linux
# cat /proc/version
Linux version 2.6.24-8-server (buildd@yellow) (gcc version 4.2.3
(Ubuntu 4.2.3-1ubuntu2)) #1 SMP Thu Feb 14 20:42:20 UTC 2008
# dpkg -l xfsprogs
Desired=Unknown/Install/Remove/Purge/Hold
| Status=Not/Installed/Config-f/Unpacked/Failed-cfg/Half-inst/t-aWait/T-pend
|/ Err?=(none)/Hold/Reinst-required/X=both-problems (Status,Err: uppercase=bad)
||/ Name           Version        Description
+++-==============-==============-============================================
ii  xfsprogs       2.9.5-1        Utilities for managing the XFS filesystem
#1 lore raw

Looks like a udev problem or something is not making /dev/sde1? Have you tried a manual mknod of the device?

Quoted 61 lines · Jeff Breidenbach

I have no special reason to believe this is xfs specific, but is it common for partitions to vanish from the face of the earth, at least as far as mount is concerned? I usually mount by UUID, but here's a sightly interesting transcript by drive letters. If this is not xfs relevant, any suggestions where to start digging?

This is a standard format XFS partition, created with an xfsprogs that I compiled a couple weeks ago from a source code download. Note that other xfs partitions are mounting fine on the same machine.

-- after a fresh reboot ---

# cfdisk /dev/sde

Name Flags Part Type FS Type [Label] Size (MB)
------------------------------------------------------------------------------
sde1 Primary Linux XFS 1000202.28

# mount /dev/sde1 /mnt
mount: special device /dev/sde1 does not exist
# xfs_check /dev/sde1
/dev/sde1: No such file or directory

fatal error -- couldn't initialize XFS library

# fdisk /dev/sde

The number of cylinders for this disk is set to 121601. 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)

Command (m for help): p

Disk /dev/sde: 1000.2 GB, 1000204886016 bytes
255 heads, 63 sectors/track, 121601 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0x00000000

Device Boot Start End Blocks Id System
/dev/sde1 1 121601 976760001 83 Linux

# cat /proc/version
Linux version 2.6.24-8-server (buildd@yellow) (gcc version 4.2.3
(Ubuntu 4.2.3-1ubuntu2)) #1 SMP Thu Feb 14 20:42:20 UTC 2008
# dpkg -l xfsprogs
Desired=Unknown/Install/Remove/Purge/Hold
| Status=Not/Installed/Config-f/Unpacked/Failed-cfg/Half-inst/t-aWait/T-pend
|/ Err?=(none)/Hold/Reinst-required/X=both-problems (Status,Err: uppercase=bad)
||/ Name           Version        Description
+++-==============-==============-============================================
ii  xfsprogs       2.9.5-1        Utilities for managing the XFS filesystem
#2 lore raw
Quoted 2 lines · Justin Piszcz

Looks like a udev problem or something is not making /dev/sde1? Have you tried a manual mknod of the device?

but... it is not an xfs problem. :)

(also check /proc/partitions for sde1...)

-Eric

#3 lore raw
Quoted 3 lines · Eric Sandeen
Quoted 2 lines · Justin Piszcz

Looks like a udev problem or something is not making /dev/sde1? Have you tried a manual mknod of the device?

# mknod /dev/sde1 b 8 65
# mount /dev/sde1 /data2
mount: /dev/sde1 is not a valid block device
Quoted 1 line

but... it is not an xfs problem. :)

Sorry for posting.

Quoted 1 line

(also check /proc/partitions for sde1...)

Not present.

# grep sde /proc/partitions
   8    64  976762584 sde
#8 lore raw
In reply to a message not in the archive

Following up and close out the topic, I got this comment from Eric.

Quoted 5 lines

So parted has this bad habit of making partition tables that cannot actually be read from the disk, and poking the supposedly values directly into the kernel. Then things work fine until reboot, at which
time the partition table cannot be properly read. Usually this turns
into a truncated size due to an overflow....

I'd been using cfdisk and not parted, but that's apparently what happened. Rewriting the partition table with cfdisk fixed everything and allowed the partition to mount. At least for this boot.

Thanks all.

#10 lore raw
In reply to Jeff Breidenbach

On Mon, Mar 03, 2008 at 05:14:38AM -0800, Jeff Breidenbach wrote:
...

Quoted 7 lines
# dpkg -l xfsprogs
Desired=Unknown/Install/Remove/Purge/Hold
| Status=Not/Installed/Config-f/Unpacked/Failed-cfg/Half-inst/t-aWait/T-pend
|/ Err?=(none)/Hold/Reinst-required/X=both-problems (Status,Err: uppercase=bad)
||/ Name           Version        Description
+++-==============-==============-============================================
ii  xfsprogs       2.9.5-1        Utilities for managing the XFS filesystem

As others have already pointed out, the problem you have is not with XFS, but probably with udev.

You may want to upgrade your xfsprogs. Version 2.9.5 has a buggy mkfs (the fs it makes uses only about 3/4 of the partition).

Josef 'Jeff' Sipek.

Signature · 3 lines
Computer Science is no more about computers than astronomy is about
telescopes.
		- Edsger Dijkstra
#9 lore raw
In reply to Jeff Breidenbach

Am Dienstag 04 März 2008 schrieb Jeff Breidenbach:

Quoted 11 lines

Following up and close out the topic, I got this comment from Eric.

Quoted 5 lines

So parted has this bad habit of making partition tables that cannot actually be read from the disk, and poking the supposedly values directly into the kernel. Then things work fine until reboot, at
which time the partition table cannot be properly read. Usually
this turns into a truncated size due to an overflow....

I'd been using cfdisk and not parted, but that's apparently what happened. Rewriting the partition table with cfdisk fixed everything and allowed the partition to mount. At least for this boot.

Hi Jan,

Its always a good idea to check whether the kernel reread the partition table after partitioning with

cat /proc/partitions

If it doesn't have you can tell the kernel to do it manually:

blockdev --rereadpt /dev/sde

If that tells you something about device is busy or so you'd need to unmount partitions on it or reboot.

Ciao,

Signature · 2 lines
Martin 'Helios' Steigerwald - http://www.Lichtvoll.de
GPG: 03B0 0D6C 0040 0710 4AFA  B82F 991B EAAC A599 84C7