kevyb
Posts: 7
Joined: Sun Aug 19, 2012 5:30 pm

Raspberry Pi Nas

Mon Jan 07, 2013 2:14 pm

Hello,

I have just recieved my raspberry pi, Its the B version with 512 Ram

I plan on using it at my NAS as at the moment my media centre in the living room is constantly turned on and streams the files, mostly music round the house. I'm hoping to use my pi to do this instead.

Alot of people have said that its not good enough to stream HD, If i stream video it will not be HD but just normal quality DVD standard and in AVI format, will the pi cope with that?

I have seen that samba is the way forward, i have followed the instructions, managed to get a hard drive mounted and accessable, but i can't get windows to find the drive, it lets me connect to the PI via SSH so i can use it without it been contected to my tv but other then that i cannot get my windows 8 laptop to connect to it, even if i put in the IP address in directly and try it that way. Im confused to why i can connect to SSH but not actually find the mapped drive or connect via the IP address I'm pretty much a complete noob when it comes to lynux. Any idea's ??

Also i saw something that is called freenas, pretty much a easy to use nas out the box, unfortunatly it doesnt run on linux. Is there any Linux distros specifically for use as a NAS?

If i could get samba working i will stick with this but i just have no idea on what to do to make my windows machine connect to the pi other then ssh. Although im having alot of fun trying and learning the commands but ive hit a wall here. Any help would be appriciated.

Kev.

ski522
Posts: 394
Joined: Sun Sep 30, 2012 2:22 pm

Re: Raspberry Pi Nas

Mon Jan 07, 2013 5:54 pm

How did you configure samba? What guide did you follow? My guess is your samba config is foo and if you get that corrected then your MS machines should be able to see the drive.

kevyb
Posts: 7
Joined: Sun Aug 19, 2012 5:30 pm

Re: Raspberry Pi Nas

Mon Jan 07, 2013 8:25 pm

I have managed to get it to work, i was missing an ntfs-3G module, which is required for a ntfs file system i am currently experiencing a new issue now i have the nas set up. I am getting 0.2-0.3 mb/s when reading but when writing im getting 1.5-2mb/s, which is alot faster, i really need higher read speed, perhaps i need to change file system, but i cannot see any reason write would be faster then read?

capslock118
Posts: 43
Joined: Wed Mar 21, 2012 6:25 pm
Location: New Haven, CT
Contact: Website

Re: Raspberry Pi Nas

Tue Jan 08, 2013 3:12 pm

Who said the pi can't stream HD? I am pretty sure I remember watching just a week ago a certain recent release of a "nocturnal crime fighter who plays dress-up" movie in Blu-Ray format with DTS from my raspberry pi nas server to my other raspberry pi which is an XBMC client and it never buffered or slowed down or anything.

Just be sure to use wired ethernet. I had my pi nas wired to my router which streamed to my other pi connected to a wireless bridge and THAT setup couldn't handle HD, but that was the wireless networks fault and not the pi.

anyways I imagine you are choosing SMB because you want to work with windows clients, as I understand it NFS has less overhead than SMB (though I can't explain why, this is just what i've read)

My raspberry pi nas server is running on raspian using nfs-kernel server and some raspian variation of portmap; sorry it's been a few months since i've set this up and I've since forgotten. I can tell you though, I used this guide and after it was all setup I havn't had any issues:
http://www.cyberciti.biz/faq/how-to-ubu ... ion-howto/

I'm pretty sure though, I did have issues writing to the nfs server from a client, even when I thought I had my rights setup to allow writing, but writing to nfs is not one of my requirements so I've never followed through on that issue...

oh, also, if you plan on having this pi nas server handle more than just NAS (such as certain server software designed to help you find media content online) the pi can handle those services, just have those services pause it's work when you want to do any kind of playback - otherwise the pi may struggle even with SD content when they are all working at the same time.

i hope this blabbering is helpful :)

nginx
Posts: 41
Joined: Sun Dec 09, 2012 2:35 pm

Re: Raspberry Pi Nas

Fri Jan 18, 2013 4:05 am

The Raspberry Pi not being able to stream HD content is pure hogwash. People who spread such fud have clearly failed to set up their Pi properly. I have been using my Pi as a NAS since last month and regularly stream FullHD BluRay content over the network using the Pi. It can even handle two BluRay streams at the same time if the bitrate is under 30mbps.

Your first problem in that you are using NTFS. Reading and writing from a NTFS drive under linux is a very CPU intensive activity and the Pi just doesn't have the processing power. Format your drive with ext4 and you will max out the Pi's 100mbps LAN.

The Pi being able to write faster than read is indeed true to a certain extent. I have reported the same thing before in another thread as have a few other members. The issue in my case was Windows constantly writing to the pagefile and slowing down the average transfer speed while reading from the Pi. Solution is to disable the Windows page file or transfer to a secondary hard drive (not partition) where there is no page file.

technion
Posts: 238
Joined: Sun Dec 02, 2012 9:49 am

Re: Raspberry Pi Nas

Fri Jan 18, 2013 5:08 am

The two things I'm seeing, Samba and NTFS, are both Microsoft technologies.

SMB performs badly enough under Windows, where every successive generation of Windows brings in a new version of SMB and a new promise of "significantly improved performance".

The linux port of that has no chance against a native Linux protocol.

NTFS likewise, up until recently was only there so Linux Live CDs could be used for recovery. Read/write support is quite new to Linux. Again, if you move to ext4, you'll improve dramatically.

I'd second all the above though. Wireless will just add more complexity also.

kevyb
Posts: 7
Joined: Sun Aug 19, 2012 5:30 pm

Re: Raspberry Pi Nas

Fri Jan 18, 2013 11:01 am

Thanks for your advice, It's nice to hear from someone that knows what there talking about,

I have indeed found a answer for this, The problem was windows. The following solved my problem and even with a ntfs i have seen a vast inprovment in speed, i decided to keep ntfs as i wanted to be able to use my external hard drive in windows, but with EX4 i did find the performace was better when transfering large files.

I would like to suggest you update the network card driver and run Windows Update to install all the important updates first.

If it does not work, I also would like to suggest you disable the automatic adjustment for the TCP window size on the network to check the issue.

1. Click Start, click All Programs, and then click Accessories.
2. Right-click Command Prompt, and then click Run as Administrator.
If you are prompted for an administrator password or for confirmation, type your password, or click Continue.
3. At the command prompt, type the following command, and then press ENTER:
netsh interface tcp set global autotuninglevel=disabled
4. Exit the Command Prompt window.
5. Restart the computer.

Hope this helps anyone else having the same problem =]

Return to “Networking and servers”