LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 05-08-2013, 02:13 PM   #1
circus78
Member
 
Registered: Dec 2011
Posts: 273

Rep: Reputation: Disabled
Problem with sfdisk


Hi, I'm trying to copy partiton table from sda (500 GB) to sdb (750 GB), but I got this error:

Quote:
# sfdisk -d /dev/sda /dev/sdb
# partition table of /dev/sda
unit: sectors

/dev/sda1 : start= 2048, size=945309696, Id=fd
/dev/sda2 : start=945311744, size= 31459328, Id=fd
/dev/sda3 : start= 0, size= 0, Id= 0
/dev/sda4 : start= 0, size= 0, Id= 0

sfdisk: ERROR: sector 0 does not have an msdos signature
/dev/sdb: unrecognized partition table type
No partitions found
My goal is to reasseble my two raid (1) device.
I know that I will waste 250 GB as /dev/sdb is greater, but I don't care.

This is my sda's fdisk:

Quote:
# fdisk -l /dev/sda

Disk /dev/sda: 500.1 GB, 500107862016 bytes
255 heads, 63 sectors/track, 60801 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x49e2fd2f

Device Boot Start End Blocks Id System
/dev/sda1 1 58843 472654848 fd Linux raid autodetect
/dev/sda2 58843 60802 15729664 fd Linux raid autodetect
and this is sdb (I KNOW it's greater!):

Quote:
# fdisk -l /dev/sdb

Disk /dev/sdb: 750.2 GB, 750156374016 bytes
255 heads, 63 sectors/track, 91201 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000

Disk /dev/sdb doesn't contain a valid partition table
How can I solve this?
Thank you
 
Old 05-08-2013, 02:39 PM   #2
smallpond
Senior Member
 
Registered: Feb 2011
Location: Massachusetts, USA
Distribution: Fedora
Posts: 4,140

Rep: Reputation: 1263Reputation: 1263Reputation: 1263Reputation: 1263Reputation: 1263Reputation: 1263Reputation: 1263Reputation: 1263Reputation: 1263
I think you are trying to do:
Code:
sfdisk -d /dev/sda | sfdisk /dev/sdb
sfdisk is obsolete, as it will not work with large disks, or disks formatted with GPT tables.
In near future you should be using parted.
 
  


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
sfdisk problem jobesd Linux - General 12 05-04-2020 08:22 AM
SFDISK partitioning udaya31 Linux - General 2 06-10-2010 11:33 AM
How to use sfdisk cthomas Linux - Hardware 3 02-02-2007 08:45 AM
sfdisk and scripting lockejr Linux - General 0 05-29-2003 01:18 PM
sfdisk problem A-dummy Linux - General 0 08-09-2002 03:48 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

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