# Moving Files from One Partition to Another



## yustr (Sep 27, 2004)

Guys,

I have a old windows HD (120G) that I have as a slave on my Ubuntu driven comp. It's split into two partitions (as it was when I was running XP). I can access the NTFS partition (80G) no problem but I can't write to it. (This I understand is typical and I'm not ready to undertake the gymnastics necessary to be able to.)

The second partition (30G) I have formatted as ext3.

What I want to do is copy the MP3's that are on the NTSF portion (80G) to the ext3 partition (30G) and then reformat the NTSF as ext3 to recapture the space.

I thought I could do that in the file browser but I can't access the 30G partition.

I went into the disk management area under admin and can see it there, it's accessable, I can change the access path but I don't know where to place it so it's usable in the file browser. 

Is there another way to do this? 

As always, thanks for the help. I'm happy to be a Linux user even though it's been tough at times. I appreciate the patience you've shown.

yustr


----------



## yustr (Sep 27, 2004)

*Or, How do I make the drive partition available?*

I'm struggling to understand how the Linux file system works. I've been experimenting with it but so far I'm no closer to a solution than I was day before yesterday.

Here's what I want to do (beside copying the music as described above) I want to use the 30G portion to host my files (pics, text, etc.) but I can't seem to figure out how to mount it so I can access it. (I'll want to do the same with the 80G partition once I get the music off and the drive reformatted.)

I've tried going through Admin>Disks and I can set the path and make it accessable, but even if I put it on my desk top when I try to copy a file to it, I'm told that I don't have permission to write to it...????


----------



## shuuhen (Sep 4, 2004)

Look at your /etc/fstab and look for the drives in question. If there is a mountpoint like /mnt/mydrive, then you can type 'mount /mnt/mydrive' and the drive should be ready to be used from that mountpoint. If the drive you want to mount is not in fstab, then you will need to mount it with 'mount -t _filesystem_type device_name mountpoint_'. You may have to run these commands as root (using 'su -' or 'sudo'). I can't tell you how to do this graphically at the moment as I don't usually use KDE.


----------



## yustr (Sep 27, 2004)

Thanks for the response to my question about mounting/formatting a second partition on my second HD. I'm able to access all my partitions.

Part of your advice was to check and change the fstab file.

I can see the fstab file (I'm at the office now so I don't have it in front of me) and I see that it still contains the old direction to load the ntfs partition (since reformatted).

I've been searching ubuntu forums for a guide to edit the fstab file but everyone just says "change the file to...". I've also read plenty of warnings about how an error can really screw things up. 

So, my question is: how do I edit this file?

I know what I want it to read but how do I do it? Do I just type the new line below the ones that exist? To delete a line do I just backspace over it? Then how do I save the changes? 

Pretty basic, I know. Thanks for your patience. (btw: I'm now using gnome rather than kde.)

yustr


----------



## shuuhen (Sep 4, 2004)

Short guide to /etc/fstab (must be edited as root!)

You can comment out lines by putting a '#' at the start of it (everything after a # is ignored). You can also delete a line to get rid of it, although you may want to make a backup of the file or comment out the line until you know the computer is doing what you want (usually you'll know after a reboot).

The /etc/fstab file is just a tab delimited file. The first column and second are fairly self explanitory (device path and mountpoint path, respectively). The third column (FStype) is also (just specifying the filesystem type). 

The fourth column (Options) says whether the device is read-only, read-write, etc. You might see 'noauto', which just means the computer doesn't try to mount it until you tell it to (usually removable drives, sometimes one you just don't want or need to use very often).

The fifth and sixth (Dump and Pass#) tell the computer the priority for backups and consistency checks by fsck (the filesystem checker).



Short guide to vi/vim (all commands to be done without quotes unless otherwise stated)

Open the file with: 'vi /etc/fstab'

Commands to be done from command mode
Enter edit mode with: 'i'
Enter edit mode on a new line above the current one: 'O'
Enter edit mode on a new line below the current one: 'o'

Save with: ':w'
Quit with: ':q'
Save and quit with: ':wq'
Quit without changes with: ':q!'

Delete a line: 'dd'
Delete a character: 'dl'

Command to be done from edit mode:
Enter command mode: 'esc'


Hopefully this answers your questions.


----------



## yustr (Sep 27, 2004)

Thanks

I didn't know about it being in (essentially) columns. Once I got things lined up, it's workng fine. It loads all my drives at start up - with all the right permissions. 

Maybe I'm getting this Linum stuff figured out.....

yustr


----------

