[CentOS] Problem resizing partition of nfs volume

David Véjar dvejar at ferreteriasantiago.cl
Thu Aug 12 22:25:23 UTC 2010


cuak

David Véjar

Soporte y Redes

     

Ferretería Santiago

Soluciones de Abastecimiento

Lira 919 Santiago, Chile

Fono: (56 2) 731 3824

 

www.ferreteriasantiago.cl

-----Mensaje original-----
De: centos-bounces at centos.org [mailto:centos-bounces at centos.org] En nombre
de John R Pierce
Enviado el: jueves, 12 de agosto de 2010 18:22
Para: CentOS mailing list
Asunto: Re: [CentOS] Problem resizing partition of nfs volume

  On 08/12/10 2:56 PM, Dan Yamins wrote:
> Hi:
>
> I have an NFS volume that I'm trying to resize a partition on.
>
> Something about the fdisk process is corrupting something on the drive
>
> Before running fdisk, I can mount the volume find:
>
> $ mount /dev/sdo1 /home
>
> ... and the volume is mounted fine.
>
> And,
> $ e2fsck -f /dev/sdo1
> /dev/sdo1: clean, ...
>
>
> But then I run fdisk to rewrite the partition table of this drive, to 
> expand the /dev/sdo1 partition w/o losing data:
>
> $ fdisk /dev/sdo
> # Type 'd' to delete the primary partition
> # Type 'n' for new partition
> # Type 'p' for primary
> # Type '1' for 1st
> # Type Enter for 1st cylinder
> # Type Enter for last cylinder (full disk)
> # Type 'w' to finish
>
> Calling ioctl() ...
> Syncing disks ...
>
> But then something has gone wrong.
>
> $ e2fsck -f /dev/sdo1
> e2fsck 1.39 (29-May-2006)
> Couldn't find ext2 superblock, trying backup blocks...
> e2fsck: Bad magic number in super-block while trying to open /dev/sdm1 ...
>
>
> And I can't mount the volume any more:
> $ mount /dev/sdo1 /home
> mount: you must specify the filesystem type
>
> What am I doing wrong? Am I missing a step of the process?

yeah, you deleted your file system, then created a new empty partition.

instead, you should have used parted(8) or similar to expand the 
partition, then used resize2fs(8) to expand the file system on this 
partition to its new size.

me, I'd strongly suggest doing a full backup of the partition first with 
dump(8)


_______________________________________________
CentOS mailing list
CentOS at centos.org
http://lists.centos.org/mailman/listinfo/centos




More information about the CentOS mailing list