Latest LQ Deal: Linux Power User Bundle
Go Back > Forums > Linux Forums > Linux - General
User Name
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.


  Search this Thread
Old 12-15-2017, 08:20 PM   #1
Senior Member
Registered: Apr 2007
Location: Buenos Aires.
Distribution: Slackware
Posts: 3,960

Rep: Reputation: 55
GNU parted 3.1: rm 7 removed partitions 7 and 8.

Working conditions: running Linux 3.10.17 from the only hard disk on this machine as root. This is the disk:
root@darkstar:~# parted -l
Model: ATA ST9320423AS (scsi)
Disk /dev/sda: 320GB
Sector size (logical/physical): 512B/512B
Partition Table: msdos
Disk Flags: 

Number  Start   End     Size    Type      File system  Flags
 1      1049kB  1000MB  999MB   primary   fat32        boot
 2      1000MB  21.0GB  20.0GB  primary   ntfs
 3      21.0GB  42.5GB  21.5GB  primary   ext2
 4      42.5GB  320GB   278GB   extended               lba
 5      44.0GB  45.0GB  991MB   logical   fat32        lba
 6      45.0GB  234GB   189GB   logical   ext2
 7      234GB   255GB   20.9GB  logical   ext2
 8      255GB   275GB   20.0GB  logical   ext2
 9      275GB   320GB   45.2GB  logical   ntfs
Before running parted this was the output of mounted:
root@darkstar:~# mount
/dev/sda8 on / type ext2 (rw)
proc on /proc type proc (rw)
sysfs on /sys type sysfs (rw)
/dev/sda6 on /extra type ext2 (rw)
tmpfs on /dev/shm type tmpfs (rw)
/dev/sda9 on /almacen type fuseblk (rw,allow_other,default_permissions,blksize=4096)
gvfsd-fuse on /home/bill/.gvfs type fuse.gvfsd-fuse (rw,nosuid,nodev,user=bill)
I then ran parted and issued 'rm 7'. I know it immediately executes the command on the disk. It gave a message: trying to communicate to the kernel the device seems busy. Or something like that. I didn't like it and immediately rebooted. But partition 8 (root) had gone for good along with partition 7!

EDIT: I think I know what happened. The root partition received a 7. But not having run lilo yet, the loader redirected control to old partition 7. Had I taken the elementary step of listing the partitions first, I wouldn't be posting now. But maybe it serves somebody. I used to allocate primary partitions for Linux and I am therefor not accostumed to linked partitions, such as logical ones are. Plus there was not udev.

Last edited by stf92; 12-15-2017 at 08:41 PM.
Old 12-16-2017, 09:43 AM   #2
LQ Guru
Registered: Apr 2008
Distribution: PCLinux, Slackware
Posts: 8,150

Rep: Reputation: 1624Reputation: 1624Reputation: 1624Reputation: 1624Reputation: 1624Reputation: 1624Reputation: 1624Reputation: 1624Reputation: 1624Reputation: 1624Reputation: 1624
When a logical partition is deleted, each logical partition with a higher number drops down a number so when you deleted partition 7, your root partition changed from 8 to 7 and I would expect you no longer have a partition 9. I expect the "device seems busy" message you got is because it was changing 8 (root partition) to 7 but exactly how this works, I don't know.

I think your edit paragraph explains and gives the solution.
Old 12-17-2017, 06:15 PM   #3
Senior Member
Registered: Apr 2007
Location: Buenos Aires.
Distribution: Slackware
Posts: 3,960

Original Poster
Rep: Reputation: 55
Yes, thanks for your post.


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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 On
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
rebuild partitions/label from existing partitions - used parted on wrong drive zedmelon Linux - Software 4 07-26-2013 04:42 PM
Help setting up GPT partitions with GNU parted (version 2.3). ssenuta Linux - Hardware 1 04-05-2012 10:02 PM
gnu parted hyphenage Linux - Software 3 08-17-2003 05:41 PM
GNU parted nakkaya Linux - Software 4 03-10-2003 03:17 PM
GNU parted nic_d Linux - Software 1 06-28-2002 05:38 PM > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 08:08 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration