LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Red Hat
User Name
Password
Red Hat This forum is for the discussion of Red Hat Linux.

Notices


Reply
  Search this Thread
Old 05-27-2014, 05:37 AM   #1
ps2ali
LQ Newbie
 
Registered: May 2014
Posts: 5

Rep: Reputation: Disabled
Resizing FS into 83 linux partition


Hello experts ,

Actually i'am on linux redhat 6.4 enterprise and i would like to resize /dev/sdb2 partition ,this partion is not LVM .however i added space into the disk /dev/sdb but i found too complicate to resize my sdb2 partition ./dev/sdb2 contain an FS for oracle database and i'm affraid to lose data .pleaaaaase help
 
Old 05-27-2014, 09:09 AM   #2
MensaWater
LQ Guru
 
Registered: May 2005
Location: Atlanta Georgia USA
Distribution: Redhat (RHEL), CentOS, Fedora, CoreOS, Debian, FreeBSD, HP-UX, Solaris, SCO
Posts: 7,831
Blog Entries: 15

Rep: Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669
How did you add space to /dev/sdb? Is it a virtual disk or a SAN disk that you grew? Is there a /dev/sdc already?
 
Old 05-27-2014, 09:15 AM   #3
ps2ali
LQ Newbie
 
Registered: May 2014
Posts: 5

Original Poster
Rep: Reputation: Disabled
its a virtual disk , so i dded space directly from vcenter console , there is no sdc disk !
 
Old 05-27-2014, 10:12 AM   #4
MensaWater
LQ Guru
 
Registered: May 2005
Location: Atlanta Georgia USA
Distribution: Redhat (RHEL), CentOS, Fedora, CoreOS, Debian, FreeBSD, HP-UX, Solaris, SCO
Posts: 7,831
Blog Entries: 15

Rep: Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669
First you should backup before try anything. (And should be doing regular backups anyway.)

It seems you should be able to use fdisk or parted to increase the space of partition 2 to the new size. Just make sure fdisk -l /dev/sdb is showing the new space you added. Partitioning does not do a low level format so shouldn't cause a problem but I use LVM so haven't needed to do this.

You'd then just resize the filesystem that is using partition /dev/sdb2 (e.g. using resize2fs or resize4fs for ext2/ext3 or ext4 filesystems).

The post here seems to describe what you need to do:
http://geekpeek.net/resize-filesystem-fdisk-resize2fs/
 
Old 05-27-2014, 10:13 AM   #5
TobiSGD
Moderator
 
Registered: Dec 2009
Location: Germany
Distribution: Whatever fits the task best
Posts: 17,148
Blog Entries: 2

Rep: Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886
Quote:
Originally Posted by ps2ali View Post
/dev/sdb2 contain an FS for oracle database and i'm affraid to lose data
Then make backups. Filesystem operations like resizing can fail at any time, so you have to have a backup before doing anything (you should have them in any case also when not doing system critical stuff, if your harddisk dies tomorrow you also will loose your data).

Anyways, to help you we need more information from you:
- which type of disk
- actual disk layout, provide the output of
Code:
fdisk -l
- filesystem in use on that partition
 
Old 05-27-2014, 11:00 AM   #6
ps2ali
LQ Newbie
 
Registered: May 2014
Posts: 5

Original Poster
Rep: Reputation: Disabled
-its a scsi disk
-# fdisk -l

Disque /dev/sda: 37.6 Go, 37580963840 octets
64 têtes, 32 secteurs/piste, 35840 cylindres
Unités = cylindres de 2048 * 512 = 1048576 octets
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Identifiant de disque : 0x0004b19c

Périphérique Amorce Début Fin Blocs Id Système
/dev/sda1 * 2 501 512000 83 Linux
La partition 1 ne se termine pas sur une frontière de cylindre.
/dev/sda2 502 35840 36187136 8e Linux LVM
La partition 2 ne se termine pas sur une frontière de cylindre.

Disque /dev/sdb: 391.9 Go, 391915765760 octets
255 têtes, 63 secteurs/piste, 47647 cylindres
Unités = cylindres de 16065 * 512 = 8225280 octets
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Identifiant de disque : 0x0007d932

Périphérique Amorce Début Fin Blocs Id Système
/dev/sdb1 1 522 4192933+ 82 Linux swap / Solaris
/dev/sdb2 523 26762 210765115 83 Linux

Disque /dev/dm-0: 34.9 Go, 34938552320 octets
255 têtes, 63 secteurs/piste, 4247 cylindres
Unités = cylindres de 16065 * 512 = 8225280 octets
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Identifiant de disque : 0x00000000

Le disque /dev/dm-0 ne contient pas une table de partition valide

Disque /dev/dm-1: 2113 Mo, 2113929216 octets
255 têtes, 63 secteurs/piste, 257 cylindres
Unités = cylindres de 16065 * 512 = 8225280 octets
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Identifiant de disque : 0x00000000

Le disque /dev/dm-1 ne contient pas une table de partition valide
 
Old 05-30-2014, 04:51 AM   #7
ps2ali
LQ Newbie
 
Registered: May 2014
Posts: 5

Original Poster
Rep: Reputation: Disabled
any feedback !! i followed the link bellow without result
 
Old 06-20-2014, 09:05 AM   #8
canussie
Member
 
Registered: Jun 2014
Location: Calgary
Posts: 50

Rep: Reputation: 7
Did you do a rescan on the dis and do you see the new size?
 
  


Reply



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
resizing PV does not work (lvm) after resizing partition deadeyes Red Hat 5 03-11-2011 11:19 AM
Problem Resizing Linux Partition From Partition magic John_Emad SUSE / openSUSE 5 02-16-2005 12:42 PM
resizing the linux partition tzvik Linux - Software 2 04-30-2003 05:53 AM
resizing the linux partition tzvik Linux - General 5 04-30-2003 04:24 AM
resizing the linux partition tzvik Linux - Newbie 3 04-30-2003 02:25 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Red Hat

All times are GMT -5. The time now is 04:53 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