Lastb0isct
Posts: 23
Joined: Thu Dec 29, 2011 9:42 pm

Re: RP-B used as Downloader with separate box as storage

Thu Dec 29, 2011 9:53 pm

Hi all,

I am really excited for the RPi to come out and just wanted to throw an idea out there.  I've been keeping tabs on the forums and have noticed a lot of people planning on using their RPi's for HTPCs or Home Servers.  I'm definitely going to be setting up my first RPi as a HTPC for my bedroom, but wanted to expand on that and thought about how I can save more electricity with another one acting as my Downloader/File Manager.

I have an old P4 that is currently doing all of my downloading/storage/file-managing and it has worked great, but i think that it is probably sucking up a lot of electricity.  I was thinking of using an RPi to handle the main day-to-day stuff.  I want to setup the RPi as the downloader so it will download content and then, upon completion, push the content to the appropriate directory on the P4 system.  Then, when the file is requested by me to download or stream or whatever, it will request the file from the P4 and then push it to the destination.  I would love to have the P4 system standby when it isn't receiving any files so it will minimize it's power-usage.

Do you think this is a possibility? I'm sure it is but I just wanted to iron out the details before I got too far into this.

kme
Posts: 448
Joined: Sun Sep 04, 2011 9:37 am

Re: RP-B used as Downloader with separate box as storage

Thu Dec 29, 2011 10:00 pm

I'd suppose the R-Pi completely can substitute the P4 box. It certainly easily saturates a 100 Mbit/s line and is idle for the rest.

Lastb0isct
Posts: 23
Joined: Thu Dec 29, 2011 9:42 pm

Re: RP-B used as Downloader with separate box as storage

Thu Dec 29, 2011 10:06 pm

kme said:


I'd suppose the R-Pi completely can substitute the P4 box. It certainly easily saturates a 100 Mbit/s line and is idle for the rest.


My only question is how would I support ~4HDDs? The RPi doesn't have any sata or ide ports and i have a mixed bag of HDDs.  I haven't really seen any posts about how people are going to be connecting hard drive, especially the power that the HDDs require.

SergeantFTC
Posts: 52
Joined: Mon Aug 29, 2011 7:46 pm
Location: Delaware, USA

Re: RP-B used as Downloader with separate box as storage

Thu Dec 29, 2011 10:14 pm

I suppose that you could attach a USB hub and use USB to IDE/SATA adapters. Where does he say anything about having a ton of hard drives anyways?

Lastb0isct
Posts: 23
Joined: Thu Dec 29, 2011 9:42 pm

Re: RP-B used as Downloader with separate box as storage

Thu Dec 29, 2011 10:16 pm

SergeantFTC said:


I suppose that you could attach a USB hub and use USB to IDE/SATA adapters. Where does he say anything about having a ton of hard drives anyways?


That was my reply, haha.  I have 4 hard drives with ~ 3.5tb of space which is why I thought it'd be best to keep the P4 in the chain.  USB would probably have to be the way if that were the case...

User avatar
daVirus
Posts: 7
Joined: Thu Dec 29, 2011 10:15 pm
Location: Germany
Contact: ICQ

Re: RP-B used as Downloader with separate box as storage

Thu Dec 29, 2011 10:21 pm

or simply buy some external usb cases for your harddisks and plug them all into a usb hub and than plug that hub into the RPi

Lastb0isct
Posts: 23
Joined: Thu Dec 29, 2011 9:42 pm

Re: RP-B used as Downloader with separate box as storage

Thu Dec 29, 2011 10:29 pm

daVirus said:


or simply buy some external usb cases for your harddisks and plug them all into a usb hub and than plug that hub into the RPi


Probably the easiest thing to do would be to transplant the RPi into the P4 case and keep all the HDDs in there.  Power everything off of a large USB hub including a couple fans to get airflow for the HDDs.  That's probably the cheapest alternative.

So hard to give up old hardware though, grew up on that P4! =(

User avatar
daVirus
Posts: 7
Joined: Thu Dec 29, 2011 10:15 pm
Location: Germany
Contact: ICQ

Re: RP-B used as Downloader with separate box as storage

Thu Dec 29, 2011 10:39 pm

Lastb0isct said:


daVirus said:


or simply buy some external usb cases for your harddisks and plug them all into a usb hub and than plug that hub into the RPi


Probably the easiest thing to do would be to transplant the RPi into the P4 case and keep all the HDDs in there.  Power everything off of a large USB hub including a couple fans to get airflow for the HDDs.  That's probably the cheapest alternative.

So hard to give up old hardware though, grew up on that P4! =(


yeah good idea, but you have to power on the psu somehow so that the drives get power and you need to change the ide/sata ports with adaptors to usb

but youll save a lot of electricity if you shut down that old P4

smithg400
Posts: 148
Joined: Sat Dec 24, 2011 3:37 pm

Re: RP-B used as Downloader with separate box as storage

Thu Dec 29, 2011 10:39 pm

The RPi may be able to saturate the 100Mb/s ethernet but surely the USB bus will be a bottle neck in this configuration?

User avatar
daVirus
Posts: 7
Joined: Thu Dec 29, 2011 10:15 pm
Location: Germany
Contact: ICQ

Re: RP-B used as Downloader with separate box as storage

Thu Dec 29, 2011 10:42 pm

thats also my convern, what happens if all the drives communicate over one usb hub -> one usb port at the same time?

Lastb0isct
Posts: 23
Joined: Thu Dec 29, 2011 9:42 pm

Re: RP-B used as Downloader with separate box as storage

Thu Dec 29, 2011 10:45 pm

GrahamSmith said:


The RPi may be able to saturate the 100Mb/s ethernet but surely the USB bus will be a bottle neck in this configuration?


That's what I was thinking because, after further reading right now, i found that the USB and Ethernet share the same bus.  I need to be able to download several streams at a time while also serving HD files to another client.  This means that the speed needs to be at least 4-5MB/s which is do-able with just one stream...but multiple streams coming down & up might be too much for the RPi.

kme
Posts: 448
Joined: Sun Sep 04, 2011 9:37 am

Re: RP-B used as Downloader with separate box as storage

Thu Dec 29, 2011 10:45 pm

GrahamSmith said:


The RPi may be able to saturate the 100Mb/s ethernet but surely the USB bus will be a bottle neck in this configuration?



How? The USB2 bus has 480 Mb/s available, the etherport takes 100 Mb/s (+ a little overhead) leaving ~ 380 Mb/s for disk transfer. This may not sound as much in raw numbers, but as data is still only arriving at 100 Mb/s (if the internet connection actually is this fast in the first place) it is plenty even considering the half duplex nature of USB2.

Lastb0isct
Posts: 23
Joined: Thu Dec 29, 2011 9:42 pm

Re: RP-B used as Downloader with separate box as storage

Thu Dec 29, 2011 10:48 pm

kme said:


GrahamSmith said:


The RPi may be able to saturate the 100Mb/s ethernet but surely the USB bus will be a bottle neck in this configuration?


How? The USB2 bus has 480 Mb/s available, the etherport takes 100 Mb/s (+ a little overhead) leaving ~ 380 Mb/s for disk transfer. This may not sound as much in raw numbers, but as data is still only arriving at 100 Mb/s (if the internet connection actually is this fast in the first place) it is plenty even considering the half duplex nature of USB2.


USB2 speeds never actually reach that "maximum" transfer rate.  I've never been able to get over 400Mb/s with USB2 and it struggles to reach over 250 most of the time.  But the problem is that for the server to work I would need it to have full-duplex capabilities to all the HDDs.  I need to be receiving and sending files at the same time.  There could be serious packet loss problems if these two components are on the same bus and I don't think it will be able to keep up with my speed requirements.

pvgb
Posts: 51
Joined: Sat Oct 15, 2011 9:53 pm

Re: RP-B used as Downloader with separate box as storage

Thu Dec 29, 2011 10:57 pm

Depending on the size of download, you could consider keeping the P4 in a standby (Wake on LAN) mode, and punt the downloaded file as soon as the P4 is awake. As soon as the transfer is complete, put the P4 back to low power mode.

It is certainly possible to get USB attached enclosures for Hard disks, so that is another way. You might want to pick an enclosure with an inbuilt fan.

There is another argument about spinning disks down after a certain time without accesses.

Lastb0isct
Posts: 23
Joined: Thu Dec 29, 2011 9:42 pm

Re: RP-B used as Downloader with separate box as storage

Thu Dec 29, 2011 11:01 pm

pvgb said:


Depending on the size of download, you could consider keeping the P4 in a standby (Wake on LAN) mode, and punt the downloaded file as soon as the P4 is awake. As soon as the transfer is complete, put the P4 back to low power mode.


This is certainly what I was looking to do.  But is there a way to initialize a WoLAN from the RPi?  I want to fully automate the process so when the download is done it will initiate a script that wakes up the P4, pushes the file to the P4 and then, after the file pushes the P4 will standby again after 2-3 minutes.  This seems to be the only solution to really limit power consumption and keep my large disk space intact...

seekerm
Posts: 11
Joined: Tue Dec 27, 2011 12:43 am

Re: RP-B used as Downloader with separate box as storage

Thu Dec 29, 2011 11:01 pm


Lastb0isct said:  There could be serious packet loss problems if these two components are on the same bus and I don't think it will be able to keep up with my speed requirements.



hmm well replacing a server is actuelly not the aim of Raspberry Pi, as far I can see .

I would  split the work in two:

* do with RBP what you intendeed too – HTPC and such

* buy a NAS inorder to take over the download-task in a less power-consuming way.

A lots of firms are using ARM based CPU's like QNAP and Synology.

kingneutron
Posts: 17
Joined: Wed Dec 28, 2011 6:42 pm

Re: RP-B used as Downloader with separate box as storage

Fri Dec 30, 2011 8:19 am

--Let's try looking at this from another perspective.  How much is your electric bill per month?  On level-pay plan, mine is between $62-68 in Missouri.

--You can pretty accurately measure how much electricity your P4 is using by attaching a Kill-A-Watt to it for ~$20:

https://www.google.com/search?q=kill+a+ ... =firefox-a

--If you buy a replacement, "modern" power supply for the P4, it can also help:

http://www.cameralabs.com/PC_H.....pply.shtml

--BTW, I wouldn't try attaching more than (1) HD to the RPI via USB port - at only 700MHz ARM, it's not going to have a lot of oomph in the 1st place; and disk contention over USB is not something you want to get into IRL.

--That said, I can help you out with some hdparm tweaks, and maxing out the power-saving settings in the BIOS may help as well without having to drop it all the way into L2 power saving/"standby" mode.  Also, turning off the P4 when not actively in-use is probably best.  You could maybe use the low-power PI to download, and then once a day (YMMV) turn on the P4 for migration and streaming...

/ just MHO

Lastb0isct said:


pvgb said:


Depending on the size of download, you could consider keeping the P4 in a standby (Wake on LAN) mode, and punt the downloaded file as soon as the P4 is awake. As soon as the transfer is complete, put the P4 back to low power mode.


This is certainly what I was looking to do.  But is there a way to initialize a WoLAN from the RPi?  I want to fully automate the process so when the download is done it will initiate a script that wakes up the P4, pushes the file to the P4 and then, after the file pushes the P4 will standby again after 2-3 minutes.  This seems to be the only solution to really limit power consumption and keep my large disk space intact...


pvgb
Posts: 51
Joined: Sat Oct 15, 2011 9:53 pm

Re: RP-B used as Downloader with separate box as storage

Mon Jan 02, 2012 8:51 pm

In theory, WoLAN is fairly simple - you just send a "magic packet" to the target.

The exact details on how well it works seems to vary across products. ( Different cards, operating systems, different S States ... )

Just been looking at the specs for the USB/Ethernet controller on the Model B - it looks like it does WoLAN.

Something else to try when the boards become available ...

tozmo
Posts: 1
Joined: Tue Jan 10, 2012 5:56 am

Re: RP-B used as Downloader with separate box as storage

Tue Jan 10, 2012 6:42 am

What about chunking multiple rpi through one switch? You still have the bottleneck of USB -> Ethernet, but now you can offset some throughput by the CPU?

loldma
Posts: 2
Joined: Tue Nov 01, 2011 3:25 pm

Re: RP-B used as Downloader with separate box as storage

Wed Jan 11, 2012 5:38 pm

What about using the GPIO to controll the power button of the P4? Config the P4 to sleep on Power button. Here is a topic about the Power switch.
http://www.raspberrypi.org/for.....oot-switch

User avatar
grumpyoldgit
Posts: 1452
Joined: Thu Jan 05, 2012 12:20 pm

Re: RP-B used as Downloader with separate box as storage

Wed Jan 11, 2012 5:55 pm

Lastb0isct said:


Hi all,

I am really excited for the RPi to come out and just wanted to throw an idea out there.  I've been keeping tabs on the forums and have noticed a lot of people planning on using their RPi's for HTPCs or Home Servers.  I'm definitely going to be setting up my first RPi as a HTPC for my bedroom, but wanted to expand on that and thought about how I can save more electricity with another one acting as my Downloader/File Manager.

I have an old P4 that is currently doing all of my downloading/storage/file-managing and it has worked great, but i think that it is probably sucking up a lot of electricity.  I was thinking of using an RPi to handle the main day-to-day stuff.  I want to setup the RPi as the downloader so it will download content and then, upon completion, push the content to the appropriate directory on the P4 system.  Then, when the file is requested by me to download or stream or whatever, it will request the file from the P4 and then push it to the destination.  I would love to have the P4 system standby when it isn't receiving any files so it will minimize it's power-usage.

Do you think this is a possibility? I'm sure it is but I just wanted to iron out the details before I got too far into this.



I assume you are talking about Bittorrent, or similar, and just want to keep the Pi running 24/7. If you just attach one of the drives and then copy files over when they have completed downloading. I have a NAS with a 1Tb drive which has a bittorrent client embedded in it and the box just sits humming away on the edge of my desk 24/7. My PC is on during the day but can now be switched off at night.

Return to “Other projects”