Sponsored Content
Top Forums Shell Programming and Scripting Automating partitioning setup of /dev/sda on /dev/sdc Post 302944760 by RogerBaran on Thursday 21st of May 2015 03:22:01 PM
Old 05-21-2015
The first time I used the DD to copy the first 2048 sectors off the drive and then I used dd to also copy both of the other partitions. At that point gdisk would complain that I had a corrupt GPT table and that my partition was over running X number of sectors into the next partition. I read somewhere that that's because the way that the drive handles writing the information to the disc is based upon the geometry of the cylinders heads and sectors ...

---------- Post updated at 02:22 PM ---------- Previous update was at 02:19 PM ----------

That's why I decided trying to copy the partition information over to another drive was not a good idea and that what I should actually do is just go ahead and zap a disc get a brand new GPT on there and then format it out one partition at a time and then copy the data into it
 

9 More Discussions You Might Find Interesting

1. Solaris

URGENT - setup port and dump all output to /dev/null or a file

Please help urgently. I need to setup up some sort of service on a solaris server on a port. I dont need it do anything special, anything that is sent to this port from an external server should be dump to /dev/null or a flat file.. Can you help urgently? (1 Reply)
Discussion started by: frustrated1
1 Replies

2. Solaris

What is /dev/tty /dev/null and /dev/console

Hi, Anyone can help My solaris 8 system has the following /dev/null , /dev/tty and /dev/console All permission are lrwxrwxrwx Can this be change to a non-world write ?? any impact ?? (12 Replies)
Discussion started by: civic2005
12 Replies

3. UNIX for Dummies Questions & Answers

Sending alt-n to /dev/pts/1 from process bound to /dev/pts/2

Hello, i am using finch (unix commandline instant messaging client using libgnt) which is running connected to /dev/pts/1 Now I would like to "remote control" the program by sending the key combinations normally typed on the keyboard from a programm in another shell. So I tried:... (0 Replies)
Discussion started by: mentos
0 Replies

4. Slackware

CUPS setup / dev/lp0 perms. ... Slow printing.

Hello, Ive got an HP LaserJet 2100 / parallel interface. I had some troubles getting going due to non-working cups drivers. Updated cups and also used a .ppd.gz file from something HP provided. found the files here... www.linuxprinting.org/show_printer.cgi?recnum=HP-LaserJet_2100 Anyways.... (1 Reply)
Discussion started by: agentrnge
1 Replies

5. Solaris

Lun remove, stuck in /dev/dsk and /dev/rdsk

So, we removed a LUN from the SAN and the system is refusing to remove the references to it in the /dev folder. I've done the following: devfsadm -Cv powermt -q luxadm -e offline <drive path> luxadm probe All those commands failed to remove the path. The drive stills shows up as <drive... (13 Replies)
Discussion started by: DustinT
13 Replies

6. AIX

Difference between /dev/hdisk and /dev/rhdisk

Hi, How can i check that i am using RAW devices for storage in my AIX machine... Also after adding a LUN from storage to a aix host, when i check /dev in the host, i can see both rhdisk and hdisk with same number eg: dcback1(root):/dev>ls -lrt | grep disk12 crw------- 1 root ... (4 Replies)
Discussion started by: jibujacob
4 Replies

7. AIX

Problem in /dev/hd1 and /dev/hd9var

Hello AIXians, I can't boot my AIX, it hangs and stops at the code error: 0518 After searching google, I knew the problem is due to problems in File Systems. So the solution is booting from any bootable media, then run these commands in maintenance mode: #fsck -y /dev/hd4 #fsck -y... (3 Replies)
Discussion started by: Mohannad
3 Replies

8. Red Hat

Changing grub from /dev/sda to /dev/sdb

Hi, Please suggest steps to change grub from /dev/sda to /dev/sdb, (1 Reply)
Discussion started by: manoj.solaris
1 Replies

9. HP-UX

Dev/urandom and dev/random missing in HP-UX

Hi, In our HP-UX B.11.11. I could not find dev/urandom and dev/random Are all pseudo-devices implemented as device drivers, or in need to run /configure some package to install the package to have dev/urandom. Please help (4 Replies)
Discussion started by: rashi
4 Replies
mpartition(1)						      General Commands Manual						     mpartition(1)

Name
       mpartition - partition an MSDOS hard disk

Note of warning
       This  manpage  has been automatically generated from mtools's texinfo documentation, and may not be entirely accurate or complete.  See the
       end of this man page for details.

Description
       The mpartition command is used to create MS-DOS file systems as partitions.  This is intended to be used on non-Linux systems, i.e. systems
       where fdisk and easy access to SCSI devices are not available.  This command only works on drives whose partition variable is set.

       mpartition -p drive
       mpartition -r drive
       mpartition -I [-B bootSector] drive
       mpartition -a drive
       mpartition -d drive
       mpartition -c [-s sectors] [-h heads]
       [-t cylinders] [-v [-T type] [-b
       begin] [-l length] [-f]

       Mpartition supports the following operations:

       p      Prints a command line to recreate the partition for the drive.  Nothing is printed if the partition for the drive is not defined, or
	      an inconsistency has been detected.  If verbose (-v) is also set, prints the current partition table.

       r      Removes the partition described by drive.

       I      Initializes the partition table, and removes all partitions.

       c      Creates the partition described by drive.

       a      "Activates" the partition, i.e. makes it bootable.  Only one partition can be bootable at a time.

       d      "Deactivates" the partition, i.e. makes it unbootable.

       If no operation is given, the current settings are printed.

       For partition creations, the following options are available:

       s sectors
	      The number of sectors per track of the partition (which is also the number of sectors per track for the whole drive).

       h heads
	      The number of heads of the partition (which is also the number of heads for the whole drive).  By default, the geometry  information
	      (number of sectors and heads) is figured out from neighboring partition table entries, or guessed from the size.

       t cylinders
	      The number of cylinders of the partition (not the number of cylinders of the whole drive.

       b begin
	      The  starting offset of the partition, expressed in sectors. If begin is not given, mpartition lets the partition begin at the start
	      of the disk (partition number 1), or immediately after the end of the previous partition.

       l length
	      The size (length) of the partition, expressed in sectors.  If end is not given, mpartition figures out the size from the	number	of
	      sectors,	heads  and  cylinders.	 If these are not given either, it gives the partition the biggest possible size, considering disk
	      size and start of the next partition.

       The following option is available for all operation which modify the partition table:

       f      Usually, before writing back any changes to the partition, mpartition performs certain consistency  checks,  such  as  checking  for
	      overlaps	and  proper alignment of the partitions.  If any of these checks fails, the partition table is not changes.  The -f allows
	      you to override these safeguards.

       The following options are available for all operations:

       v      Together with -p prints the partition table as it is now (no change operation), or as it is after it is modified.

       vv     If the verbosity flag is given twice, mpartition will print out a hexdump of the partition table when reading it from and writing it
	      to the device.

       The following option is available for partition table initialization:

       B bootSector
	      Reads the template master boot record from file bootSector.

See Also
       Mtools' texinfo doc

Viewing the texi doc
       This  manpage  has  been automatically generated from mtools's texinfo documentation. However, this process is only approximative, and some
       items, such as crossreferences, footnotes and indices are lost in this translation process.  Indeed, these items have no appropriate repre-
       sentation  in  the manpage format.  Moreover, not all information has been translated into the manpage version.	Thus I strongly advise you
       to use the original texinfo doc.  See the end of this manpage for instructions how to view the texinfo doc.

       *      To generate a printable copy from the texinfo doc, run the following commands:

		     ./configure; make dvi; dvips mtools.dvi

       *      To generate a html copy,	run:

		     ./configure; make html

       A premade html can be found at `http://www.gnu.org/software/mtools/manual/mtools.html'

       *      To generate an info copy (browsable using emacs' info mode), run:

		     ./configure; make info

       The texinfo doc looks most pretty when printed or as html.  Indeed, in the info version certain examples are difficult to read due  to  the
       quoting conventions used in info.

mtools-4.0.18							      09Jan13							     mpartition(1)
All times are GMT -4. The time now is 08:36 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy