Re: upload files to another server

2006-08-24 Thread zenx

Thank you both!!! That's very helpful! I will read the howto carefully
;)


--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-users
-~--~~~~--~~--~--~---



Re: upload files to another server

2006-08-24 Thread Jacob Kaplan-Moss

On Aug 24, 2006, at 9:31 AM, Jay Parlar wrote:
> And there won't be any docs on setting up NFS with Django. Your Django
> won't know you're running NFS, and NFS won't know you're running
> Django. They're unrelated to each other.

Took the words right out of my mouth :)

> There should be a ton of good docs on setting up NFS.

I found the NFS-HOWTO very helpful: http://nfs.sourceforge.net/nfs- 
howto/

Jacob

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-users
-~--~~~~--~~--~--~---



Re: upload files to another server

2006-08-24 Thread Jay Parlar

On 8/24/06, zenx <[EMAIL PROTECTED]> wrote:
>
> Thank you Jacob!
>
> If anybody can point me to any link about setting up NFS with Django I
> would be grateful.
>

Yeah, Jacob's right, NFS is the way to go. Only use my scp idea if for
some reason you can't get NFS going.

And there won't be any docs on setting up NFS with Django. Your Django
won't know you're running NFS, and NFS won't know you're running
Django. They're unrelated to each other.

There should be a ton of good docs on setting up NFS.

Jay P.

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-users
-~--~~~~--~~--~--~---



Re: upload files to another server

2006-08-24 Thread zenx

Thank you Jacob!

If anybody can point me to any link about setting up NFS with Django I
would be grateful.

Thanks!!!


--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-users
-~--~~~~--~~--~--~---



Re: upload files to another server

2006-08-23 Thread Jacob Kaplan-Moss

On Aug 23, 2006, at 8:13 AM, zenx wrote:
> I was reading some django performance tips:
> http://www.jacobian.org/writing/2005/dec/12/django-performance-tips/
> One of them is: "Use a separate media server"
> But how could I upload files with Django FileField or ImageField to
> another webserver than the one using django?

You've got a few options.

One is to (as Gabriel suggested) use lighttpd alongside Apache on the  
same physical machine.

The faster option -- and the one we use -- is to have two physical  
machines, and just mount the media directory onto the Django server  
using NFS.  This slightly slows down writes to file fields from  
Django, but drastically speeds up reads of media.

Jacob

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-users
-~--~~~~--~~--~--~---



Re: upload files to another server

2006-08-23 Thread zenx

Thank you! I will take a look at it.


--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-users
-~--~~~~--~~--~--~---



Re: upload files to another server

2006-08-23 Thread Jay Parlar

On 8/23/06, Gabriel Puliatti <[EMAIL PROTECTED]> wrote:
>
> On 8/23/06, zenx <[EMAIL PROTECTED]> wrote:
> > But how could I upload files with Django FileField or ImageField to
> > another webserver than the one using django?
>
> I think it meant something like a separate server, not a machine.
>
> Like using apache to run Django and lightTPD to serve the media files.
>

If you do want to send to a completely different machine, you'll need
to write your own views that can copy files (using scp, or something
similar).

Jay P.

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-users
-~--~~~~--~~--~--~---



Re: upload files to another server

2006-08-23 Thread Gabriel Puliatti

On 8/23/06, zenx <[EMAIL PROTECTED]> wrote:
> But how could I upload files with Django FileField or ImageField to
> another webserver than the one using django?

I think it meant something like a separate server, not a machine.

Like using apache to run Django and lightTPD to serve the media files.


-- 
You can't get there from here.

Gabriel Puliatti
predius.org

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-users
-~--~~~~--~~--~--~---