pigeond pigeond

pigeon's blog - the pigeon concerto in D minor


Playstation 3 Network downloads + Linux
2008/06/08 21:35:35
games linux

For those who have been trolling around with your PS3 on the Playstation Network might know that all the playable demos and stuff on the PS3 networks can be downloaded on your usual computer, and then later get your PS3 to fetch and install them. That way you won’t have to use your PS3 to download for whatever reasons (time, disk space, connection, etc).

This ps3news forum post has all the goodies and explanations, how it works and what you need to do, except, it hasn’t got a Linux way of doing it. I spent some time looking into that a few months ago, and I think I should note them down here, before I forget the method myself…

The basic idea is you configure your PS3 to use a proxy, and then you tell it to download and install Folding@Home. The proxy translates the URL into a different one, i.e. you tell your proxy to rewrite the Folding@Home URL into one that points to the actual package you want to install.

To achieve that, I’ve decided to use apache, squid, and jesred. Apache and squid might be bit overkill, but that’s what I have already been using. jesred is a URL redirector in Debian that works with squid.

The download part is the same. You look for the game/demo/whatever you want and download the package (.pkg file) using the URL on the forum post. Let’s say you’ve got the file blah.pkg. Put the file somewhere accessible from your web server. For example, /var/www/ps3/ on my machine proxy1, which means I can download the file on my local network via http://proxy1/ps3/blah.pkg.

On to the squid config. In /etc/squid/squid.conf, I first define an access control:

acl myps3 src 192.168.0.123
http_access allow myps3

which allows my PS3, having an IP 192.168.0.123, to access my proxy.

I also have to add a special header_access rule:

header_access Content-Type deny myps3

which makes the PS3 happy downloading the file. Without this, the PS3 seems to refuse to even start downloading the package.

Then finally, I setup the URL rewrite:

url_rewrite_program /usr/lib/squid/jesred

which tells squid to use jesred for URL rewriting.

Now we setup jesred. Edit /etc/jesred.acl to suit your own needs. I have simply uncommented the line:

0.0.0.0/0

which allows URL rewrite from all sources.

Then we move onto /etc/jesred.rules. This is where we define our URL rewriting. First you need to know which URL your PS3 is using for Folding@Home. A list of possible URLs are shown in the 2.D of the FAQ on the forum post. My PS3 is PAL one, so to rewrite that URL to what we want:

regexi ^http://deu01.ps3.download.playstation.net/download/ps3/eu/fah/fah\.pkg 

http://proxy1/ps3/blah.pkg

(The above on one single line)

Remember every time you edit the jesred.rules file, you have to tell squid to reload (/etc/init.d/squid reload does the trick).

Finally, onto the PS3. Make sure you have set your PS3 to use your proxy. Now tell your PS3 to download and install Folding@Home.

And that’s it! I know it hasn’t got a nice GUI like the PS3.Proxyserver thing. But surely editing some text config files and running init reload scripts are that kind of things we have a passion for right?

If things don’t work, well, you can have a look at squid’s and jesred’s log. You might need to edit /etc/jesred.conf to enable its logging.

Let me know if I’ve made any mistakes, comments are also welcome.





Quote of the day…
2008/06/04 20:24:51
linux personal
<catty>  you know how with taiwanese or chinese, when your baby
         is one month old, you give out things like eggs and cakes and
         stuff like that to your relatives and friends...
<pigeon> yeah?
<catty>  we'll do similar things?
<pigeon> hmm, no, we'll give out linux live CDs...




Pikkoro – My Linux live system on a CF card
2006/06/04 20:28:26
flightgear linux

Since the last few times when I was in HK/TW, I’ve been thinking of having a Linux live system, installed on a USB stick or Compact Flash (CF) card, so I could simply plug it to any machine (say, those m$ windows box of my parent’s or my wife’s). I had been using the Ubuntu LiveCD, and it was really great. But then of course CD access is slow, and it’s read-only.

So I bought myself a 2GB CF card when I was in HK months ago. And I’ve finally finished setting Linux up on it. Host name “Pikkoro” (yes, yet another machine named after Dragon Ball characters), got Debian Etch (testing) installed, have it booting and running my own Linux system using a USB-CF card reader.

For those who are not familiar with the idea of a “live” system, it is basically an operating system (Linux in this case) installed on any media that can be used to boot on a computer. We all know the common setup of your computer booting the OS installed on your harddisk. So your harddisk is “bootable”. These days most computers can boot not only from a harddisk, but also from a CD/DVD, or a USB storage device (aka USB drive/stick). A live system would mean the OS/system can be run without installation. It won’t touch your harddisk (unless you want to).

So in my case, I have Linux installed and setup on my CF card, which can be plugged to a computer via a USB-CF card reader. The reason why i didn’t use a USB stick/drive is so I can use/read it on my iPAQ too, which has a CF slot.

Getting a Linux live system to work is pretty easy if you’re familiar with how Linux boots and how Debian works. Nevertheless I did some searches and reading on what other people have been doing, and I found this mini guide. What interested me is the localepurge package in Debian, which saved me a some disk spaces.

One of many things during the process was picking a window manager (notice how I said “window manager”, but not “desktop environment” :) I’ve been an AfterStepper (1.8) for a long long time. When I was doing FGLive I played with fluxbox a bit and I liked it. So I’ve decided to give it a go. After fiddling with it for a while, it’s official, fluxbox is now default on my Linux live CF. Its tab feature is probably one of the coolest. My only complaint so far is it not able to switch virtual desktop by mouse, and the fact that it only has concept of linear virtual desktops it seems.

Anyway, I’m now happy that I can carry around my own Linux system anywhere I go…


permlink :: trackback :: Comments Off



FGLive 0.1 LinuxTag edition
2006/05/15 05:30:14
flightgear linux software

The first, sorta official release of FGLive is here. FGLive – FlightGear Live is a bootable live system on CD (or any bootable medium) that boots into Linux, with FlightGear setup, ready to run. FlightGear is an open-source, multi-platform, cooperative flight simulator development project.

To find out more about FGLive, see here, and make sure you read the README as well.

See screenshots and videos of FlightGear here.


permlink :: trackback :: Comments Off



FlightGear Multiplay Air Traffic with Google Map
2005/09/11 21:41:58
coding flightgear linux software

After seeing lots useful and cool stuff people have been doing using the Google Map API, I was inspired to write something perhaps to plot buildings/models I have been/will be doing for FlightGear. While trying the API out a bit, an idea striked my head. What about a real time map for the FlightGear multiplay server air traffic map?

And so I started off doing it. It’s heaps of fun, not to mention finding out all those bugs with IE. M$ is very kind, they always do things that make people laugh. This always gives me a chance to revise a lot with Javascript.

I also ended up writing my own routines for map overlays displaying plane markers and info, instead of using the GMAPI’s GMarker. A bit more flexible, and it does exactly what I want.

There is time when Javascript is useful, and there is time where it’s just overkill. IMHO, Javascript is useful for writing “web app”. Same as using Flash, or Java applet. But btw this does NOT mean every website should be bloody web app!!

And there you go, the FlightGear server online map. A couple of FlightGearers have been using it as a flying map and as a simple ATC radar. If it’s the right time you’ll see us flying!

I’ve got plans to add more features, like airports/navids lookup. And of course, improving the usability and UI is always on the plate. Comments are also welcomed…

Also thanks to everyone who has helped me with testing and giving suggestions to the page. (ampere, AJ, thorben, vivian, gorilla, Surge, johnh51, MasseR, etc)

FlightGear Google Map





blog top 24 tags
api bonding debian engrish fglive fgmap flightgear google ISP laptop lca2007 lca2008 linux live map mpserver navaids network qotd quote of the day taiwan vim windows wine
Search
 
Web pigeond.net









this site is
created with vim



nearly all pages in this site are validated as
Valid HTML 4.01!

css validated by
Valid CSS!


pigeond.net copyright 2001 - 2014
designed, created, and coded by pigeon at pigeond dot net
all rights reserved