![]() |
![]() OCAU News - Wiki - QuickLinks - Pix - Sponsors |
|
|||||||
| Notices |
|
Sign up for a free OCAU account and this ad will go away! Search our forums with Google: |
![]() |
|
|
Thread Tools |
|
|
#1 |
|
Member
Join Date: Nov 2004
Location: Gold Coast, QLD OS:R.Hat
Posts: 5,845
|
Is it possible to change sda2 to sda1?
|
|
|
|
| Join OCAU to remove this ad! |
|
|
#2 |
|
Member
Join Date: Nov 2002
Posts: 51
|
|
|
|
|
|
|
#3 |
|
Member
Join Date: Nov 2004
Location: Gold Coast, QLD OS:R.Hat
Posts: 5,845
|
Yeah I know. But I'll explain what I done. I've ditched Windows for now and have Ubuntu only running. Before I removed Windows I had:
Code:
sda1 ntfs windows sda2 ext3 ubuntu sda3 extended sda5 linux swap Code:
sda2 ext3 ubuntu sda3 extended sda5 linux swap |
|
|
|
|
|
#4 |
|
Member
Join Date: Jul 2001
Location: Mount Gambier
Posts: 416
|
Doesnt that mean that there is another partition before your new sda2 ppartition ?
Fire up gparted (if you dont have it, sudo apt-get install gparted) to have a look. I am half guessing here so dont bet your data on my advice yet :P
__________________
"In the Morning !" |
|
|
|
|
|
#5 |
|
Member
Join Date: Nov 2002
Posts: 51
|
I think there's still a partition in front of sda2, otherwise it would've been picked up as sda1.
what does fdisk -l /dev/sda say? You can probably merge sda1 and sda2 using parted (or qtparted/gparted etc), but sda1 should definitely still be there. |
|
|
|
|
|
#6 |
|
Member
Join Date: Nov 2004
Location: Gold Coast, QLD OS:R.Hat
Posts: 5,845
|
No I removed sda1 because that's what partition Windows was installed on. And then I used GParted and grew sda2 from 80GB > 160GB to take over the freed space that was left by sda1.
Code:
chris@chris-desktop:~$ sudo fdisk -l /dev/sda Disk /dev/sda: 163.9 GB, 163928604672 bytes 255 heads, 63 sectors/track, 19929 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes Disk identifier: 0x70855789 Device Boot Start End Blocks Id System /dev/sda2 1 19752 158657908+ 83 Linux /dev/sda3 19753 19929 1421752+ 5 Extended /dev/sda5 19753 19929 1421721 82 Linux swap / Solaris
|
|
|
|
|
|
#7 |
|
Member
Join Date: Jul 2001
Location: Mount Gambier
Posts: 416
|
Bugger me.
You'll need someone cleverer than me to answer then !
__________________
"In the Morning !" |
|
|
|
|
|
#8 |
|
Member
Join Date: Jul 2002
Location: Tasmania
Posts: 4,019
|
You shouldn't rely on the numbers anyway... label the partitions and use that for mounting, e.g.
Code:
# e2label /dev/sda2 qwerty /etc/fstab: Replace /dev/sda2 /mnt/qwerty ext3 defaults 0 0 with: LABEL=qwerty /mnt/qwerty ext3 defaults 0 0
__________________
OCAU MetaL Club Member #666 | last.fm 2005: Megadeth | 2006: Opeth | 2007: Blind Guardian, Sodom | 2008: Iron Maiden | 2009: Pain of Salvation, Dream Theater 2010: Ensiferum, Sonata Arctica, Wolves in the Throne Room |
|
|
|
|
|
#9 |
|
Member
Join Date: Jul 2001
Location: Mount Gambier
Posts: 416
|
Does that mean that when you take some sata drives out and maybe plug them into different ports they still mount fine ?
Also does it mean you can reinstall the os and put that same line in fstab and it will pick up the label name from the drive ? Or is the label name stored in the os ? Thanks
__________________
"In the Morning !" |
|
|
|
|
|
#10 |
|
Member
Join Date: Jun 2001
Location: Sydney, Australia
Posts: 620
|
The label name is stored as part of the filesystem, so it's intrinsic to the disk.
I personally don't use labels as they don't tell me which partition is being used at a glance. It seems more intuitive to use LVM and name the logical partitions in a nice way such as /dev/VolGroup00/home as an example. EDIT: Forgot to mention that labels are handy when you have multiple drives to prevent boot issues that might occur when udev feels like swapping your drive references around. Last edited by BIPyjamas; 26th August 2009 at 1:19 PM. |
|
|
|
|
|
#11 |
|
Member
Join Date: Jun 2001
Location: Melbourne
Posts: 1,326
|
I've found the various sda1, sda2 labels just appear in the order the partitions were created. Following from ubuntu's practice, I use the UUID string to keep consistency in after moving around partitions.
__________________
Steve's Ubuntu Tweaks || Flickr
Intel i7-3770K | ASRock Z77 Extreme4-M | 8GB G.Skill 1600 | Gigabyte GTX 560 | Samsung 830 120GB SSD | Seagate 2TB HDD |
|
|
|
|
|
#12 |
|
Member
Join Date: Jun 2006
Location: Hobart
Posts: 1,843
|
UUID all the way
|
|
|
|
|
|
#13 |
|
Member
Join Date: Nov 2004
Location: Gold Coast, QLD OS:R.Hat
Posts: 5,845
|
This is exactly how it works and how it has worked out for me. It's not really a big deal anyway. I think I'll just leave it be for now, until I reinstall when Karmic goes gold.
|
|
|
|
![]() |
| Bookmarks |
|
Sign up for a free OCAU account and this ad will go away! |
| Thread Tools | |
|
|