LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 01-01-2013, 09:22 AM   #31
Dougski
LQ Newbie
 
Registered: Dec 2012
Location: East Lothian
Distribution: Debian for Pi
Posts: 24

Original Poster
Rep: Reputation: Disabled

no, got the
/dez/sda1 is not a valid block device
error message.

The external disk is NTFS if that helps at all?
 
Old 01-01-2013, 09:24 AM   #32
spiky0011
Senior Member
 
Registered: Jan 2011
Location: PLANET-SPIKE
Distribution: /LFS/Debian
Posts: 2,511
Blog Entries: 1

Rep: Reputation: 412Reputation: 412Reputation: 412Reputation: 412Reputation: 412
That was what I was looking for. Can you connect it to the vista machine dose that read the disk ok?
 
Old 01-01-2013, 09:27 AM   #33
Dougski
LQ Newbie
 
Registered: Dec 2012
Location: East Lothian
Distribution: Debian for Pi
Posts: 24

Original Poster
Rep: Reputation: Disabled
ok, so plugged it in, vista has no problem reading the disk. Formatting the disk is a possible, which disk format best suits Linux?
 
Old 01-01-2013, 09:29 AM   #34
spiky0011
Senior Member
 
Registered: Jan 2011
Location: PLANET-SPIKE
Distribution: /LFS/Debian
Posts: 2,511
Blog Entries: 1

Rep: Reputation: 412Reputation: 412Reputation: 412Reputation: 412Reputation: 412
On the pi what is the output of
Code:
ntfs-3g --version
This will allow read write to ntfs file system
 
Old 01-01-2013, 09:29 AM   #35
Dougski
LQ Newbie
 
Registered: Dec 2012
Location: East Lothian
Distribution: Debian for Pi
Posts: 24

Original Poster
Rep: Reputation: Disabled
whilst still in
cd /media/externaldrive?
 
Old 01-01-2013, 09:31 AM   #36
spiky0011
Senior Member
 
Registered: Jan 2011
Location: PLANET-SPIKE
Distribution: /LFS/Debian
Posts: 2,511
Blog Entries: 1

Rep: Reputation: 412Reputation: 412Reputation: 412Reputation: 412Reputation: 412
It wont matter it should what verion of ntfs is installed
 
Old 01-01-2013, 09:32 AM   #37
Dougski
LQ Newbie
 
Registered: Dec 2012
Location: East Lothian
Distribution: Debian for Pi
Posts: 24

Original Poster
Rep: Reputation: Disabled
it gave me a bash error:
-bash: ntfs-3g: command not found

what now?
 
Old 01-01-2013, 09:35 AM   #38
spiky0011
Senior Member
 
Registered: Jan 2011
Location: PLANET-SPIKE
Distribution: /LFS/Debian
Posts: 2,511
Blog Entries: 1

Rep: Reputation: 412Reputation: 412Reputation: 412Reputation: 412Reputation: 412
now you can either install ntfs-3g or you, said you could format disk
 
Old 01-01-2013, 09:39 AM   #39
Dougski
LQ Newbie
 
Registered: Dec 2012
Location: East Lothian
Distribution: Debian for Pi
Posts: 24

Original Poster
Rep: Reputation: Disabled
ok, i'm just emptying the disk to see what disk formats there are.

is there a format which is best for linux?
 
Old 01-01-2013, 09:43 AM   #40
spiky0011
Senior Member
 
Registered: Jan 2011
Location: PLANET-SPIKE
Distribution: /LFS/Debian
Posts: 2,511
Blog Entries: 1

Rep: Reputation: 412Reputation: 412Reputation: 412Reputation: 412Reputation: 412
ext3 or ext4 BUT windows wont be able to read or even see the drive so bear that in mind
 
Old 01-01-2013, 09:45 AM   #41
Dougski
LQ Newbie
 
Registered: Dec 2012
Location: East Lothian
Distribution: Debian for Pi
Posts: 24

Original Poster
Rep: Reputation: Disabled
ok, so if i format it ext3/4, then i won't be able to copy back & forth between my laptop or pc?
also if i format it ext3/4, will it mount more easily?
 
Old 01-01-2013, 09:48 AM   #42
spiky0011
Senior Member
 
Registered: Jan 2011
Location: PLANET-SPIKE
Distribution: /LFS/Debian
Posts: 2,511
Blog Entries: 1

Rep: Reputation: 412Reputation: 412Reputation: 412Reputation: 412Reputation: 412
It will mount in linux ok but windows wont recognize it. By installing ntfs-3g it will still work with windows,
 
Old 01-01-2013, 09:49 AM   #43
Dougski
LQ Newbie
 
Registered: Dec 2012
Location: East Lothian
Distribution: Debian for Pi
Posts: 24

Original Poster
Rep: Reputation: Disabled
ok, sorry, got to go. I might be back later on tonight, but i'll try to format the disk & re-mount it.


Again, thanks for all your help!


ta, dougski
 
Old 01-01-2013, 03:08 PM   #44
TroN-0074
Senior Member
 
Registered: Dec 2011
Location: Michigan USA
Distribution: OpenSUSE 13.2 64bit-Gnome on ASUS U52F
Posts: 1,444

Rep: Reputation: 340Reputation: 340Reputation: 340Reputation: 340
Linux can see NTFS file systems and also FAT32. I think there is a limit in file size about 4 GB or more I am not really sure. So if your external hard drive is formatted in eather of these you can use with Windows and Linux operating system. Again I am not sure but I believe FAT16 is discontinued and FAT32 is in its way out too.

This is what Raspberry Pi site has at this link
http://elinux.org/RPi_Adding_USB_Drives

Quote:
Mounting Drive Partitions

You can plug in a USB flash or hard disk drive while the Pi is running without any problem. The USB device will be sensed by the Pi, however, it probably won't be added to the operating system's file system. That will require some manual intervention to "mount" the device onto the file system. A flash or hard drive may be configured with one, or more, partitions, which you can create yourself in the unlikely event that the drive doesn't already have any. Creating partitions is covered in a separate tutorial: [TBD]
USB Drive Hierarchy

Linux hardware devices are organized and identified by letters under the file system's device hierarchy, /dev. USB drives attached to the Pi are found under the file system as /dev/sdX, where "X" starts with the letter "a" representing the first USB drive, "b" for the second drive, "c" for the third, etc. The individual partitions on each drive are represented by incremented numbers, starting with "1". So, the first partition on the first USB drive is located in the file system as /dev/sda1, the second partition on that drive is /dev/sda2, the third partition on a third drive would be /dev/sdc3, etc.
Mount Points

In order to make a partition accessible to the file system, you need to use the Linux "mount" command, referencing the hardware (e.g., /dev/hda1) and a "mount point" in the file system, which is any empty directory, usually created for the purpose by the user. There is a canonical (i.e., standard) directory path where mount points are usually created: the /mnt directory. You can create a new directory under /mnt for each partition to be mounted, and it can be named anything you want as long as it doesn't contain any spaces. You might want to name it to correspond to the drive's physical characteristics, e.g., /mnt/1GB_USB_flash, or /mnt/120GB_USB_hard_disk.
Mounting a Partition

After creating the mount point for a partition, the only thing left to do is to actually mount the drive partition, e.g.:

sudo mount -o uid=pi,gid=pi /dev/sda1 /mnt/1GB_USB_flash

where:

-o (lowercase letter "o", not the number zero) specifies that an option string follows

uid=pi,gid=pi specifies the user ID is user "pi" and the group ID is "pi" (note there are no spaces allowed between these terms)

/dev/sda1 is the first partition on the first USB drive

/mnt/1GB_USB_flash is the mount point directory
And you probably need to do something like this
Quote:
Adding USB Storage

If you are going to add some drives to share, and you have not already done so add them. For a tutorial on how to connect USB flash drives and hard drives to your Pi, see: Adding USB Drives to a Raspberry Pi

After reading the above tutorial you will want to tweak where your drives are mounted so that they mount in the share area. First create a directory then mount the drive there.

Code:
sudo mkdir /home/shares/public/disk1
Code:
sudo mount /dev/sdxx /home/shares/public/disk1
Where sdxx is where your drive is in the file system's device hierarchy. i.e. /dev/sda1

Remount USB storage on startup

When Raspberry Pi is rebooted Samba service will automatically restart, but USB disk will not be automatically mounted. This can be remedied by editing /etc/fstab

Code:
sudo nano /etc/fstab
and adding following line

Code:
/dev/sdxx /home/shares/public/disk1 auto noatime 0 0
Where sdxx is where your drive is in the file system's device hierarchy. i.e. /dev/sda1 .

If you're having troubles with permissions, use gid and uid options. So, instead of previous line, add following to /etc/fstab

Code:
/dev/sdxx /home/shares/public/disk1 auto gid=pi,uid=pi,noatime 0 0
Again, sdxx is where your drive is in the file system's device hierarchy. i.e. /dev/sda1 .
I got that from their site too here is the link http://elinux.org/R-Pi_NAS

Last edited by TroN-0074; 01-01-2013 at 03:21 PM.
 
1 members found this post helpful.
Old 01-01-2013, 03:17 PM   #45
spiky0011
Senior Member
 
Registered: Jan 2011
Location: PLANET-SPIKE
Distribution: /LFS/Debian
Posts: 2,511
Blog Entries: 1

Rep: Reputation: 412Reputation: 412Reputation: 412Reputation: 412Reputation: 412
Hi TroN-0074

The op wants to be able to write to the drive as well which requires ntfs-3g which is not present on pi so hence the choice of install ntfs or format to ext3/4

Unless you know of a way to write to ntfs file system?
 
1 members found this post helpful.
  


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
[SOLVED] mount Iomega external hard drive on debian squeeze, how to use mount command Foxbat1155 Linux - Hardware 15 02-21-2012 04:55 PM
udev rules to mount external hard drive at mount point akamikeym Gentoo 3 03-31-2010 01:12 PM
External hard drive, how do I mount it? trainee Slackware 12 08-19-2009 11:38 AM
Problem formatting/mounting an OLD Iomega external hard drive. akuthia Linux - Newbie 6 03-05-2009 07:03 PM
unable to copy to external hard-drive running 2.4.20-2m version of debian londonandrew Linux - Hardware 1 03-31-2006 03:50 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 11:45 PM.

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