You are not logged in.

#1 2011-03-16 21:30:29

breaksand30
Member
Registered: 2011-01-13
Posts: 39

Mounting an external HD?

Hey I'm a bit new to Arch Linux but I hope to learn about it more. Anyway I've gotten everything set up. I wan't to restore some files that are compressed in a tar.gz format on an external 2 TB hard drive. Although when I do a

sudo mount /dev/sdc1 /media/backup && cd /media/backup/Backup1/

It works fine and I can see the files but if I try moving them to ~/restores:

mv: cannot remove `Backup1.tar.gz': Operation not permitted

Any idea why this is happening?

Offline

#2 2011-03-16 21:42:25

whatshisname
Member
Registered: 2010-04-24
Posts: 162

Re: Mounting an external HD?

breaksand30 wrote:

Hey I'm a bit new to Arch Linux but I hope to learn about it more. Anyway I've gotten everything set up. I wan't to restore some files that are compressed in a tar.gz format on an external 2 TB hard drive. Although when I do a

sudo mount /dev/sdc1 /media/backup && cd /media/backup/Backup1/

It works fine and I can see the files but if I try moving them to ~/restores:

mv: cannot remove `Backup1.tar.gz': Operation not permitted

Any idea why this is happening?

If your external drive is formatted to fat32, what you're seeing is the permissions error related to "removing" the file (at the end of the "move" operation) as a normal user.  You will probably need to be root to actually delete the files.

You should, however, see that your files were *copied* over to ~/restores.

If the files were not copied, then you may have errors on the drive.  "fsck" the drive and then try again.

Whether or not this is your problem, this would be the first 2 things I would check anyway.

Offline

#3 2011-03-16 21:45:15

ewaller
Administrator
From: Pasadena, CA
Registered: 2009-07-13
Posts: 19,740

Re: Mounting an external HD?

Two questions.  When you did the move, who were you?  If you did it as a regular user, you probably don't have write permissions to the drive.

If you did it as root, then the drive is mounted read-only. 
Also, what is the format of the drive.  If it NTFS, it is very likely mounted as read only.

Check the mount options with mount  (No parameters).
Look at the file permissions on the drive with ls -l for both the files you are trying to move, and for the directory that contains them.


Nothing is too wonderful to be true, if it be consistent with the laws of nature -- Michael Faraday
Sometimes it is the people no one can imagine anything of who do the things no one can imagine. -- Alan Turing
---
How to Ask Questions the Smart Way

Offline

#4 2011-03-16 21:49:42

breaksand30
Member
Registered: 2011-01-13
Posts: 39

Re: Mounting an external HD?

ewaller wrote:

Two questions.  When you did the move, who were you?  If you did it as a regular user, you probably don't have write permissions to the drive.

If you did it as root, then the drive is mounted read-only. 
Also, what is the format of the drive.  If it NTFS, it is very likely mounted as read only.

Check the mount options with mount  (No parameters).
Look at the file permissions on the drive with ls -l for both the files you are trying to move, and for the directory that contains them.

It is ntfs
And I tried as both root and regular user
Output of fdisk -l

Disk /dev/sda: 250.1 GB, 250059350016 bytes
255 heads, 63 sectors/track, 30401 cylinders, total 488397168 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x90909090

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1   *          63      208844      104391   83  Linux
/dev/sda2          208845      738989      265072+  82  Linux swap / Solaris
/dev/sda3          738990    16113194     7687102+  83  Linux
/dev/sda4        16113195   488392064   236139435   83  Linux

Disk /dev/sdc: 999.5 GB, 999501594624 bytes
255 heads, 63 sectors/track, 121515 cylinders, total 1952151552 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x172aec23

   Device Boot      Start         End      Blocks   Id  System
/dev/sdc1            2048  1952151551   976074752    7  HPFS/NTFS

/dev/sdc is the external hard drive.

Last edited by breaksand30 (2011-03-16 21:51:07)

Offline

#5 2011-03-16 21:55:46

skunktrader
Member
From: Brisbane, Australia
Registered: 2010-02-14
Posts: 1,538

Re: Mounting an external HD?

Do you have ntfs-3g installed?  It is required for write access on an ntfs formatted volume.
https://wiki.archlinux.org/index.php/NTFS-3G

Last edited by skunktrader (2011-03-16 21:56:33)

Offline

#6 2011-03-16 21:59:49

ewaller
Administrator
From: Pasadena, CA
Registered: 2009-07-13
Posts: 19,740

Re: Mounting an external HD?

... and the output of mount   ???

It can be dangerous writing to NTFS because it is an undocumented proprietary "standard".  We have access to it because it has been reverse engineered.  Reading is safe.  Writing seems okay, but I would not risk my data or reputation on it.  You never know when Redmond might "fix" something that happens to break compatibility.

As such, NTFS usally defaults to read only.  mount will tell ....


Nothing is too wonderful to be true, if it be consistent with the laws of nature -- Michael Faraday
Sometimes it is the people no one can imagine anything of who do the things no one can imagine. -- Alan Turing
---
How to Ask Questions the Smart Way

Offline

#7 2011-03-16 22:17:05

breaksand30
Member
Registered: 2011-01-13
Posts: 39

Re: Mounting an external HD?

skunktrader wrote:

Do you have ntfs-3g installed?  It is required for write access on an ntfs formatted volume.
https://wiki.archlinux.org/index.php/NTFS-3G

Thanks that worked big_smile

Offline

Board footer

Powered by FluxBB