Find the answer to your Linux question:
Results 1 to 4 of 4
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1

    how to transfer data from one hda to another hda partition?

    hi any expert,
    I have several partitions in a hard disk, say, hda1 and hda2 as well as hda3, and now I create a big amount of data in hda1, because there is more space in hda3 unused, so I hope to transfer my data file to hda3 from hda1,
    (1)how to do that?
    (2)how to write my data directly when i run my program in the terminal?
    any help will be appreciated greatly?

  2. #2
    Just Joined!
    Join Date
    Apr 2009
    first you need to mount the target partition
    say, you want to move/copy some files from your current mounted partition
    to the partition /dev/hda3:
    a. create a mount point if it doesn't already exist, mount /dev/hda3 to that
    mount point:

    mkdir -p /mnt/hda3; mount /dev/hda3 /mnt/hda3

    b. if the commands above were successful
    you can now copy/move the files from your current partition to

    (2) you do step a. and output to /mnt/hda3/wherever_subfolder_you_want

    replace hda3 by whatever destination partition you want to use

    When you are done, don't forget to unmount the partition:

    umount /mnt/hda3

  3. #3
    SuperMod (Back again) devils casper's Avatar
    Join Date
    Jun 2006
    Chandigarh, India
    (1)how to do that?
    (2)how to write my data directly when i run my program in the terminal?
    Its very simple. Just mount hda3 partition and move data of hda1 to hda3.

    Let say, hda3 has ext3 filesystem :
    Execute this in Terminal
    su -
    mkdir /media/hda3
    mount -t ext3 /dev/hda3 /media/hda3
    chown -R user_id:group_id /media/hda3
    Above code will mount hda3 partition at /media/hda3. chown command will give read/write access to Regular user for data transfer.
    Execute id command as Regular User to confirm user_id and group_id.

    If you have any confusion, post the output of fdisk -l command here.
    su -
    fdisk -l
    * Its small L in fdisk -l.
    It is amazing what you can accomplish if you do not care who gets the credit.
    New Users: Read This First

  4. $spacer_open
  5. #4


    hi thanks so much!

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts