LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 07-13-2017, 06:59 AM   #1
littlebigman
Member
 
Registered: Aug 2008
Location: France
Posts: 658

Rep: Reputation: 35
Question After cloning old HD to new HD: "Partition does not start on physical sector boundary"


Hello,

I used Clonezilla with the default settings to clone my old 145GB HD to a new 1,000GB HD, and have a couple of issues:

1. The root partition is still 145GB

2. fdisk -l complains with "Partition 3 does not start on physical sector boundary.":

Code:
~# df -h
Filesystem      Size  Used Avail Use% Mounted on
/dev/sda1       145G  124G   14G  91% /
udev             10M     0   10M   0% /dev
tmpfs           198M  4.7M  194M   3% /run
tmpfs           495M     0  495M   0% /dev/shm
tmpfs           5.0M     0  5.0M   0% /run/lock
tmpfs           495M     0  495M   0% /sys/fs/cgroup

~# fdisk -l

Disk /dev/sda: 931.5 GiB, 1000204886016 bytes, 1953525168 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disklabel type: dos
Disk identifier: 0x743dbbe5

Device     Boot     Start       End   Sectors   Size Id Type
/dev/sda1  *         2048 310501375 310499328 148.1G 83 Linux
/dev/sda2       310503422 312580095   2076674  1014M  5 Extended
/dev/sda5       310503424 312580095   2076672  1014M 82 Linux swap / Solaris

Partition 3 does not start on physical sector boundary.
Is there a way to solve those issues without recloning with Clonezilla, and if yes, how?

FWIW, the computer is running Debian 8.8.

Thank you.
 
Old 07-13-2017, 07:16 AM   #2
IsaacKuo
Senior Member
 
Registered: Apr 2004
Location: Baton Rouge, Louisiana, USA
Distribution: Debian Stable
Posts: 2,546
Blog Entries: 8

Rep: Reputation: 465Reputation: 465Reputation: 465Reputation: 465Reputation: 465
Quote:
Originally Posted by littlebigman View Post
Hello,

I used Clonezilla with the default settings to clone my old 145GB HD to a new 1,000GB HD, and have a couple of issues:

1. The root partition is still 145GB

2. fdisk -l complains with "Partition 3 does not start on physical sector boundary.":

Code:
~# df -h
Filesystem      Size  Used Avail Use% Mounted on
/dev/sda1       145G  124G   14G  91% /
udev             10M     0   10M   0% /dev
tmpfs           198M  4.7M  194M   3% /run
tmpfs           495M     0  495M   0% /dev/shm
tmpfs           5.0M     0  5.0M   0% /run/lock
tmpfs           495M     0  495M   0% /sys/fs/cgroup

~# fdisk -l

Disk /dev/sda: 931.5 GiB, 1000204886016 bytes, 1953525168 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disklabel type: dos
Disk identifier: 0x743dbbe5

Device     Boot     Start       End   Sectors   Size Id Type
/dev/sda1  *         2048 310501375 310499328 148.1G 83 Linux
/dev/sda2       310503422 312580095   2076674  1014M  5 Extended
/dev/sda5       310503424 312580095   2076672  1014M 82 Linux swap / Solaris

Partition 3 does not start on physical sector boundary.
Is there a way to solve those issues without recloning with Clonezilla, and if yes, how?

FWIW, the computer is running Debian 8.8.

Thank you.
Steps to take:

1) Boot to a liveCD or put the hard drive in another computer

2) edit etc/fstab to comment out the swap entry (put a # in front of the line). You can add a new entry for a new swap partition later. Unfortunately, you may not be able to reliably move or resize the current swap partition without changing its UUID, which will tend to invalidate fstab entries and RESUME device settings. So anyway, I've found swap partitions to be more trouble than they're worth. Since I have NEVER used the hibernate feature, I get no worth out of swap partitions at all! A swap file is so much easier and better.

3) Use gparted (or other partitioning tools) to remove the swap and extended partitions.

4) Use gparted to resize the one remaining partition (the os partition). I'd personally resize it to the maximum size. But there's something to be said for leaving a small amount of space free (maybe 8GB) in case you want to install a second OS partition for some reason. For example, you might want to try out Debian 9 while keeping your Debian 8 setup intact.
 
Old 07-13-2017, 07:21 AM   #3
littlebigman
Member
 
Registered: Aug 2008
Location: France
Posts: 658

Original Poster
Rep: Reputation: 35
Thanks. This host is text-only, so I can't run graphic apps like Gparted. Is there a text-based alternative?

Code:
root@debian:~# cat /etc/fstab
# /etc/fstab: static file system information.
#
# Use 'blkid' to print the universally unique identifier for a
# device; this may be used with UUID= as a more robust way to name devices
# that works even if disks are added and removed. See fstab(5).
#
# <file system> <mount point>   <type>  <options>       <dump>  <pass>
# / was on /dev/sda1 during installation
UUID=7758e3e1-9cba-42f5-a99f-abd8040f4c2b /               ext4    errors=remount-ro 0       1
# swap was on /dev/sda5 during installation
UUID=af9660c1-4d15-4026-9892-969e7efe6a42 none            swap    sw              0       0
/dev/sr0        /media/cdrom0   udf,iso9660 user,noauto     0       0

root@debian:~# blkid
/dev/sda1: UUID="7758e3e1-9cba-42f5-a99f-abd8040f4c2b" TYPE="ext4" PARTUUID="743dbbe5-01"
/dev/sda5: UUID="af9660c1-4d15-4026-9892-969e7efe6a42" TYPE="swap" PARTUUID="743dbbe5-05"
--

Edit: My mistake. I'll burn a bootable USB keydrive with Mint and run Gparted and see how it goes.

I don't use hibernate, but I do put the computer to sleep because I use it as a NAS an hour a day to perform backups.

Last edited by littlebigman; 07-13-2017 at 07:23 AM.
 
Old 07-13-2017, 07:29 AM   #4
IsaacKuo
Senior Member
 
Registered: Apr 2004
Location: Baton Rouge, Louisiana, USA
Distribution: Debian Stable
Posts: 2,546
Blog Entries: 8

Rep: Reputation: 465Reputation: 465Reputation: 465Reputation: 465Reputation: 465
Quote:
Originally Posted by littlebigman View Post
Thanks. This host is text-only, so I can't run graphic apps like Gparted. Is there a text-based alternative?

Code:
root@debian:~# cat /etc/fstab
# /etc/fstab: static file system information.
#
# Use 'blkid' to print the universally unique identifier for a
# device; this may be used with UUID= as a more robust way to name devices
# that works even if disks are added and removed. See fstab(5).
#
# <file system> <mount point>   <type>  <options>       <dump>  <pass>
# / was on /dev/sda1 during installation
UUID=7758e3e1-9cba-42f5-a99f-abd8040f4c2b /               ext4    errors=remount-ro 0       1
# swap was on /dev/sda5 during installation
UUID=af9660c1-4d15-4026-9892-969e7efe6a42 none            swap    sw              0       0
/dev/sr0        /media/cdrom0   udf,iso9660 user,noauto     0       0

root@debian:~# blkid
/dev/sda1: UUID="7758e3e1-9cba-42f5-a99f-abd8040f4c2b" TYPE="ext4" PARTUUID="743dbbe5-01"
/dev/sda5: UUID="af9660c1-4d15-4026-9892-969e7efe6a42" TYPE="swap" PARTUUID="743dbbe5-05"
--

Edit: My mistake. I'll burn a bootable USB keydrive with Mint and run Gparted and see how it goes.

I don't use hibernate, but I do put the computer to sleep because I use it as a NAS an hour a day to perform backups.
Cool!

Suspend functionality is not affected by the presence or absence of swap. Hibernate is the feature that requires a standard swap partition.
 
Old 07-13-2017, 07:44 AM   #5
littlebigman
Member
 
Registered: Aug 2008
Location: France
Posts: 658

Original Poster
Rep: Reputation: 35
Done. In Gparted, I add to choose "Swapoff" in the pop-menu before it would let me delete the swap partition.

Code:
~# fdisk -l

Disk /dev/sda: 931.5 GiB, 1000204886016 bytes, 1953525168 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disklabel type: dos
Disk identifier: 0x743dbbe5

Device     Boot Start        End    Sectors   Size Id Type
/dev/sda1  *     2048 1887105023 1887102976 899.9G 83 Linux

~# df -h
Filesystem      Size  Used Avail Use% Mounted on
/dev/sda1       885G  124G  724G  15% /
udev             10M     0   10M   0% /dev
tmpfs           198M  4.7M  194M   3% /run
tmpfs           495M     0  495M   0% /dev/shm
tmpfs           5.0M     0  5.0M   0% /run/lock
tmpfs           495M     0  495M   0% /sys/fs/cgroup
If Clonezilla can expand a partition while cloning, it should at least make it obvious so users wouldn't have to waste time with the above.

Thank you.
 
Old 07-13-2017, 02:58 PM   #6
jefro
Moderator
 
Registered: Mar 2008
Posts: 21,982

Rep: Reputation: 3625Reputation: 3625Reputation: 3625Reputation: 3625Reputation: 3625Reputation: 3625Reputation: 3625Reputation: 3625Reputation: 3625Reputation: 3625Reputation: 3625
I think this is the problem really. https://askubuntu.com/questions/1569...ector-boundary
 
Old 07-13-2017, 04:29 PM   #7
rknichols
Senior Member
 
Registered: Aug 2009
Distribution: Rocky Linux
Posts: 4,779

Rep: Reputation: 2212Reputation: 2212Reputation: 2212Reputation: 2212Reputation: 2212Reputation: 2212Reputation: 2212Reputation: 2212Reputation: 2212Reputation: 2212Reputation: 2212
In this particular case, it really doesn't matter.
Quote:
Originally Posted by littlebigman View Post
Disk /dev/sda: 931.5 GiB, 1000204886016 bytes, 1953525168 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disklabel type: dos
Disk identifier: 0x743dbbe5

Device Boot Start End Sectors Size Id Type
/dev/sda1 * 2048 310501375 310499328 148.1G 83 Linux
/dev/sda2 310503422 312580095 2076674 1014M 5 Extended
/dev/sda5 310503424 312580095 2076672 1014M 82 Linux swap / Solaris[/CODE]
The only thing misaligned here is the extended partition header. In normal operation, that header is read once when the system boots and is never written. The actual swap partition, /dev/sda5, is properly aligned. It might be considered an ideal alignment, wasting just one 4KB block for the extended partition header, and preserving 1MB alignment for the actual partitions.
 
Old 07-13-2017, 04:59 PM   #8
littlebigman
Member
 
Registered: Aug 2008
Location: France
Posts: 658

Original Poster
Rep: Reputation: 35
The message went away after I deleted the swap partition.
 
  


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
Partition 3 does not start on physical sector boundary. gruncleJim Linux - Hardware 25 08-28-2021 10:02 PM
Partition does not start on physical sector boundary bogeyman2007 Linux - Hardware 9 07-06-2015 07:13 PM
[SOLVED] Partition 2 does not start on physical sector boundary czezz Linux - General 4 01-29-2014 09:44 AM
Partition 1 does not start on physical sector boundary. mshlinux Fedora 9 11-16-2013 10:51 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

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

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