serve large files

classic Classic list List threaded Threaded
15 messages Options
Reply | Threaded
Open this post in threaded view
|

serve large files

mirans
Hi List,

I want to serve files that are up to 40 Mb (user clicks on a link  
'download file')

I have tried to use file_serve, but it takes about 4 minutes before  
the download actually starts
with file_stream it takes about 3 minutes before the download starts

how can ik make sure that the download starts immediately when a  
download link is clicked ?

thanks,
miran

#############################################################
This message is sent to you because you are subscribed to
  the mailing list <[hidden email]>.
To unsubscribe, E-mail to: <[hidden email]>
To switch to the DIGEST mode, E-mail to <[hidden email]>
To switch to the INDEX mode, E-mail to <[hidden email]>
Send administrative queries to  <[hidden email]>

Reply | Threaded
Open this post in threaded view
|

Re: serve large files

stevepiercy
Where is the file stored?  Disk or memory?

file_serve would be a bad choice for large files on disk.  The
entire file must be stored in memory before it is sent to the
client.  If the file is in memory already, then it should be OK
to use.

file_stream should be immediate because it serves the file from
disk in small chunks.  For file_stream the file should already
be written to the file system.

If file_stream is not immediate, then perhaps you have memory or
other resource issues on your server?

--steve


On 11/9/10 at 12:47 PM, [hidden email] (Miran) pronounced:

>Hi List,
>
>I want to serve files that are up to 40 Mb (user clicks on a link 'download file')
>
>I have tried to use file_serve, but it takes about 4 minutes
>before the download actually starts
>with file_stream it takes about 3 minutes before the download starts
>
>how can ik make sure that the download starts immediately when
>a download link is clicked ?
>
>thanks,
>miran
>
>#############################################################
>This message is sent to you because you are subscribed to
>the mailing list <[hidden email]>.
>To unsubscribe, E-mail to: <[hidden email]>
>To switch to the DIGEST mode, E-mail to <[hidden email]>
>To switch to the INDEX mode, E-mail to <[hidden email]>
>Send administrative queries to  <[hidden email]>
>

-- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
-- --
Steve Piercy               Web Site Builder              
Soquel, CA
<[hidden email]>                  <http://www.StevePiercy.com/>


#############################################################
This message is sent to you because you are subscribed to
  the mailing list <[hidden email]>.
To unsubscribe, E-mail to: <[hidden email]>
To switch to the DIGEST mode, E-mail to <[hidden email]>
To switch to the INDEX mode, E-mail to <[hidden email]>
Send administrative queries to  <[hidden email]>

Reply | Threaded
Open this post in threaded view
|

Re: serve large files

Johan Solve
file_stream is not compatible with gzip compression in the web server,
such as mod_gzip or mod_deflate. This is because the entire file must
be buffered to the gzip module before the download can begin.

mod_deflate can be configured to ignore certain paths, such as the url
used for the file_stream.

On Tue, Nov 9, 2010 at 9:55 PM, Steve Piercy - Web Site Builder
<[hidden email]> wrote:

> Where is the file stored?  Disk or memory?
>
> file_serve would be a bad choice for large files on disk.  The entire file
> must be stored in memory before it is sent to the client.  If the file is in
> memory already, then it should be OK to use.
>
> file_stream should be immediate because it serves the file from disk in
> small chunks.  For file_stream the file should already be written to the
> file system.
>
> If file_stream is not immediate, then perhaps you have memory or other
> resource issues on your server?
>
> --steve
>
>
> On 11/9/10 at 12:47 PM, [hidden email] (Miran) pronounced:
>
>> Hi List,
>>
>> I want to serve files that are up to 40 Mb (user clicks on a link
>> 'download file')
>>
>> I have tried to use file_serve, but it takes about 4 minutes before the
>> download actually starts
>> with file_stream it takes about 3 minutes before the download starts
>>
>> how can ik make sure that the download starts immediately when a download
>> link is clicked ?
>>
>> thanks,
>> miran
>>
>> #############################################################
>> This message is sent to you because you are subscribed to
>> the mailing list <[hidden email]>.
>> To unsubscribe, E-mail to: <[hidden email]>
>> To switch to the DIGEST mode, E-mail to <[hidden email]>
>> To switch to the INDEX mode, E-mail to <[hidden email]>
>> Send administrative queries to  <[hidden email]>
>>
>
> -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
> Steve Piercy               Web Site Builder               Soquel, CA
> <[hidden email]>                  <http://www.StevePiercy.com/>
>
>
> #############################################################
> This message is sent to you because you are subscribed to
>  the mailing list <[hidden email]>.
> To unsubscribe, E-mail to: <[hidden email]>
> To switch to the DIGEST mode, E-mail to <[hidden email]>
> To switch to the INDEX mode, E-mail to <[hidden email]>
> Send administrative queries to  <[hidden email]>
>
>



--
Mvh
Johan Sölve
____________________________________
Montania System AB
Halmstad   Stockholm   Malmö
http://www.montania.se

Johan Sölve
Mobil +46 709-51 55 70
[hidden email]

Kristinebergsvägen 17, S-302 41 Halmstad, Sweden
Telefon +46 35-136800 |  Fax +46 35-136801

#############################################################
This message is sent to you because you are subscribed to
  the mailing list <[hidden email]>.
To unsubscribe, E-mail to: <[hidden email]>
To switch to the DIGEST mode, E-mail to <[hidden email]>
To switch to the INDEX mode, E-mail to <[hidden email]>
Send administrative queries to  <[hidden email]>

Reply | Threaded
Open this post in threaded view
|

Re: serve large files

mirans
thanks for your replies
the file is already stored on the disk (in the webroot)

I will look into 'mod_deflate'

miran

Op 9 nov 2010, om 23:57 heeft Johan Solve het volgende geschreven:

> file_stream is not compatible with gzip compression in the web server,
> such as mod_gzip or mod_deflate. This is because the entire file must
> be buffered to the gzip module before the download can begin.
>
> mod_deflate can be configured to ignore certain paths, such as the url
> used for the file_stream.
>
> On Tue, Nov 9, 2010 at 9:55 PM, Steve Piercy - Web Site Builder
> <[hidden email]> wrote:
>> Where is the file stored?  Disk or memory?
>>
>> file_serve would be a bad choice for large files on disk.  The  
>> entire file
>> must be stored in memory before it is sent to the client.  If the  
>> file is in
>> memory already, then it should be OK to use.
>>
>> file_stream should be immediate because it serves the file from  
>> disk in
>> small chunks.  For file_stream the file should already be written  
>> to the
>> file system.
>>
>> If file_stream is not immediate, then perhaps you have memory or  
>> other
>> resource issues on your server?
>>
>> --steve
>>
>>
>> On 11/9/10 at 12:47 PM, [hidden email] (Miran) pronounced:
>>
>>> Hi List,
>>>
>>> I want to serve files that are up to 40 Mb (user clicks on a link
>>> 'download file')
>>>
>>> I have tried to use file_serve, but it takes about 4 minutes  
>>> before the
>>> download actually starts
>>> with file_stream it takes about 3 minutes before the download starts
>>>
>>> how can ik make sure that the download starts immediately when a  
>>> download
>>> link is clicked ?
>>>
>>> thanks,
>>> miran
>>>
>>> #############################################################
>>> This message is sent to you because you are subscribed to
>>> the mailing list <[hidden email]>.
>>> To unsubscribe, E-mail to: <[hidden email]>
>>> To switch to the DIGEST mode, E-mail to <[hidden email]
>>> >
>>> To switch to the INDEX mode, E-mail to <[hidden email]
>>> >
>>> Send administrative queries to  <[hidden email]>
>>>
>>
>> -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
>> Steve Piercy               Web Site Builder               Soquel, CA
>> <[hidden email]>                  <http://www.StevePiercy.com/>
>>
>>
>> #############################################################
>> This message is sent to you because you are subscribed to
>>  the mailing list <[hidden email]>.
>> To unsubscribe, E-mail to: <[hidden email]>
>> To switch to the DIGEST mode, E-mail to <[hidden email]
>> >
>> To switch to the INDEX mode, E-mail to <[hidden email]
>> >
>> Send administrative queries to  <[hidden email]>
>>
>>
>
>
>
> --
> Mvh
> Johan Sölve
> ____________________________________
> Montania System AB
> Halmstad   Stockholm   Malmö
> http://www.montania.se
>
> Johan Sölve
> Mobil +46 709-51 55 70
> [hidden email]
>
> Kristinebergsvägen 17, S-302 41 Halmstad, Sweden
> Telefon +46 35-136800 |  Fax +46 35-136801
>
> #############################################################
> This message is sent to you because you are subscribed to
>  the mailing list <[hidden email]>.
> To unsubscribe, E-mail to: <[hidden email]>
> To switch to the DIGEST mode, E-mail to <[hidden email]
> >
> To switch to the INDEX mode, E-mail to <[hidden email]
> >
> Send administrative queries to  <[hidden email]>
>
>
>


#############################################################
This message is sent to you because you are subscribed to
  the mailing list <[hidden email]>.
To unsubscribe, E-mail to: <[hidden email]>
To switch to the DIGEST mode, E-mail to <[hidden email]>
To switch to the INDEX mode, E-mail to <[hidden email]>
Send administrative queries to  <[hidden email]>

Reply | Threaded
Open this post in threaded view
|

Re: serve large files

Johan Solve
So it's a plain static file? In that case there's no reason to involve
Lasso and you can just link directly to the file.


On Wed, Nov 10, 2010 at 8:49 AM, Miran <[hidden email]> wrote:

> thanks for your replies
> the file is already stored on the disk (in the webroot)
>
> I will look into 'mod_deflate'
>
> miran
>
> Op 9 nov 2010, om 23:57 heeft Johan Solve het volgende geschreven:
>
>> file_stream is not compatible with gzip compression in the web server,
>> such as mod_gzip or mod_deflate. This is because the entire file must
>> be buffered to the gzip module before the download can begin.
>>
>> mod_deflate can be configured to ignore certain paths, such as the url
>> used for the file_stream.
>>
>> On Tue, Nov 9, 2010 at 9:55 PM, Steve Piercy - Web Site Builder
>> <[hidden email]> wrote:
>>>
>>> Where is the file stored?  Disk or memory?
>>>
>>> file_serve would be a bad choice for large files on disk.  The entire
>>> file
>>> must be stored in memory before it is sent to the client.  If the file is
>>> in
>>> memory already, then it should be OK to use.
>>>
>>> file_stream should be immediate because it serves the file from disk in
>>> small chunks.  For file_stream the file should already be written to the
>>> file system.
>>>
>>> If file_stream is not immediate, then perhaps you have memory or other
>>> resource issues on your server?
>>>
>>> --steve
>>>
>>>
>>> On 11/9/10 at 12:47 PM, [hidden email] (Miran) pronounced:
>>>
>>>> Hi List,
>>>>
>>>> I want to serve files that are up to 40 Mb (user clicks on a link
>>>> 'download file')
>>>>
>>>> I have tried to use file_serve, but it takes about 4 minutes before the
>>>> download actually starts
>>>> with file_stream it takes about 3 minutes before the download starts
>>>>
>>>> how can ik make sure that the download starts immediately when a
>>>> download
>>>> link is clicked ?
>>>>
>>>> thanks,
>>>> miran
>>>>
>>>> #############################################################
>>>> This message is sent to you because you are subscribed to
>>>> the mailing list <[hidden email]>.
>>>> To unsubscribe, E-mail to: <[hidden email]>
>>>> To switch to the DIGEST mode, E-mail to
>>>> <[hidden email]>
>>>> To switch to the INDEX mode, E-mail to <[hidden email]>
>>>> Send administrative queries to  <[hidden email]>
>>>>
>>>
>>> -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
>>> Steve Piercy               Web Site Builder               Soquel, CA
>>> <[hidden email]>                  <http://www.StevePiercy.com/>
>>>
>>>
>>> #############################################################
>>> This message is sent to you because you are subscribed to
>>>  the mailing list <[hidden email]>.
>>> To unsubscribe, E-mail to: <[hidden email]>
>>> To switch to the DIGEST mode, E-mail to
>>> <[hidden email]>
>>> To switch to the INDEX mode, E-mail to <[hidden email]>
>>> Send administrative queries to  <[hidden email]>
>>>
>>>
>>
>>
>>
>> --
>> Mvh
>> Johan Sölve
>> ____________________________________
>> Montania System AB
>> Halmstad   Stockholm   Malmö
>> http://www.montania.se
>>
>> Johan Sölve
>> Mobil +46 709-51 55 70
>> [hidden email]
>>
>> Kristinebergsvägen 17, S-302 41 Halmstad, Sweden
>> Telefon +46 35-136800 |  Fax +46 35-136801
>>
>> #############################################################
>> This message is sent to you because you are subscribed to
>>  the mailing list <[hidden email]>.
>> To unsubscribe, E-mail to: <[hidden email]>
>> To switch to the DIGEST mode, E-mail to <[hidden email]>
>> To switch to the INDEX mode, E-mail to <[hidden email]>
>> Send administrative queries to  <[hidden email]>
>>
>>
>>
>
>
> #############################################################
> This message is sent to you because you are subscribed to
>  the mailing list <[hidden email]>.
> To unsubscribe, E-mail to: <[hidden email]>
> To switch to the DIGEST mode, E-mail to <[hidden email]>
> To switch to the INDEX mode, E-mail to <[hidden email]>
> Send administrative queries to  <[hidden email]>
>
>



--
Mvh
Johan Sölve
____________________________________
Montania System AB
Halmstad   Stockholm   Malmö
http://www.montania.se

Johan Sölve
Mobil +46 709-51 55 70
[hidden email]

Kristinebergsvägen 17, S-302 41 Halmstad, Sweden
Telefon +46 35-136800 |  Fax +46 35-136801

#############################################################
This message is sent to you because you are subscribed to
  the mailing list <[hidden email]>.
To unsubscribe, E-mail to: <[hidden email]>
To switch to the DIGEST mode, E-mail to <[hidden email]>
To switch to the INDEX mode, E-mail to <[hidden email]>
Send administrative queries to  <[hidden email]>

Reply | Threaded
Open this post in threaded view
|

Re: serve large files

mirans
thanks, but some files are pdf files
with a direct link to the file, the browser will try to open the  
document
this takes also too long

and not all users understand that you can save the document with  
control click (or how windows users do that :-)

miran


Op 10 nov 2010, om 10:36 heeft Johan Solve het volgende geschreven:

> So it's a plain static file? In that case there's no reason to involve
> Lasso and you can just link directly to the file.
>
>
> On Wed, Nov 10, 2010 at 8:49 AM, Miran <[hidden email]> wrote:
>> thanks for your replies
>> the file is already stored on the disk (in the webroot)
>>
>> I will look into 'mod_deflate'
>>
>> miran
>>
>> Op 9 nov 2010, om 23:57 heeft Johan Solve het volgende geschreven:
>>
>>> file_stream is not compatible with gzip compression in the web  
>>> server,
>>> such as mod_gzip or mod_deflate. This is because the entire file  
>>> must
>>> be buffered to the gzip module before the download can begin.
>>>
>>> mod_deflate can be configured to ignore certain paths, such as the  
>>> url
>>> used for the file_stream.
>>>
>>> On Tue, Nov 9, 2010 at 9:55 PM, Steve Piercy - Web Site Builder
>>> <[hidden email]> wrote:
>>>>
>>>> Where is the file stored?  Disk or memory?
>>>>
>>>> file_serve would be a bad choice for large files on disk.  The  
>>>> entire
>>>> file
>>>> must be stored in memory before it is sent to the client.  If the  
>>>> file is
>>>> in
>>>> memory already, then it should be OK to use.
>>>>
>>>> file_stream should be immediate because it serves the file from  
>>>> disk in
>>>> small chunks.  For file_stream the file should already be written  
>>>> to the
>>>> file system.
>>>>
>>>> If file_stream is not immediate, then perhaps you have memory or  
>>>> other
>>>> resource issues on your server?
>>>>
>>>> --steve
>>>>
>>>>
>>>> On 11/9/10 at 12:47 PM, [hidden email] (Miran) pronounced:
>>>>
>>>>> Hi List,
>>>>>
>>>>> I want to serve files that are up to 40 Mb (user clicks on a link
>>>>> 'download file')
>>>>>
>>>>> I have tried to use file_serve, but it takes about 4 minutes  
>>>>> before the
>>>>> download actually starts
>>>>> with file_stream it takes about 3 minutes before the download  
>>>>> starts
>>>>>
>>>>> how can ik make sure that the download starts immediately when a
>>>>> download
>>>>> link is clicked ?
>>>>>
>>>>> thanks,
>>>>> miran
>>>>>
>>>>> #############################################################
>>>>> This message is sent to you because you are subscribed to
>>>>> the mailing list <[hidden email]>.
>>>>> To unsubscribe, E-mail to: <[hidden email]>
>>>>> To switch to the DIGEST mode, E-mail to
>>>>> <[hidden email]>
>>>>> To switch to the INDEX mode, E-mail to <[hidden email]
>>>>> >
>>>>> Send administrative queries to  <lasso-
>>>>> [hidden email]>
>>>>>
>>>>
>>>> -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --  
>>>> --
>>>> Steve Piercy               Web Site Builder               Soquel,  
>>>> CA
>>>> <[hidden email]>                  <http://
>>>> www.StevePiercy.com/>
>>>>
>>>>
>>>> #############################################################
>>>> This message is sent to you because you are subscribed to
>>>>  the mailing list <[hidden email]>.
>>>> To unsubscribe, E-mail to: <[hidden email]>
>>>> To switch to the DIGEST mode, E-mail to
>>>> <[hidden email]>
>>>> To switch to the INDEX mode, E-mail to <[hidden email]
>>>> >
>>>> Send administrative queries to  <[hidden email]>
>>>>
>>>>
>>>
>>>
>>>
>>> --
>>> Mvh
>>> Johan Sölve
>>> ____________________________________
>>> Montania System AB
>>> Halmstad   Stockholm   Malmö
>>> http://www.montania.se
>>>
>>> Johan Sölve
>>> Mobil +46 709-51 55 70
>>> [hidden email]
>>>
>>> Kristinebergsvägen 17, S-302 41 Halmstad, Sweden
>>> Telefon +46 35-136800 |  Fax +46 35-136801
>>>
>>> #############################################################
>>> This message is sent to you because you are subscribed to
>>>  the mailing list <[hidden email]>.
>>> To unsubscribe, E-mail to: <[hidden email]>
>>> To switch to the DIGEST mode, E-mail to <[hidden email]
>>> >
>>> To switch to the INDEX mode, E-mail to <[hidden email]
>>> >
>>> Send administrative queries to  <[hidden email]>
>>>
>>>
>>>
>>
>>
>> #############################################################
>> This message is sent to you because you are subscribed to
>>  the mailing list <[hidden email]>.
>> To unsubscribe, E-mail to: <[hidden email]>
>> To switch to the DIGEST mode, E-mail to <[hidden email]
>> >
>> To switch to the INDEX mode, E-mail to <[hidden email]
>> >
>> Send administrative queries to  <[hidden email]>
>>
>>
>
>
>
> --
> Mvh
> Johan Sölve
> ____________________________________
> Montania System AB
> Halmstad   Stockholm   Malmö
> http://www.montania.se
>
> Johan Sölve
> Mobil +46 709-51 55 70
> [hidden email]
>
> Kristinebergsvägen 17, S-302 41 Halmstad, Sweden
> Telefon +46 35-136800 |  Fax +46 35-136801
>
> #############################################################
> This message is sent to you because you are subscribed to
>  the mailing list <[hidden email]>.
> To unsubscribe, E-mail to: <[hidden email]>
> To switch to the DIGEST mode, E-mail to <[hidden email]
> >
> To switch to the INDEX mode, E-mail to <[hidden email]
> >
> Send administrative queries to  <[hidden email]>
>
>
>


#############################################################
This message is sent to you because you are subscribed to
  the mailing list <[hidden email]>.
To unsubscribe, E-mail to: <[hidden email]>
To switch to the DIGEST mode, E-mail to <[hidden email]>
To switch to the INDEX mode, E-mail to <[hidden email]>
Send administrative queries to  <[hidden email]>

Reply | Threaded
Open this post in threaded view
|

Re: serve large files

Johan Solve
I think you can set the mime type to something different than
application/pdf for a specific directory, for example
application/octet-stream.
http://httpd.apache.org/docs/2.0/mod/core.html#forcetype

This will tell the browser to download the file instead of showing it.

On Wed, Nov 10, 2010 at 10:47 AM, Miran <[hidden email]> wrote:

> thanks, but some files are pdf files
> with a direct link to the file, the browser will try to open the document
> this takes also too long
>
> and not all users understand that you can save the document with control
> click (or how windows users do that :-)
>
> miran
>
>
> Op 10 nov 2010, om 10:36 heeft Johan Solve het volgende geschreven:
>
>> So it's a plain static file? In that case there's no reason to involve
>> Lasso and you can just link directly to the file.
>>
>>
>> On Wed, Nov 10, 2010 at 8:49 AM, Miran <[hidden email]> wrote:
>>>
>>> thanks for your replies
>>> the file is already stored on the disk (in the webroot)
>>>
>>> I will look into 'mod_deflate'
>>>
>>> miran
>>>
>>> Op 9 nov 2010, om 23:57 heeft Johan Solve het volgende geschreven:
>>>
>>>> file_stream is not compatible with gzip compression in the web server,
>>>> such as mod_gzip or mod_deflate. This is because the entire file must
>>>> be buffered to the gzip module before the download can begin.
>>>>
>>>> mod_deflate can be configured to ignore certain paths, such as the url
>>>> used for the file_stream.
>>>>
>>>> On Tue, Nov 9, 2010 at 9:55 PM, Steve Piercy - Web Site Builder
>>>> <[hidden email]> wrote:
>>>>>
>>>>> Where is the file stored?  Disk or memory?
>>>>>
>>>>> file_serve would be a bad choice for large files on disk.  The entire
>>>>> file
>>>>> must be stored in memory before it is sent to the client.  If the file
>>>>> is
>>>>> in
>>>>> memory already, then it should be OK to use.
>>>>>
>>>>> file_stream should be immediate because it serves the file from disk in
>>>>> small chunks.  For file_stream the file should already be written to
>>>>> the
>>>>> file system.
>>>>>
>>>>> If file_stream is not immediate, then perhaps you have memory or other
>>>>> resource issues on your server?
>>>>>
>>>>> --steve
>>>>>
>>>>>
>>>>> On 11/9/10 at 12:47 PM, [hidden email] (Miran) pronounced:
>>>>>
>>>>>> Hi List,
>>>>>>
>>>>>> I want to serve files that are up to 40 Mb (user clicks on a link
>>>>>> 'download file')
>>>>>>
>>>>>> I have tried to use file_serve, but it takes about 4 minutes before
>>>>>> the
>>>>>> download actually starts
>>>>>> with file_stream it takes about 3 minutes before the download starts
>>>>>>
>>>>>> how can ik make sure that the download starts immediately when a
>>>>>> download
>>>>>> link is clicked ?
>>>>>>
>>>>>> thanks,
>>>>>> miran
>>>>>>
>>>>>> #############################################################
>>>>>> This message is sent to you because you are subscribed to
>>>>>> the mailing list <[hidden email]>.
>>>>>> To unsubscribe, E-mail to: <[hidden email]>
>>>>>> To switch to the DIGEST mode, E-mail to
>>>>>> <[hidden email]>
>>>>>> To switch to the INDEX mode, E-mail to
>>>>>> <[hidden email]>
>>>>>> Send administrative queries to  <[hidden email]>
>>>>>>
>>>>>
>>>>> -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
>>>>> Steve Piercy               Web Site Builder               Soquel, CA
>>>>> <[hidden email]>                  <http://www.StevePiercy.com/>
>>>>>
>>>>>
>>>>> #############################################################
>>>>> This message is sent to you because you are subscribed to
>>>>>  the mailing list <[hidden email]>.
>>>>> To unsubscribe, E-mail to: <[hidden email]>
>>>>> To switch to the DIGEST mode, E-mail to
>>>>> <[hidden email]>
>>>>> To switch to the INDEX mode, E-mail to
>>>>> <[hidden email]>
>>>>> Send administrative queries to  <[hidden email]>
>>>>>
>>>>>
>>>>
>>>>
>>>>
>>>> --
>>>> Mvh
>>>> Johan Sölve
>>>> ____________________________________
>>>> Montania System AB
>>>> Halmstad   Stockholm   Malmö
>>>> http://www.montania.se
>>>>
>>>> Johan Sölve
>>>> Mobil +46 709-51 55 70
>>>> [hidden email]
>>>>
>>>> Kristinebergsvägen 17, S-302 41 Halmstad, Sweden
>>>> Telefon +46 35-136800 |  Fax +46 35-136801
>>>>
>>>> #############################################################
>>>> This message is sent to you because you are subscribed to
>>>>  the mailing list <[hidden email]>.
>>>> To unsubscribe, E-mail to: <[hidden email]>
>>>> To switch to the DIGEST mode, E-mail to
>>>> <[hidden email]>
>>>> To switch to the INDEX mode, E-mail to <[hidden email]>
>>>> Send administrative queries to  <[hidden email]>
>>>>
>>>>
>>>>
>>>
>>>
>>> #############################################################
>>> This message is sent to you because you are subscribed to
>>>  the mailing list <[hidden email]>.
>>> To unsubscribe, E-mail to: <[hidden email]>
>>> To switch to the DIGEST mode, E-mail to
>>> <[hidden email]>
>>> To switch to the INDEX mode, E-mail to <[hidden email]>
>>> Send administrative queries to  <[hidden email]>
>>>
>>>
>>
>>
>>
>> --
>> Mvh
>> Johan Sölve
>> ____________________________________
>> Montania System AB
>> Halmstad   Stockholm   Malmö
>> http://www.montania.se
>>
>> Johan Sölve
>> Mobil +46 709-51 55 70
>> [hidden email]
>>
>> Kristinebergsvägen 17, S-302 41 Halmstad, Sweden
>> Telefon +46 35-136800 |  Fax +46 35-136801
>>
>> #############################################################
>> This message is sent to you because you are subscribed to
>>  the mailing list <[hidden email]>.
>> To unsubscribe, E-mail to: <[hidden email]>
>> To switch to the DIGEST mode, E-mail to <[hidden email]>
>> To switch to the INDEX mode, E-mail to <[hidden email]>
>> Send administrative queries to  <[hidden email]>
>>
>>
>>
>
>
> #############################################################
> This message is sent to you because you are subscribed to
>  the mailing list <[hidden email]>.
> To unsubscribe, E-mail to: <[hidden email]>
> To switch to the DIGEST mode, E-mail to <[hidden email]>
> To switch to the INDEX mode, E-mail to <[hidden email]>
> Send administrative queries to  <[hidden email]>
>
>



--
Mvh
Johan Sölve
____________________________________
Montania System AB
Halmstad   Stockholm   Malmö
http://www.montania.se

Johan Sölve
Mobil +46 709-51 55 70
[hidden email]

Kristinebergsvägen 17, S-302 41 Halmstad, Sweden
Telefon +46 35-136800 |  Fax +46 35-136801

#############################################################
This message is sent to you because you are subscribed to
  the mailing list <[hidden email]>.
To unsubscribe, E-mail to: <[hidden email]>
To switch to the DIGEST mode, E-mail to <[hidden email]>
To switch to the INDEX mode, E-mail to <[hidden email]>
Send administrative queries to  <[hidden email]>

Reply | Threaded
Open this post in threaded view
|

Re: serve large files

mirans
in the same directory where the large files are stored are also low  
res files, which can be viewed in the browser

so telling apache that all files in that directory should be  
downloaded instead of opened is also a nogo
and the directories are created dynamically, every client that is  
using the system gets his own directory



Op 10 nov 2010, om 10:59 heeft Johan Solve het volgende geschreven:

> I think you can set the mime type to something different than
> application/pdf for a specific directory, for example
> application/octet-stream.
> http://httpd.apache.org/docs/2.0/mod/core.html#forcetype
>
> This will tell the browser to download the file instead of showing it.
>
> On Wed, Nov 10, 2010 at 10:47 AM, Miran <[hidden email]> wrote:
>> thanks, but some files are pdf files
>> with a direct link to the file, the browser will try to open the  
>> document
>> this takes also too long
>>
>> and not all users understand that you can save the document with  
>> control
>> click (or how windows users do that :-)
>>
>> miran
>>
>>
>> Op 10 nov 2010, om 10:36 heeft Johan Solve het volgende geschreven:
>>
>>> So it's a plain static file? In that case there's no reason to  
>>> involve
>>> Lasso and you can just link directly to the file.
>>>
>>>
>>> On Wed, Nov 10, 2010 at 8:49 AM, Miran <[hidden email]> wrote:
>>>>
>>>> thanks for your replies
>>>> the file is already stored on the disk (in the webroot)
>>>>
>>>> I will look into 'mod_deflate'
>>>>
>>>> miran
>>>>
>>>> Op 9 nov 2010, om 23:57 heeft Johan Solve het volgende geschreven:
>>>>
>>>>> file_stream is not compatible with gzip compression in the web  
>>>>> server,
>>>>> such as mod_gzip or mod_deflate. This is because the entire file  
>>>>> must
>>>>> be buffered to the gzip module before the download can begin.
>>>>>
>>>>> mod_deflate can be configured to ignore certain paths, such as  
>>>>> the url
>>>>> used for the file_stream.
>>>>>
>>>>> On Tue, Nov 9, 2010 at 9:55 PM, Steve Piercy - Web Site Builder
>>>>> <[hidden email]> wrote:
>>>>>>
>>>>>> Where is the file stored?  Disk or memory?
>>>>>>
>>>>>> file_serve would be a bad choice for large files on disk.  The  
>>>>>> entire
>>>>>> file
>>>>>> must be stored in memory before it is sent to the client.  If  
>>>>>> the file
>>>>>> is
>>>>>> in
>>>>>> memory already, then it should be OK to use.
>>>>>>
>>>>>> file_stream should be immediate because it serves the file from  
>>>>>> disk in
>>>>>> small chunks.  For file_stream the file should already be  
>>>>>> written to
>>>>>> the
>>>>>> file system.
>>>>>>
>>>>>> If file_stream is not immediate, then perhaps you have memory  
>>>>>> or other
>>>>>> resource issues on your server?
>>>>>>
>>>>>> --steve
>>>>>>
>>>>>>
>>>>>> On 11/9/10 at 12:47 PM, [hidden email] (Miran) pronounced:
>>>>>>
>>>>>>> Hi List,
>>>>>>>
>>>>>>> I want to serve files that are up to 40 Mb (user clicks on a  
>>>>>>> link
>>>>>>> 'download file')
>>>>>>>
>>>>>>> I have tried to use file_serve, but it takes about 4 minutes  
>>>>>>> before
>>>>>>> the
>>>>>>> download actually starts
>>>>>>> with file_stream it takes about 3 minutes before the download  
>>>>>>> starts
>>>>>>>
>>>>>>> how can ik make sure that the download starts immediately when a
>>>>>>> download
>>>>>>> link is clicked ?
>>>>>>>
>>>>>>> thanks,
>>>>>>> miran
>>>>>>>
>>>>>>> #############################################################
>>>>>>> This message is sent to you because you are subscribed to
>>>>>>> the mailing list <[hidden email]>.
>>>>>>> To unsubscribe, E-mail to: <[hidden email]>
>>>>>>> To switch to the DIGEST mode, E-mail to
>>>>>>> <[hidden email]>
>>>>>>> To switch to the INDEX mode, E-mail to
>>>>>>> <[hidden email]>
>>>>>>> Send administrative queries to  <[hidden email]
>>>>>>> >
>>>>>>>
>>>>>>
>>>>>> -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --  
>>>>>> -- --
>>>>>> Steve Piercy               Web Site Builder                
>>>>>> Soquel, CA
>>>>>> <[hidden email]>                  <http://www.StevePiercy.com/ 
>>>>>> >
>>>>>>
>>>>>>
>>>>>> #############################################################
>>>>>> This message is sent to you because you are subscribed to
>>>>>>  the mailing list <[hidden email]>.
>>>>>> To unsubscribe, E-mail to: <[hidden email]>
>>>>>> To switch to the DIGEST mode, E-mail to
>>>>>> <[hidden email]>
>>>>>> To switch to the INDEX mode, E-mail to
>>>>>> <[hidden email]>
>>>>>> Send administrative queries to  <[hidden email]
>>>>>> >
>>>>>>
>>>>>>
>>>>>
>>>>>
>>>>>
>>>>> --
>>>>> Mvh
>>>>> Johan Sölve
>>>>> ____________________________________
>>>>> Montania System AB
>>>>> Halmstad   Stockholm   Malmö
>>>>> http://www.montania.se
>>>>>
>>>>> Johan Sölve
>>>>> Mobil +46 709-51 55 70
>>>>> [hidden email]
>>>>>
>>>>> Kristinebergsvägen 17, S-302 41 Halmstad, Sweden
>>>>> Telefon +46 35-136800 |  Fax +46 35-136801
>>>>>
>>>>> #############################################################
>>>>> This message is sent to you because you are subscribed to
>>>>>  the mailing list <[hidden email]>.
>>>>> To unsubscribe, E-mail to: <[hidden email]>
>>>>> To switch to the DIGEST mode, E-mail to
>>>>> <[hidden email]>
>>>>> To switch to the INDEX mode, E-mail to <[hidden email]
>>>>> >
>>>>> Send administrative queries to  <lasso-
>>>>> [hidden email]>
>>>>>
>>>>>
>>>>>
>>>>
>>>>
>>>> #############################################################
>>>> This message is sent to you because you are subscribed to
>>>>  the mailing list <[hidden email]>.
>>>> To unsubscribe, E-mail to: <[hidden email]>
>>>> To switch to the DIGEST mode, E-mail to
>>>> <[hidden email]>
>>>> To switch to the INDEX mode, E-mail to <[hidden email]
>>>> >
>>>> Send administrative queries to  <[hidden email]>
>>>>
>>>>
>>>
>>>
>>>
>>> --
>>> Mvh
>>> Johan Sölve
>>> ____________________________________
>>> Montania System AB
>>> Halmstad   Stockholm   Malmö
>>> http://www.montania.se
>>>
>>> Johan Sölve
>>> Mobil +46 709-51 55 70
>>> [hidden email]
>>>
>>> Kristinebergsvägen 17, S-302 41 Halmstad, Sweden
>>> Telefon +46 35-136800 |  Fax +46 35-136801
>>>
>>> #############################################################
>>> This message is sent to you because you are subscribed to
>>>  the mailing list <[hidden email]>.
>>> To unsubscribe, E-mail to: <[hidden email]>
>>> To switch to the DIGEST mode, E-mail to <[hidden email]
>>> >
>>> To switch to the INDEX mode, E-mail to <[hidden email]
>>> >
>>> Send administrative queries to  <[hidden email]>
>>>
>>>
>>>
>>
>>
>> #############################################################
>> This message is sent to you because you are subscribed to
>>  the mailing list <[hidden email]>.
>> To unsubscribe, E-mail to: <[hidden email]>
>> To switch to the DIGEST mode, E-mail to <[hidden email]
>> >
>> To switch to the INDEX mode, E-mail to <[hidden email]
>> >
>> Send administrative queries to  <[hidden email]>
>>
>>
>
>
>
> --
> Mvh
> Johan Sölve
> ____________________________________
> Montania System AB
> Halmstad   Stockholm   Malmö
> http://www.montania.se
>
> Johan Sölve
> Mobil +46 709-51 55 70
> [hidden email]
>
> Kristinebergsvägen 17, S-302 41 Halmstad, Sweden
> Telefon +46 35-136800 |  Fax +46 35-136801
>
> #############################################################
> This message is sent to you because you are subscribed to
>  the mailing list <[hidden email]>.
> To unsubscribe, E-mail to: <[hidden email]>
> To switch to the DIGEST mode, E-mail to <[hidden email]
> >
> To switch to the INDEX mode, E-mail to <[hidden email]
> >
> Send administrative queries to  <[hidden email]>
>
>
>


#############################################################
This message is sent to you because you are subscribed to
  the mailing list <[hidden email]>.
To unsubscribe, E-mail to: <[hidden email]>
To switch to the DIGEST mode, E-mail to <[hidden email]>
To switch to the INDEX mode, E-mail to <[hidden email]>
Send administrative queries to  <[hidden email]>

Reply | Threaded
Open this post in threaded view
|

Re: serve large files

stevepiercy
Then use the <filesmatch> container in Apache:
http://httpd.apache.org/docs/2.0/mod/core.html#filesmatch

<FilesMatch "\.pdf$">
     ForceType application/octet-stream
</FilesMatch>

--steve


On 11/10/10 at 11:07 AM, [hidden email] (Miran) pronounced:

>in the same directory where the large files are stored are also
>low res files, which can be viewed in the browser
>
>so telling apache that all files in that directory should be
>downloaded instead of opened is also a nogo
>and the directories are created dynamically, every client that
>is using the system gets his own directory
>
>
>
>Op 10 nov 2010, om 10:59 heeft Johan Solve het volgende geschreven:
>
>>I think you can set the mime type to something different than
>>application/pdf for a specific directory, for example
>>application/octet-stream.
>>http://httpd.apache.org/docs/2.0/mod/core.html#forcetype
>>
>>This will tell the browser to download the file instead of showing it.
>>
>>On Wed, Nov 10, 2010 at 10:47 AM, Miran <[hidden email]> wrote:
>>>thanks, but some files are pdf files
>>>with a direct link to the file, the browser will try to open
>>>the document
>>>this takes also too long
>>>
>>>and not all users understand that you can save the document
>>>with control
>>>click (or how windows users do that :-)
>>>
>>>miran
>>>
>>>
>>>Op 10 nov 2010, om 10:36 heeft Johan Solve het volgende geschreven:
>>>
>>>>So it's a plain static file? In that case there's no reason
>>>>to involve
>>>>Lasso and you can just link directly to the file.
>>>>
>>>>
>>>>On Wed, Nov 10, 2010 at 8:49 AM, Miran <[hidden email]> wrote:
>>>>>
>>>>>thanks for your replies
>>>>>the file is already stored on the disk (in the webroot)
>>>>>
>>>>>I will look into 'mod_deflate'
>>>>>
>>>>>miran
>>>>>
>>>>>Op 9 nov 2010, om 23:57 heeft Johan Solve het volgende geschreven:
>>>>>
>>>>>>file_stream is not compatible with gzip compression in the
>>>>>>web server,
>>>>>>such as mod_gzip or mod_deflate. This is because the
>>>>>>entire file must
>>>>>>be buffered to the gzip module before the download can begin.
>>>>>>
>>>>>>mod_deflate can be configured to ignore certain paths,
>>>>>>such as the url
>>>>>>used for the file_stream.
>>>>>>
>>>>>>On Tue, Nov 9, 2010 at 9:55 PM, Steve Piercy - Web Site Builder
>>>>>><[hidden email]> wrote:
>>>>>>>
>>>>>>>Where is the file stored?  Disk or memory?
>>>>>>>
>>>>>>>file_serve would be a bad choice for large files on
>>>>>>>disk.  The entire
>>>>>>>file
>>>>>>>must be stored in memory before it is sent to the
>>>>>>>client.  If the file
>>>>>>>is
>>>>>>>in
>>>>>>>memory already, then it should be OK to use.
>>>>>>>
>>>>>>>file_stream should be immediate because it serves the
>>>>>>>file from disk in
>>>>>>>small chunks.  For file_stream the file should already be
>>>>>>>written to
>>>>>>>the
>>>>>>>file system.
>>>>>>>
>>>>>>>If file_stream is not immediate, then perhaps you have
>>>>>>>memory or other
>>>>>>>resource issues on your server?
>>>>>>>
>>>>>>>--steve
>>>>>>>
>>>>>>>
>>>>>>>On 11/9/10 at 12:47 PM, [hidden email] (Miran) pronounced:
>>>>>>>
>>>>>>>>Hi List,
>>>>>>>>
>>>>>>>>I want to serve files that are up to 40 Mb (user clicks
>>>>>>>>on a link
>>>>>>>>'download file')
>>>>>>>>
>>>>>>>>I have tried to use file_serve, but it takes about 4
>>>>>>>>minutes before
>>>>>>>>the
>>>>>>>>download actually starts
>>>>>>>>with file_stream it takes about 3 minutes before the
>>>>>>>>download starts
>>>>>>>>
>>>>>>>>how can ik make sure that the download starts immediately when a
>>>>>>>>download
>>>>>>>>link is clicked ?
>>>>>>>>
>>>>>>>>thanks,
>>>>>>>>miran
>>>>>>>>
>>>>>>>>#############################################################
>>>>>>>>This message is sent to you because you are subscribed to
>>>>>>>>the mailing list <[hidden email]>.
>>>>>>>>To unsubscribe, E-mail to: <[hidden email]>
>>>>>>>>To switch to the DIGEST mode, E-mail to
>>>>>>>><[hidden email]>
>>>>>>>>To switch to the INDEX mode, E-mail to
>>>>>>>><[hidden email]>
>>>>>>>>Send administrative queries to  <[hidden email]>
>>>>>>>>
>>>>>>>
>>>>>>>-- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
>>>>>>>-- -- -- --
>>>>>>>Steve Piercy               Web Site Builder              
>>>>>>>Soquel, CA
>>>>>>><[hidden email]>                  <http://www.StevePiercy.com/>
>>>>>>>
>>>>>>>
>>>>>>>#############################################################
>>>>>>>This message is sent to you because you are subscribed to
>>>>>>> the mailing list <[hidden email]>.
>>>>>>>To unsubscribe, E-mail to: <[hidden email]>
>>>>>>>To switch to the DIGEST mode, E-mail to
>>>>>>><[hidden email]>
>>>>>>>To switch to the INDEX mode, E-mail to
>>>>>>><[hidden email]>
>>>>>>>Send administrative queries to  <[hidden email]>
>>>>>>>
>>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>>--
>>>>>>Mvh
>>>>>>Johan Sölve
>>>>>>____________________________________
>>>>>>Montania System AB
>>>>>>Halmstad   Stockholm   Malmö
>>>>>>http://www.montania.se
>>>>>>
>>>>>>Johan Sölve
>>>>>>Mobil +46 709-51 55 70
>>>>>>[hidden email]
>>>>>>
>>>>>>Kristinebergsvägen 17, S-302 41 Halmstad, Sweden
>>>>>>Telefon +46 35-136800 |  Fax +46 35-136801
>>>>>>
>>>>>>#############################################################
>>>>>>This message is sent to you because you are subscribed to
>>>>>> the mailing list <[hidden email]>.
>>>>>>To unsubscribe, E-mail to: <[hidden email]>
>>>>>>To switch to the DIGEST mode, E-mail to
>>>>>><[hidden email]>
>>>>>>To switch to the INDEX mode, E-mail to <[hidden email]>
>>>>>>Send administrative queries to  <[hidden email]>
>>>>>>
>>>>>>
>>>>>>
>>>>>
>>>>>
>>>>>#############################################################
>>>>>This message is sent to you because you are subscribed to
>>>>> the mailing list <[hidden email]>.
>>>>>To unsubscribe, E-mail to: <[hidden email]>
>>>>>To switch to the DIGEST mode, E-mail to
>>>>><[hidden email]>
>>>>>To switch to the INDEX mode, E-mail to <[hidden email]>
>>>>>Send administrative queries to  <[hidden email]>
>>>>>
>>>>>
>>>>
>>>>
>>>>
>>>>--
>>>>Mvh
>>>>Johan Sölve
>>>>____________________________________
>>>>Montania System AB
>>>>Halmstad   Stockholm   Malmö
>>>>http://www.montania.se
>>>>
>>>>Johan Sölve
>>>>Mobil +46 709-51 55 70
>>>>[hidden email]
>>>>
>>>>Kristinebergsvägen 17, S-302 41 Halmstad, Sweden
>>>>Telefon +46 35-136800 |  Fax +46 35-136801
>>>>
>>>>#############################################################
>>>>This message is sent to you because you are subscribed to
>>>> the mailing list <[hidden email]>.
>>>>To unsubscribe, E-mail to: <[hidden email]>
>>>>To switch to the DIGEST mode, E-mail to <[hidden email]>
>>>>To switch to the INDEX mode, E-mail to <[hidden email]>
>>>>Send administrative queries to  <[hidden email]>
>>>>
>>>>
>>>>
>>>
>>>
>>>#############################################################
>>>This message is sent to you because you are subscribed to
>>> the mailing list <[hidden email]>.
>>>To unsubscribe, E-mail to: <[hidden email]>
>>>To switch to the DIGEST mode, E-mail to <[hidden email]>
>>>To switch to the INDEX mode, E-mail to <[hidden email]>
>>>Send administrative queries to  <[hidden email]>
>>>
>>>
>>
>>
>>
>>--
>>Mvh
>>Johan Sölve
>>____________________________________
>>Montania System AB
>>Halmstad   Stockholm   Malmö
>>http://www.montania.se
>>
>>Johan Sölve
>>Mobil +46 709-51 55 70
>>[hidden email]
>>
>>Kristinebergsvägen 17, S-302 41 Halmstad, Sweden
>>Telefon +46 35-136800 |  Fax +46 35-136801
>>
>>#############################################################
>>This message is sent to you because you are subscribed to
>>the mailing list <[hidden email]>.
>>To unsubscribe, E-mail to: <[hidden email]>
>>To switch to the DIGEST mode, E-mail to <[hidden email]>
>>To switch to the INDEX mode, E-mail to <[hidden email]>
>>Send administrative queries to  <[hidden email]>
>>
>>
>>
>
>
>#############################################################
>This message is sent to you because you are subscribed to
>the mailing list <[hidden email]>.
>To unsubscribe, E-mail to: <[hidden email]>
>To switch to the DIGEST mode, E-mail to <[hidden email]>
>To switch to the INDEX mode, E-mail to <[hidden email]>
>Send administrative queries to  <[hidden email]>
>

-- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
-- --
Steve Piercy               Web Site Builder              
Soquel, CA
<[hidden email]>                  <http://www.StevePiercy.com/>


#############################################################
This message is sent to you because you are subscribed to
  the mailing list <[hidden email]>.
To unsubscribe, E-mail to: <[hidden email]>
To switch to the DIGEST mode, E-mail to <[hidden email]>
To switch to the INDEX mode, E-mail to <[hidden email]>
Send administrative queries to  <[hidden email]>

Reply | Threaded
Open this post in threaded view
|

Re: serve large files

Jonathan Vanherpe (T & T NV)
In reply to this post by mirans
If you have a specific naming scheme for either the low-res images or
the hi-res images, you could probably do what Johan suggests with some
regex-fu.

Jonathan

Miran wrote:

> in the same directory where the large files are stored are also low
> res files, which can be viewed in the browser
>
> so telling apache that all files in that directory should be
> downloaded instead of opened is also a nogo
> and the directories are created dynamically, every client that is
> using the system gets his own directory
>
>
>
> Op 10 nov 2010, om 10:59 heeft Johan Solve het volgende geschreven:
>
>> I think you can set the mime type to something different than
>> application/pdf for a specific directory, for example
>> application/octet-stream.
>> http://httpd.apache.org/docs/2.0/mod/core.html#forcetype
>>
>> This will tell the browser to download the file instead of showing it.
>>
>> On Wed, Nov 10, 2010 at 10:47 AM, Miran <[hidden email]> wrote:
>>> thanks, but some files are pdf files
>>> with a direct link to the file, the browser will try to open the
>>> document
>>> this takes also too long
>>>
>>> and not all users understand that you can save the document with
>>> control
>>> click (or how windows users do that :-)
>>>
>>> miran
>>>
>>>
>>> Op 10 nov 2010, om 10:36 heeft Johan Solve het volgende geschreven:
>>>
>>>
>>>
>>> #############################################################
>>> This message is sent to you because you are subscribed to
>>>  the mailing list <[hidden email]>.
>>> To unsubscribe, E-mail to: <[hidden email]>
>>> To switch to the DIGEST mode, E-mail to
>>> <[hidden email]>
>>> To switch to the INDEX mode, E-mail to
>>> <[hidden email]>
>>> Send administrative queries to <[hidden email]>
>>>
>>>
>>
>>
>>
>> --
>> Mvh
>> Johan Sölve
>> ____________________________________
>> Montania System AB
>> Halmstad   Stockholm   Malmö
>> http://www.montania.se
>>
>> Johan Sölve
>> Mobil +46 709-51 55 70
>> [hidden email]
>>
>> Kristinebergsvägen 17, S-302 41 Halmstad, Sweden
>> Telefon +46 35-136800 |  Fax +46 35-136801
>>
>> #############################################################
>> This message is sent to you because you are subscribed to
>>  the mailing list <[hidden email]>.
>> To unsubscribe, E-mail to: <[hidden email]>
>> To switch to the DIGEST mode, E-mail to
>> <[hidden email]>
>> To switch to the INDEX mode, E-mail to <[hidden email]>
>> Send administrative queries to <[hidden email]>
>>
>>
>>
>
>
> #############################################################
> This message is sent to you because you are subscribed to
>  the mailing list <[hidden email]>.
> To unsubscribe, E-mail to: <[hidden email]>
> To switch to the DIGEST mode, E-mail to
> <[hidden email]>
> To switch to the INDEX mode, E-mail to <[hidden email]>
> Send administrative queries to <[hidden email]>
>
>

--
www.tnt.be <http://www.tnt.be/?source=emailsig> *Jonathan Vanherpe*
[hidden email] <mailto:[hidden email]> - www.tnt.be
<http://www.tnt.be/?source=emailsig> - tel.: +32 (0)9 3860441


#############################################################
This message is sent to you because you are subscribed to
  the mailing list <[hidden email]>.
To unsubscribe, E-mail to: <[hidden email]>
To switch to the DIGEST mode, E-mail to <[hidden email]>
To switch to the INDEX mode, E-mail to <[hidden email]>
Send administrative queries to  <[hidden email]>

Reply | Threaded
Open this post in threaded view
|

Re: serve large files

Johan Solve
In reply to this post by mirans
And there's no way to put the larger files in a subdir (or copy them),
or name them in a unique manner so you can change the mime type using
the <files> directive?
http://httpd.apache.org/docs/2.0/mod/core.html#files

Maybe you could even add some mod_rewrite magic to be able to
differentiate the larger files for direct download simply with a query
string on the link, for example
largefile.pdf?download

Maybe something like (completely untested)
RewriteCond %{QUERY_STRING} download
RewriteRule .* - [PT,T=application/octet-stream]

http://httpd.apache.org/docs/2.2/mod/mod_rewrite.html


On Wed, Nov 10, 2010 at 11:07 AM, Miran <[hidden email]> wrote:

> in the same directory where the large files are stored are also low res
> files, which can be viewed in the browser
>
> so telling apache that all files in that directory should be downloaded
> instead of opened is also a nogo
> and the directories are created dynamically, every client that is using the
> system gets his own directory
>
>
>
> Op 10 nov 2010, om 10:59 heeft Johan Solve het volgende geschreven:
>
>> I think you can set the mime type to something different than
>> application/pdf for a specific directory, for example
>> application/octet-stream.
>> http://httpd.apache.org/docs/2.0/mod/core.html#forcetype
>>
>> This will tell the browser to download the file instead of showing it.
>>
>> On Wed, Nov 10, 2010 at 10:47 AM, Miran <[hidden email]> wrote:
>>>
>>> thanks, but some files are pdf files
>>> with a direct link to the file, the browser will try to open the document
>>> this takes also too long
>>>
>>> and not all users understand that you can save the document with control
>>> click (or how windows users do that :-)
>>>
>>> miran
>>>
>>>
>>> Op 10 nov 2010, om 10:36 heeft Johan Solve het volgende geschreven:
>>>
>>>> So it's a plain static file? In that case there's no reason to involve
>>>> Lasso and you can just link directly to the file.
>>>>
>>>>
>>>> On Wed, Nov 10, 2010 at 8:49 AM, Miran <[hidden email]> wrote:
>>>>>
>>>>> thanks for your replies
>>>>> the file is already stored on the disk (in the webroot)
>>>>>
>>>>> I will look into 'mod_deflate'
>>>>>
>>>>> miran
>>>>>
>>>>> Op 9 nov 2010, om 23:57 heeft Johan Solve het volgende geschreven:
>>>>>
>>>>>> file_stream is not compatible with gzip compression in the web server,
>>>>>> such as mod_gzip or mod_deflate. This is because the entire file must
>>>>>> be buffered to the gzip module before the download can begin.
>>>>>>
>>>>>> mod_deflate can be configured to ignore certain paths, such as the url
>>>>>> used for the file_stream.
>>>>>>
>>>>>> On Tue, Nov 9, 2010 at 9:55 PM, Steve Piercy - Web Site Builder
>>>>>> <[hidden email]> wrote:
>>>>>>>
>>>>>>> Where is the file stored?  Disk or memory?
>>>>>>>
>>>>>>> file_serve would be a bad choice for large files on disk.  The entire
>>>>>>> file
>>>>>>> must be stored in memory before it is sent to the client.  If the
>>>>>>> file
>>>>>>> is
>>>>>>> in
>>>>>>> memory already, then it should be OK to use.
>>>>>>>
>>>>>>> file_stream should be immediate because it serves the file from disk
>>>>>>> in
>>>>>>> small chunks.  For file_stream the file should already be written to
>>>>>>> the
>>>>>>> file system.
>>>>>>>
>>>>>>> If file_stream is not immediate, then perhaps you have memory or
>>>>>>> other
>>>>>>> resource issues on your server?
>>>>>>>
>>>>>>> --steve
>>>>>>>
>>>>>>>
>>>>>>> On 11/9/10 at 12:47 PM, [hidden email] (Miran) pronounced:
>>>>>>>
>>>>>>>> Hi List,
>>>>>>>>
>>>>>>>> I want to serve files that are up to 40 Mb (user clicks on a link
>>>>>>>> 'download file')
>>>>>>>>
>>>>>>>> I have tried to use file_serve, but it takes about 4 minutes before
>>>>>>>> the
>>>>>>>> download actually starts
>>>>>>>> with file_stream it takes about 3 minutes before the download starts
>>>>>>>>
>>>>>>>> how can ik make sure that the download starts immediately when a
>>>>>>>> download
>>>>>>>> link is clicked ?
>>>>>>>>
>>>>>>>> thanks,
>>>>>>>> miran
>>>>>>>>
>>>>>>>> #############################################################
>>>>>>>> This message is sent to you because you are subscribed to
>>>>>>>> the mailing list <[hidden email]>.
>>>>>>>> To unsubscribe, E-mail to: <[hidden email]>
>>>>>>>> To switch to the DIGEST mode, E-mail to
>>>>>>>> <[hidden email]>
>>>>>>>> To switch to the INDEX mode, E-mail to
>>>>>>>> <[hidden email]>
>>>>>>>> Send administrative queries to  <[hidden email]>
>>>>>>>>
>>>>>>>
>>>>>>> -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
>>>>>>> Steve Piercy               Web Site Builder               Soquel, CA
>>>>>>> <[hidden email]>                  <http://www.StevePiercy.com/>
>>>>>>>
>>>>>>>
>>>>>>> #############################################################
>>>>>>> This message is sent to you because you are subscribed to
>>>>>>>  the mailing list <[hidden email]>.
>>>>>>> To unsubscribe, E-mail to: <[hidden email]>
>>>>>>> To switch to the DIGEST mode, E-mail to
>>>>>>> <[hidden email]>
>>>>>>> To switch to the INDEX mode, E-mail to
>>>>>>> <[hidden email]>
>>>>>>> Send administrative queries to  <[hidden email]>
>>>>>>>
>>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>> --
>>>>>> Mvh
>>>>>> Johan Sölve
>>>>>> ____________________________________
>>>>>> Montania System AB
>>>>>> Halmstad   Stockholm   Malmö
>>>>>> http://www.montania.se
>>>>>>
>>>>>> Johan Sölve
>>>>>> Mobil +46 709-51 55 70
>>>>>> [hidden email]
>>>>>>
>>>>>> Kristinebergsvägen 17, S-302 41 Halmstad, Sweden
>>>>>> Telefon +46 35-136800 |  Fax +46 35-136801
>>>>>>
>>>>>> #############################################################
>>>>>> This message is sent to you because you are subscribed to
>>>>>>  the mailing list <[hidden email]>.
>>>>>> To unsubscribe, E-mail to: <[hidden email]>
>>>>>> To switch to the DIGEST mode, E-mail to
>>>>>> <[hidden email]>
>>>>>> To switch to the INDEX mode, E-mail to
>>>>>> <[hidden email]>
>>>>>> Send administrative queries to  <[hidden email]>
>>>>>>
>>>>>>
>>>>>>
>>>>>
>>>>>
>>>>> #############################################################
>>>>> This message is sent to you because you are subscribed to
>>>>>  the mailing list <[hidden email]>.
>>>>> To unsubscribe, E-mail to: <[hidden email]>
>>>>> To switch to the DIGEST mode, E-mail to
>>>>> <[hidden email]>
>>>>> To switch to the INDEX mode, E-mail to
>>>>> <[hidden email]>
>>>>> Send administrative queries to  <[hidden email]>
>>>>>
>>>>>
>>>>
>>>>
>>>>
>>>> --
>>>> Mvh
>>>> Johan Sölve
>>>> ____________________________________
>>>> Montania System AB
>>>> Halmstad   Stockholm   Malmö
>>>> http://www.montania.se
>>>>
>>>> Johan Sölve
>>>> Mobil +46 709-51 55 70
>>>> [hidden email]
>>>>
>>>> Kristinebergsvägen 17, S-302 41 Halmstad, Sweden
>>>> Telefon +46 35-136800 |  Fax +46 35-136801
>>>>
>>>> #############################################################
>>>> This message is sent to you because you are subscribed to
>>>>  the mailing list <[hidden email]>.
>>>> To unsubscribe, E-mail to: <[hidden email]>
>>>> To switch to the DIGEST mode, E-mail to
>>>> <[hidden email]>
>>>> To switch to the INDEX mode, E-mail to <[hidden email]>
>>>> Send administrative queries to  <[hidden email]>
>>>>
>>>>
>>>>
>>>
>>>
>>> #############################################################
>>> This message is sent to you because you are subscribed to
>>>  the mailing list <[hidden email]>.
>>> To unsubscribe, E-mail to: <[hidden email]>
>>> To switch to the DIGEST mode, E-mail to
>>> <[hidden email]>
>>> To switch to the INDEX mode, E-mail to <[hidden email]>
>>> Send administrative queries to  <[hidden email]>
>>>
>>>
>>
>>
>>
>> --
>> Mvh
>> Johan Sölve
>> ____________________________________
>> Montania System AB
>> Halmstad   Stockholm   Malmö
>> http://www.montania.se
>>
>> Johan Sölve
>> Mobil +46 709-51 55 70
>> [hidden email]
>>
>> Kristinebergsvägen 17, S-302 41 Halmstad, Sweden
>> Telefon +46 35-136800 |  Fax +46 35-136801
>>
>> #############################################################
>> This message is sent to you because you are subscribed to
>>  the mailing list <[hidden email]>.
>> To unsubscribe, E-mail to: <[hidden email]>
>> To switch to the DIGEST mode, E-mail to <[hidden email]>
>> To switch to the INDEX mode, E-mail to <[hidden email]>
>> Send administrative queries to  <[hidden email]>
>>
>>
>>
>
>
> #############################################################
> This message is sent to you because you are subscribed to
>  the mailing list <[hidden email]>.
> To unsubscribe, E-mail to: <[hidden email]>
> To switch to the DIGEST mode, E-mail to <[hidden email]>
> To switch to the INDEX mode, E-mail to <[hidden email]>
> Send administrative queries to  <[hidden email]>
>
>



--
Mvh
Johan Sölve
____________________________________
Montania System AB
Halmstad   Stockholm   Malmö
http://www.montania.se

Johan Sölve
Mobil +46 709-51 55 70
[hidden email]

Kristinebergsvägen 17, S-302 41 Halmstad, Sweden
Telefon +46 35-136800 |  Fax +46 35-136801

#############################################################
This message is sent to you because you are subscribed to
  the mailing list <[hidden email]>.
To unsubscribe, E-mail to: <[hidden email]>
To switch to the DIGEST mode, E-mail to <[hidden email]>
To switch to the INDEX mode, E-mail to <[hidden email]>
Send administrative queries to  <[hidden email]>

Reply | Threaded
Open this post in threaded view
|

Re: serve large files

mirans
thanks, I will see if I can use this

miran

Op 10 nov 2010, om 11:21 heeft Johan Solve het volgende geschreven:

> And there's no way to put the larger files in a subdir (or copy them),
> or name them in a unique manner so you can change the mime type using
> the <files> directive?
> http://httpd.apache.org/docs/2.0/mod/core.html#files
>
> Maybe you could even add some mod_rewrite magic to be able to
> differentiate the larger files for direct download simply with a query
> string on the link, for example
> largefile.pdf?download
>
> Maybe something like (completely untested)
> RewriteCond %{QUERY_STRING} download
> RewriteRule .* - [PT,T=application/octet-stream]
>
> http://httpd.apache.org/docs/2.2/mod/mod_rewrite.html
>
>
> On Wed, Nov 10, 2010 at 11:07 AM, Miran <[hidden email]> wrote:
>> in the same directory where the large files are stored are also low  
>> res
>> files, which can be viewed in the browser
>>
>> so telling apache that all files in that directory should be  
>> downloaded
>> instead of opened is also a nogo
>> and the directories are created dynamically, every client that is  
>> using the
>> system gets his own directory
>>
>>
>>
>> Op 10 nov 2010, om 10:59 heeft Johan Solve het volgende geschreven:
>>
>>> I think you can set the mime type to something different than
>>> application/pdf for a specific directory, for example
>>> application/octet-stream.
>>> http://httpd.apache.org/docs/2.0/mod/core.html#forcetype
>>>
>>> This will tell the browser to download the file instead of showing  
>>> it.
>>>
>>> On Wed, Nov 10, 2010 at 10:47 AM, Miran <[hidden email]> wrote:
>>>>
>>>> thanks, but some files are pdf files
>>>> with a direct link to the file, the browser will try to open the  
>>>> document
>>>> this takes also too long
>>>>
>>>> and not all users understand that you can save the document with  
>>>> control
>>>> click (or how windows users do that :-)
>>>>
>>>> miran
>>>>
>>>>
>>>> Op 10 nov 2010, om 10:36 heeft Johan Solve het volgende geschreven:
>>>>
>>>>> So it's a plain static file? In that case there's no reason to  
>>>>> involve
>>>>> Lasso and you can just link directly to the file.
>>>>>
>>>>>
>>>>> On Wed, Nov 10, 2010 at 8:49 AM, Miran <[hidden email]> wrote:
>>>>>>
>>>>>> thanks for your replies
>>>>>> the file is already stored on the disk (in the webroot)
>>>>>>
>>>>>> I will look into 'mod_deflate'
>>>>>>
>>>>>> miran
>>>>>>
>>>>>> Op 9 nov 2010, om 23:57 heeft Johan Solve het volgende  
>>>>>> geschreven:
>>>>>>
>>>>>>> file_stream is not compatible with gzip compression in the web  
>>>>>>> server,
>>>>>>> such as mod_gzip or mod_deflate. This is because the entire  
>>>>>>> file must
>>>>>>> be buffered to the gzip module before the download can begin.
>>>>>>>
>>>>>>> mod_deflate can be configured to ignore certain paths, such as  
>>>>>>> the url
>>>>>>> used for the file_stream.
>>>>>>>
>>>>>>> On Tue, Nov 9, 2010 at 9:55 PM, Steve Piercy - Web Site Builder
>>>>>>> <[hidden email]> wrote:
>>>>>>>>
>>>>>>>> Where is the file stored?  Disk or memory?
>>>>>>>>
>>>>>>>> file_serve would be a bad choice for large files on disk.  
>>>>>>>> The entire
>>>>>>>> file
>>>>>>>> must be stored in memory before it is sent to the client.  If  
>>>>>>>> the
>>>>>>>> file
>>>>>>>> is
>>>>>>>> in
>>>>>>>> memory already, then it should be OK to use.
>>>>>>>>
>>>>>>>> file_stream should be immediate because it serves the file  
>>>>>>>> from disk
>>>>>>>> in
>>>>>>>> small chunks.  For file_stream the file should already be  
>>>>>>>> written to
>>>>>>>> the
>>>>>>>> file system.
>>>>>>>>
>>>>>>>> If file_stream is not immediate, then perhaps you have memory  
>>>>>>>> or
>>>>>>>> other
>>>>>>>> resource issues on your server?
>>>>>>>>
>>>>>>>> --steve
>>>>>>>>
>>>>>>>>
>>>>>>>> On 11/9/10 at 12:47 PM, [hidden email] (Miran) pronounced:
>>>>>>>>
>>>>>>>>> Hi List,
>>>>>>>>>
>>>>>>>>> I want to serve files that are up to 40 Mb (user clicks on a  
>>>>>>>>> link
>>>>>>>>> 'download file')
>>>>>>>>>
>>>>>>>>> I have tried to use file_serve, but it takes about 4 minutes  
>>>>>>>>> before
>>>>>>>>> the
>>>>>>>>> download actually starts
>>>>>>>>> with file_stream it takes about 3 minutes before the  
>>>>>>>>> download starts
>>>>>>>>>
>>>>>>>>> how can ik make sure that the download starts immediately  
>>>>>>>>> when a
>>>>>>>>> download
>>>>>>>>> link is clicked ?
>>>>>>>>>
>>>>>>>>> thanks,
>>>>>>>>> miran
>>>>>>>>>
>>>>>>>>> #############################################################
>>>>>>>>> This message is sent to you because you are subscribed to
>>>>>>>>> the mailing list <[hidden email]>.
>>>>>>>>> To unsubscribe, E-mail to: <[hidden email]>
>>>>>>>>> To switch to the DIGEST mode, E-mail to
>>>>>>>>> <[hidden email]>
>>>>>>>>> To switch to the INDEX mode, E-mail to
>>>>>>>>> <[hidden email]>
>>>>>>>>> Send administrative queries to  <[hidden email]
>>>>>>>>> >
>>>>>>>>>
>>>>>>>>
>>>>>>>> -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --  
>>>>>>>> -- -- --
>>>>>>>> Steve Piercy               Web Site Builder                
>>>>>>>> Soquel, CA
>>>>>>>> <[hidden email]>                  <http://www.StevePiercy.com/ 
>>>>>>>> >
>>>>>>>>
>>>>>>>>
>>>>>>>> #############################################################
>>>>>>>> This message is sent to you because you are subscribed to
>>>>>>>>  the mailing list <[hidden email]>.
>>>>>>>> To unsubscribe, E-mail to: <[hidden email]>
>>>>>>>> To switch to the DIGEST mode, E-mail to
>>>>>>>> <[hidden email]>
>>>>>>>> To switch to the INDEX mode, E-mail to
>>>>>>>> <[hidden email]>
>>>>>>>> Send administrative queries to  <[hidden email]
>>>>>>>> >
>>>>>>>>
>>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> --
>>>>>>> Mvh
>>>>>>> Johan Sölve
>>>>>>> ____________________________________
>>>>>>> Montania System AB
>>>>>>> Halmstad   Stockholm   Malmö
>>>>>>> http://www.montania.se
>>>>>>>
>>>>>>> Johan Sölve
>>>>>>> Mobil +46 709-51 55 70
>>>>>>> [hidden email]
>>>>>>>
>>>>>>> Kristinebergsvägen 17, S-302 41 Halmstad, Sweden
>>>>>>> Telefon +46 35-136800 |  Fax +46 35-136801
>>>>>>>
>>>>>>> #############################################################
>>>>>>> This message is sent to you because you are subscribed to
>>>>>>>  the mailing list <[hidden email]>.
>>>>>>> To unsubscribe, E-mail to: <[hidden email]>
>>>>>>> To switch to the DIGEST mode, E-mail to
>>>>>>> <[hidden email]>
>>>>>>> To switch to the INDEX mode, E-mail to
>>>>>>> <[hidden email]>
>>>>>>> Send administrative queries to  <[hidden email]
>>>>>>> >
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>
>>>>>>
>>>>>> #############################################################
>>>>>> This message is sent to you because you are subscribed to
>>>>>>  the mailing list <[hidden email]>.
>>>>>> To unsubscribe, E-mail to: <[hidden email]>
>>>>>> To switch to the DIGEST mode, E-mail to
>>>>>> <[hidden email]>
>>>>>> To switch to the INDEX mode, E-mail to
>>>>>> <[hidden email]>
>>>>>> Send administrative queries to  <[hidden email]
>>>>>> >
>>>>>>
>>>>>>
>>>>>
>>>>>
>>>>>
>>>>> --
>>>>> Mvh
>>>>> Johan Sölve
>>>>> ____________________________________
>>>>> Montania System AB
>>>>> Halmstad   Stockholm   Malmö
>>>>> http://www.montania.se
>>>>>
>>>>> Johan Sölve
>>>>> Mobil +46 709-51 55 70
>>>>> [hidden email]
>>>>>
>>>>> Kristinebergsvägen 17, S-302 41 Halmstad, Sweden
>>>>> Telefon +46 35-136800 |  Fax +46 35-136801
>>>>>
>>>>> #############################################################
>>>>> This message is sent to you because you are subscribed to
>>>>>  the mailing list <[hidden email]>.
>>>>> To unsubscribe, E-mail to: <[hidden email]>
>>>>> To switch to the DIGEST mode, E-mail to
>>>>> <[hidden email]>
>>>>> To switch to the INDEX mode, E-mail to <[hidden email]
>>>>> >
>>>>> Send administrative queries to  <lasso-
>>>>> [hidden email]>
>>>>>
>>>>>
>>>>>
>>>>
>>>>
>>>> #############################################################
>>>> This message is sent to you because you are subscribed to
>>>>  the mailing list <[hidden email]>.
>>>> To unsubscribe, E-mail to: <[hidden email]>
>>>> To switch to the DIGEST mode, E-mail to
>>>> <[hidden email]>
>>>> To switch to the INDEX mode, E-mail to <[hidden email]
>>>> >
>>>> Send administrative queries to  <[hidden email]>
>>>>
>>>>
>>>
>>>
>>>
>>> --
>>> Mvh
>>> Johan Sölve
>>> ____________________________________
>>> Montania System AB
>>> Halmstad   Stockholm   Malmö
>>> http://www.montania.se
>>>
>>> Johan Sölve
>>> Mobil +46 709-51 55 70
>>> [hidden email]
>>>
>>> Kristinebergsvägen 17, S-302 41 Halmstad, Sweden
>>> Telefon +46 35-136800 |  Fax +46 35-136801
>>>
>>> #############################################################
>>> This message is sent to you because you are subscribed to
>>>  the mailing list <[hidden email]>.
>>> To unsubscribe, E-mail to: <[hidden email]>
>>> To switch to the DIGEST mode, E-mail to <[hidden email]
>>> >
>>> To switch to the INDEX mode, E-mail to <[hidden email]
>>> >
>>> Send administrative queries to  <[hidden email]>
>>>
>>>
>>>
>>
>>
>> #############################################################
>> This message is sent to you because you are subscribed to
>>  the mailing list <[hidden email]>.
>> To unsubscribe, E-mail to: <[hidden email]>
>> To switch to the DIGEST mode, E-mail to <[hidden email]
>> >
>> To switch to the INDEX mode, E-mail to <[hidden email]
>> >
>> Send administrative queries to  <[hidden email]>
>>
>>
>
>
>
> --
> Mvh
> Johan Sölve
> ____________________________________
> Montania System AB
> Halmstad   Stockholm   Malmö
> http://www.montania.se
>
> Johan Sölve
> Mobil +46 709-51 55 70
> [hidden email]
>
> Kristinebergsvägen 17, S-302 41 Halmstad, Sweden
> Telefon +46 35-136800 |  Fax +46 35-136801
>
> #############################################################
> This message is sent to you because you are subscribed to
>  the mailing list <[hidden email]>.
> To unsubscribe, E-mail to: <[hidden email]>
> To switch to the DIGEST mode, E-mail to <[hidden email]
> >
> To switch to the INDEX mode, E-mail to <[hidden email]
> >
> Send administrative queries to  <[hidden email]>
>
>
>


#############################################################
This message is sent to you because you are subscribed to
  the mailing list <[hidden email]>.
To unsubscribe, E-mail to: <[hidden email]>
To switch to the DIGEST mode, E-mail to <[hidden email]>
To switch to the INDEX mode, E-mail to <[hidden email]>
Send administrative queries to  <[hidden email]>

Reply | Threaded
Open this post in threaded view
|

Re: serve large files

stevepiercy
This would be simpler.

<filesmatch> container in Apache:
http://httpd.apache.org/docs/2.0/mod/core.html#filesmatch

<FilesMatch "\.pdf$">
    ForceType application/octet-stream
</FilesMatch>

--steve


On 11/10/10 at 1:27 PM, [hidden email] (Miran) pronounced:

> thanks, I will see if I can use this
>
> miran
>
> Op 10 nov 2010, om 11:21 heeft Johan Solve het volgende geschreven:
>
> >And there's no way to put the larger files in a subdir (or copy them),
> >or name them in a unique manner so you can change the mime type using
> >the <files> directive?
> >http://httpd.apache.org/docs/2.0/mod/core.html#files
> >
> >Maybe you could even add some mod_rewrite magic to be able to
> >differentiate the larger files for direct download simply with a query
> >string on the link, for example
> >largefile.pdf?download
> >
> >Maybe something like (completely untested)
> >RewriteCond %{QUERY_STRING} download
> >RewriteRule .* - [PT,T=application/octet-stream]
> >
> >http://httpd.apache.org/docs/2.2/mod/mod_rewrite.html
> >
> >
> >On Wed, Nov 10, 2010 at 11:07 AM, Miran <[hidden email]> wrote:
> >>in the same directory where the large files are stored are
> >>also low res
> >>files, which can be viewed in the browser
> >>
> >>so telling apache that all files in that directory should be downloaded
> >>instead of opened is also a nogo
> >>and the directories are created dynamically, every client that
> >>is using the
> >>system gets his own directory
> >>
> >>
> >>
> >>Op 10 nov 2010, om 10:59 heeft Johan Solve het volgende geschreven:
> >>
> >>>I think you can set the mime type to something different than
> >>>application/pdf for a specific directory, for example
> >>>application/octet-stream.
> >>>http://httpd.apache.org/docs/2.0/mod/core.html#forcetype
> >>>
> >>>This will tell the browser to download the file instead of
> >>>showing it.
> >>>
> >>>On Wed, Nov 10, 2010 at 10:47 AM, Miran <[hidden email]> wrote:
> >>>>
> >>>>thanks, but some files are pdf files
> >>>>with a direct link to the file, the browser will try to open
> >>>>the document
> >>>>this takes also too long
> >>>>
> >>>>and not all users understand that you can save the document
> >>>>with control
> >>>>click (or how windows users do that :-)
> >>>>
> >>>>miran
> >>>>
> >>>>
> >>>>Op 10 nov 2010, om 10:36 heeft Johan Solve het volgende geschreven:
> >>>>
> >>>>>So it's a plain static file? In that case there's no reason
> >>>>>to involve
> >>>>>Lasso and you can just link directly to the file.
> >>>>>
> >>>>>
> >>>>>On Wed, Nov 10, 2010 at 8:49 AM, Miran <[hidden email]> wrote:
> >>>>>>
> >>>>>>thanks for your replies
> >>>>>>the file is already stored on the disk (in the webroot)
> >>>>>>
> >>>>>>I will look into 'mod_deflate'
> >>>>>>
> >>>>>>miran
> >>>>>>
> >>>>>>Op 9 nov 2010, om 23:57 heeft Johan Solve het volgende geschreven:
> >>>>>>
> >>>>>>>file_stream is not compatible with gzip compression in
> >>>>>>>the web server,
> >>>>>>>such as mod_gzip or mod_deflate. This is because the
> >>>>>>>entire file must
> >>>>>>>be buffered to the gzip module before the download can begin.
> >>>>>>>
> >>>>>>>mod_deflate can be configured to ignore certain paths,
> >>>>>>>such as the url
> >>>>>>>used for the file_stream.
> >>>>>>>
> >>>>>>>On Tue, Nov 9, 2010 at 9:55 PM, Steve Piercy - Web Site Builder
> >>>>>>><[hidden email]> wrote:
> >>>>>>>>
> >>>>>>>>Where is the file stored?  Disk or memory?
> >>>>>>>>
> >>>>>>>>file_serve would be a bad choice for large files on
> >>>>>>>>disk.  The entire
> >>>>>>>>file
> >>>>>>>>must be stored in memory before it is sent to the
> >>>>>>>>client.  If the
> >>>>>>>>file
> >>>>>>>>is
> >>>>>>>>in
> >>>>>>>>memory already, then it should be OK to use.
> >>>>>>>>
> >>>>>>>>file_stream should be immediate because it serves the
> >>>>>>>>file from disk
> >>>>>>>>in
> >>>>>>>>small chunks.  For file_stream the file should already
> >>>>>>>>be written to
> >>>>>>>>the
> >>>>>>>>file system.
> >>>>>>>>
> >>>>>>>>If file_stream is not immediate, then perhaps you have
> >>>>>>>>memory or
> >>>>>>>>other
> >>>>>>>>resource issues on your server?
> >>>>>>>>
> >>>>>>>>--steve
> >>>>>>>>
> >>>>>>>>
> >>>>>>>>On 11/9/10 at 12:47 PM, [hidden email] (Miran) pronounced:
> >>>>>>>>
> >>>>>>>>>Hi List,
> >>>>>>>>>
> >>>>>>>>>I want to serve files that are up to 40 Mb (user clicks
> >>>>>>>>>on a link
> >>>>>>>>>'download file')
> >>>>>>>>>
> >>>>>>>>>I have tried to use file_serve, but it takes about 4
> >>>>>>>>>minutes before
> >>>>>>>>>the
> >>>>>>>>>download actually starts
> >>>>>>>>>with file_stream it takes about 3 minutes before the
> >>>>>>>>>download starts
> >>>>>>>>>
> >>>>>>>>>how can ik make sure that the download starts
> >>>>>>>>>immediately when a
> >>>>>>>>>download
> >>>>>>>>>link is clicked ?
> >>>>>>>>>
> >>>>>>>>>thanks,
> >>>>>>>>>miran
> >>>>>>>>>
> >>>>>>>>>#############################################################
> >>>>>>>>>This message is sent to you because you are subscribed to
> >>>>>>>>>the mailing list <[hidden email]>.
> >>>>>>>>>To unsubscribe, E-mail to: <[hidden email]>
> >>>>>>>>>To switch to the DIGEST mode, E-mail to
> >>>>>>>>><[hidden email]>
> >>>>>>>>>To switch to the INDEX mode, E-mail to
> >>>>>>>>><[hidden email]>
> >>>>>>>>>Send administrative queries to  <[hidden email]>
> >>>>>>>>>
> >>>>>>>>
> >>>>>>>>-- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
> >>>>>>>>-- -- -- --
> >>>>>>>>Steve Piercy               Web Site
> >>>>>>>>Builder               Soquel, CA
> >>>>>>>><[hidden email]>                  <http://www.StevePiercy.com/>
> >>>>>>>>
> >>>>>>>>
> >>>>>>>>#############################################################
> >>>>>>>>This message is sent to you because you are subscribed to
> >>>>>>>> the mailing list <[hidden email]>.
> >>>>>>>>To unsubscribe, E-mail to: <[hidden email]>
> >>>>>>>>To switch to the DIGEST mode, E-mail to
> >>>>>>>><[hidden email]>
> >>>>>>>>To switch to the INDEX mode, E-mail to
> >>>>>>>><[hidden email]>
> >>>>>>>>Send administrative queries to  <[hidden email]>
> >>>>>>>>
> >>>>>>>>
> >>>>>>>
> >>>>>>>
> >>>>>>>
> >>>>>>>--
> >>>>>>>Mvh
> >>>>>>>Johan Sölve
> >>>>>>>____________________________________
> >>>>>>>Montania System AB
> >>>>>>>Halmstad   Stockholm   Malmö
> >>>>>>>http://www.montania.se
> >>>>>>>
> >>>>>>>Johan Sölve
> >>>>>>>Mobil +46 709-51 55 70
> >>>>>>>[hidden email]
> >>>>>>>
> >>>>>>>Kristinebergsvägen 17, S-302 41 Halmstad, Sweden
> >>>>>>>Telefon +46 35-136800 |  Fax +46 35-136801
> >>>>>>>
> >>>>>>>#############################################################
> >>>>>>>This message is sent to you because you are subscribed to
> >>>>>>> the mailing list <[hidden email]>.
> >>>>>>>To unsubscribe, E-mail to: <[hidden email]>
> >>>>>>>To switch to the DIGEST mode, E-mail to
> >>>>>>><[hidden email]>
> >>>>>>>To switch to the INDEX mode, E-mail to
> >>>>>>><[hidden email]>
> >>>>>>>Send administrative queries to  <[hidden email]>
> >>>>>>>
> >>>>>>>
> >>>>>>>
> >>>>>>
> >>>>>>
> >>>>>>#############################################################
> >>>>>>This message is sent to you because you are subscribed to
> >>>>>> the mailing list <[hidden email]>.
> >>>>>>To unsubscribe, E-mail to: <[hidden email]>
> >>>>>>To switch to the DIGEST mode, E-mail to
> >>>>>><[hidden email]>
> >>>>>>To switch to the INDEX mode, E-mail to
> >>>>>><[hidden email]>
> >>>>>>Send administrative queries to  <[hidden email]>
> >>>>>>
> >>>>>>
> >>>>>
> >>>>>
> >>>>>
> >>>>>--
> >>>>>Mvh
> >>>>>Johan Sölve
> >>>>>____________________________________
> >>>>>Montania System AB
> >>>>>Halmstad   Stockholm   Malmö
> >>>>>http://www.montania.se
> >>>>>
> >>>>>Johan Sölve
> >>>>>Mobil +46 709-51 55 70
> >>>>>[hidden email]
> >>>>>
> >>>>>Kristinebergsvägen 17, S-302 41 Halmstad, Sweden
> >>>>>Telefon +46 35-136800 |  Fax +46 35-136801
> >>>>>
> >>>>>#############################################################
> >>>>>This message is sent to you because you are subscribed to
> >>>>> the mailing list <[hidden email]>.
> >>>>>To unsubscribe, E-mail to: <[hidden email]>
> >>>>>To switch to the DIGEST mode, E-mail to
> >>>>><[hidden email]>
> >>>>>To switch to the INDEX mode, E-mail to <[hidden email]>
> >>>>>Send administrative queries to  <[hidden email]>
> >>>>>
> >>>>>
> >>>>>
> >>>>
> >>>>
> >>>>#############################################################
> >>>>This message is sent to you because you are subscribed to
> >>>> the mailing list <[hidden email]>.
> >>>>To unsubscribe, E-mail to: <[hidden email]>
> >>>>To switch to the DIGEST mode, E-mail to
> >>>><[hidden email]>
> >>>>To switch to the INDEX mode, E-mail to <[hidden email]>
> >>>>Send administrative queries to  <[hidden email]>
> >>>>
> >>>>
> >>>
> >>>
> >>>
> >>>--
> >>>Mvh
> >>>Johan Sölve
> >>>____________________________________
> >>>Montania System AB
> >>>Halmstad   Stockholm   Malmö
> >>>http://www.montania.se
> >>>
> >>>Johan Sölve
> >>>Mobil +46 709-51 55 70
> >>>[hidden email]
> >>>
> >>>Kristinebergsvägen 17, S-302 41 Halmstad, Sweden
> >>>Telefon +46 35-136800 |  Fax +46 35-136801
> >>>
> >>>#############################################################
> >>>This message is sent to you because you are subscribed to
> >>> the mailing list <[hidden email]>.
> >>>To unsubscribe, E-mail to: <[hidden email]>
> >>>To switch to the DIGEST mode, E-mail to <[hidden email]>
> >>>To switch to the INDEX mode, E-mail to <[hidden email]>
> >>>Send administrative queries to  <[hidden email]>
> >>>
> >>>
> >>>
> >>
> >>
> >>#############################################################
> >>This message is sent to you because you are subscribed to
> >> the mailing list <[hidden email]>.
> >>To unsubscribe, E-mail to: <[hidden email]>
> >>To switch to the DIGEST mode, E-mail to <[hidden email]>
> >>To switch to the INDEX mode, E-mail to <[hidden email]>
> >>Send administrative queries to  <[hidden email]>
> >>
> >>
> >
> >
> >
> >--
> >Mvh
> >Johan Sölve
> >____________________________________
> >Montania System AB
> >Halmstad   Stockholm   Malmö
> >http://www.montania.se
> >
> >Johan Sölve
> >Mobil +46 709-51 55 70
> >[hidden email]
> >
> >Kristinebergsvägen 17, S-302 41 Halmstad, Sweden
> >Telefon +46 35-136800 |  Fax +46 35-136801
> >
> >#############################################################
> >This message is sent to you because you are subscribed to
> > the mailing list <[hidden email]>.
> >To unsubscribe, E-mail to: <[hidden email]>
> >To switch to the DIGEST mode, E-mail to <[hidden email]>
> >To switch to the INDEX mode, E-mail to <[hidden email]>
> >Send administrative queries to  <[hidden email]>
> >
> >
> >
>
>
> #############################################################
> This message is sent to you because you are subscribed to
>  the mailing list <[hidden email]>.
> To unsubscribe, E-mail to: <[hidden email]>
> To switch to the DIGEST mode, E-mail to <[hidden email]>
> To switch to the INDEX mode, E-mail to <[hidden email]>
> Send administrative queries to  <[hidden email]>
>

-- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
Steve Piercy               Web Site Builder               Soquel, CA
<[hidden email]>                  <http://www.StevePiercy.com/>


#############################################################
This message is sent to you because you are subscribed to
  the mailing list <[hidden email]>.
To unsubscribe, E-mail to: <[hidden email]>
To switch to the DIGEST mode, E-mail to <[hidden email]>
To switch to the INDEX mode, E-mail to <[hidden email]>
Send administrative queries to  <[hidden email]>

Reply | Threaded
Open this post in threaded view
|

Re: serve large files

Johan Solve
My understanding was that smaller pdfs would be ok to view in browser,
that's why I suggested a way to decide download or view per file.

On Wed, Nov 10, 2010 at 10:14 PM, Steve Piercy - Web Site Builder
<[hidden email]> wrote:

> This would be simpler.
>
> <filesmatch> container in Apache:
> http://httpd.apache.org/docs/2.0/mod/core.html#filesmatch
>
> <FilesMatch "\.pdf$">
>    ForceType application/octet-stream
> </FilesMatch>
>
> --steve
>
>
> On 11/10/10 at 1:27 PM, [hidden email] (Miran) pronounced:
>
>> thanks, I will see if I can use this
>>
>> miran
>>
>> Op 10 nov 2010, om 11:21 heeft Johan Solve het volgende geschreven:
>>
>> >And there's no way to put the larger files in a subdir (or copy them),
>> >or name them in a unique manner so you can change the mime type using
>> >the <files> directive?
>> >http://httpd.apache.org/docs/2.0/mod/core.html#files
>> >
>> >Maybe you could even add some mod_rewrite magic to be able to
>> >differentiate the larger files for direct download simply with a query
>> >string on the link, for example
>> >largefile.pdf?download
>> >
>> >Maybe something like (completely untested)
>> >RewriteCond %{QUERY_STRING} download
>> >RewriteRule .* - [PT,T=application/octet-stream]
>> >
>> >http://httpd.apache.org/docs/2.2/mod/mod_rewrite.html
>> >
>> >
>> >On Wed, Nov 10, 2010 at 11:07 AM, Miran <[hidden email]> wrote:
>> >>in the same directory where the large files are stored are
>> >>also low res
>> >>files, which can be viewed in the browser
>> >>
>> >>so telling apache that all files in that directory should be downloaded
>> >>instead of opened is also a nogo
>> >>and the directories are created dynamically, every client that
>> >>is using the
>> >>system gets his own directory
>> >>
>> >>
>> >>
>> >>Op 10 nov 2010, om 10:59 heeft Johan Solve het volgende geschreven:
>> >>
>> >>>I think you can set the mime type to something different than
>> >>>application/pdf for a specific directory, for example
>> >>>application/octet-stream.
>> >>>http://httpd.apache.org/docs/2.0/mod/core.html#forcetype
>> >>>
>> >>>This will tell the browser to download the file instead of
>> >>>showing it.
>> >>>
>> >>>On Wed, Nov 10, 2010 at 10:47 AM, Miran <[hidden email]> wrote:
>> >>>>
>> >>>>thanks, but some files are pdf files
>> >>>>with a direct link to the file, the browser will try to open
>> >>>>the document
>> >>>>this takes also too long
>> >>>>
>> >>>>and not all users understand that you can save the document
>> >>>>with control
>> >>>>click (or how windows users do that :-)
>> >>>>
>> >>>>miran
>> >>>>
>> >>>>
>> >>>>Op 10 nov 2010, om 10:36 heeft Johan Solve het volgende geschreven:
>> >>>>
>> >>>>>So it's a plain static file? In that case there's no reason
>> >>>>>to involve
>> >>>>>Lasso and you can just link directly to the file.
>> >>>>>
>> >>>>>
>> >>>>>On Wed, Nov 10, 2010 at 8:49 AM, Miran <[hidden email]> wrote:
>> >>>>>>
>> >>>>>>thanks for your replies
>> >>>>>>the file is already stored on the disk (in the webroot)
>> >>>>>>
>> >>>>>>I will look into 'mod_deflate'
>> >>>>>>
>> >>>>>>miran
>> >>>>>>
>> >>>>>>Op 9 nov 2010, om 23:57 heeft Johan Solve het volgende geschreven:
>> >>>>>>
>> >>>>>>>file_stream is not compatible with gzip compression in
>> >>>>>>>the web server,
>> >>>>>>>such as mod_gzip or mod_deflate. This is because the
>> >>>>>>>entire file must
>> >>>>>>>be buffered to the gzip module before the download can begin.
>> >>>>>>>
>> >>>>>>>mod_deflate can be configured to ignore certain paths,
>> >>>>>>>such as the url
>> >>>>>>>used for the file_stream.
>> >>>>>>>
>> >>>>>>>On Tue, Nov 9, 2010 at 9:55 PM, Steve Piercy - Web Site Builder
>> >>>>>>><[hidden email]> wrote:
>> >>>>>>>>
>> >>>>>>>>Where is the file stored?  Disk or memory?
>> >>>>>>>>
>> >>>>>>>>file_serve would be a bad choice for large files on
>> >>>>>>>>disk.  The entire
>> >>>>>>>>file
>> >>>>>>>>must be stored in memory before it is sent to the
>> >>>>>>>>client.  If the
>> >>>>>>>>file
>> >>>>>>>>is
>> >>>>>>>>in
>> >>>>>>>>memory already, then it should be OK to use.
>> >>>>>>>>
>> >>>>>>>>file_stream should be immediate because it serves the
>> >>>>>>>>file from disk
>> >>>>>>>>in
>> >>>>>>>>small chunks.  For file_stream the file should already
>> >>>>>>>>be written to
>> >>>>>>>>the
>> >>>>>>>>file system.
>> >>>>>>>>
>> >>>>>>>>If file_stream is not immediate, then perhaps you have
>> >>>>>>>>memory or
>> >>>>>>>>other
>> >>>>>>>>resource issues on your server?
>> >>>>>>>>
>> >>>>>>>>--steve
>> >>>>>>>>
>> >>>>>>>>
>> >>>>>>>>On 11/9/10 at 12:47 PM, [hidden email] (Miran) pronounced:
>> >>>>>>>>
>> >>>>>>>>>Hi List,
>> >>>>>>>>>
>> >>>>>>>>>I want to serve files that are up to 40 Mb (user clicks
>> >>>>>>>>>on a link
>> >>>>>>>>>'download file')
>> >>>>>>>>>
>> >>>>>>>>>I have tried to use file_serve, but it takes about 4
>> >>>>>>>>>minutes before
>> >>>>>>>>>the
>> >>>>>>>>>download actually starts
>> >>>>>>>>>with file_stream it takes about 3 minutes before the
>> >>>>>>>>>download starts
>> >>>>>>>>>
>> >>>>>>>>>how can ik make sure that the download starts
>> >>>>>>>>>immediately when a
>> >>>>>>>>>download
>> >>>>>>>>>link is clicked ?
>> >>>>>>>>>
>> >>>>>>>>>thanks,
>> >>>>>>>>>miran
>> >>>>>>>>>
>> >>>>>>>>>#############################################################
>> >>>>>>>>>This message is sent to you because you are subscribed to
>> >>>>>>>>>the mailing list <[hidden email]>.
>> >>>>>>>>>To unsubscribe, E-mail to: <[hidden email]>
>> >>>>>>>>>To switch to the DIGEST mode, E-mail to
>> >>>>>>>>><[hidden email]>
>> >>>>>>>>>To switch to the INDEX mode, E-mail to
>> >>>>>>>>><[hidden email]>
>> >>>>>>>>>Send administrative queries to  <[hidden email]>
>> >>>>>>>>>
>> >>>>>>>>
>> >>>>>>>>-- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
>> >>>>>>>>-- -- -- --
>> >>>>>>>>Steve Piercy               Web Site
>> >>>>>>>>Builder               Soquel, CA
>> >>>>>>>><[hidden email]>                  <http://www.StevePiercy.com/>
>> >>>>>>>>
>> >>>>>>>>
>> >>>>>>>>#############################################################
>> >>>>>>>>This message is sent to you because you are subscribed to
>> >>>>>>>> the mailing list <[hidden email]>.
>> >>>>>>>>To unsubscribe, E-mail to: <[hidden email]>
>> >>>>>>>>To switch to the DIGEST mode, E-mail to
>> >>>>>>>><[hidden email]>
>> >>>>>>>>To switch to the INDEX mode, E-mail to
>> >>>>>>>><[hidden email]>
>> >>>>>>>>Send administrative queries to  <[hidden email]>
>> >>>>>>>>
>> >>>>>>>>
>> >>>>>>>
>> >>>>>>>
>> >>>>>>>
>> >>>>>>>--
>> >>>>>>>Mvh
>> >>>>>>>Johan Sölve
>> >>>>>>>____________________________________
>> >>>>>>>Montania System AB
>> >>>>>>>Halmstad   Stockholm   Malmö
>> >>>>>>>http://www.montania.se
>> >>>>>>>
>> >>>>>>>Johan Sölve
>> >>>>>>>Mobil +46 709-51 55 70
>> >>>>>>>[hidden email]
>> >>>>>>>
>> >>>>>>>Kristinebergsvägen 17, S-302 41 Halmstad, Sweden
>> >>>>>>>Telefon +46 35-136800 |  Fax +46 35-136801
>> >>>>>>>
>> >>>>>>>#############################################################
>> >>>>>>>This message is sent to you because you are subscribed to
>> >>>>>>> the mailing list <[hidden email]>.
>> >>>>>>>To unsubscribe, E-mail to: <[hidden email]>
>> >>>>>>>To switch to the DIGEST mode, E-mail to
>> >>>>>>><[hidden email]>
>> >>>>>>>To switch to the INDEX mode, E-mail to
>> >>>>>>><[hidden email]>
>> >>>>>>>Send administrative queries to  <[hidden email]>
>> >>>>>>>
>> >>>>>>>
>> >>>>>>>
>> >>>>>>
>> >>>>>>
>> >>>>>>#############################################################
>> >>>>>>This message is sent to you because you are subscribed to
>> >>>>>> the mailing list <[hidden email]>.
>> >>>>>>To unsubscribe, E-mail to: <[hidden email]>
>> >>>>>>To switch to the DIGEST mode, E-mail to
>> >>>>>><[hidden email]>
>> >>>>>>To switch to the INDEX mode, E-mail to
>> >>>>>><[hidden email]>
>> >>>>>>Send administrative queries to  <[hidden email]>
>> >>>>>>
>> >>>>>>
>> >>>>>
>> >>>>>
>> >>>>>
>> >>>>>--
>> >>>>>Mvh
>> >>>>>Johan Sölve
>> >>>>>____________________________________
>> >>>>>Montania System AB
>> >>>>>Halmstad   Stockholm   Malmö
>> >>>>>http://www.montania.se
>> >>>>>
>> >>>>>Johan Sölve
>> >>>>>Mobil +46 709-51 55 70
>> >>>>>[hidden email]
>> >>>>>
>> >>>>>Kristinebergsvägen 17, S-302 41 Halmstad, Sweden
>> >>>>>Telefon +46 35-136800 |  Fax +46 35-136801
>> >>>>>
>> >>>>>#############################################################
>> >>>>>This message is sent to you because you are subscribed to
>> >>>>> the mailing list <[hidden email]>.
>> >>>>>To unsubscribe, E-mail to: <[hidden email]>
>> >>>>>To switch to the DIGEST mode, E-mail to
>> >>>>><[hidden email]>
>> >>>>>To switch to the INDEX mode, E-mail to <[hidden email]>
>> >>>>>Send administrative queries to  <[hidden email]>
>> >>>>>
>> >>>>>
>> >>>>>
>> >>>>
>> >>>>
>> >>>>#############################################################
>> >>>>This message is sent to you because you are subscribed to
>> >>>> the mailing list <[hidden email]>.
>> >>>>To unsubscribe, E-mail to: <[hidden email]>
>> >>>>To switch to the DIGEST mode, E-mail to
>> >>>><[hidden email]>
>> >>>>To switch to the INDEX mode, E-mail to <[hidden email]>
>> >>>>Send administrative queries to  <[hidden email]>
>> >>>>
>> >>>>
>> >>>
>> >>>
>> >>>
>> >>>--
>> >>>Mvh
>> >>>Johan Sölve
>> >>>____________________________________
>> >>>Montania System AB
>> >>>Halmstad   Stockholm   Malmö
>> >>>http://www.montania.se
>> >>>
>> >>>Johan Sölve
>> >>>Mobil +46 709-51 55 70
>> >>>[hidden email]
>> >>>
>> >>>Kristinebergsvägen 17, S-302 41 Halmstad, Sweden
>> >>>Telefon +46 35-136800 |  Fax +46 35-136801
>> >>>
>> >>>#############################################################
>> >>>This message is sent to you because you are subscribed to
>> >>> the mailing list <[hidden email]>.
>> >>>To unsubscribe, E-mail to: <[hidden email]>
>> >>>To switch to the DIGEST mode, E-mail to <[hidden email]>
>> >>>To switch to the INDEX mode, E-mail to <[hidden email]>
>> >>>Send administrative queries to  <[hidden email]>
>> >>>
>> >>>
>> >>>
>> >>
>> >>
>> >>#############################################################
>> >>This message is sent to you because you are subscribed to
>> >> the mailing list <[hidden email]>.
>> >>To unsubscribe, E-mail to: <[hidden email]>
>> >>To switch to the DIGEST mode, E-mail to <[hidden email]>
>> >>To switch to the INDEX mode, E-mail to <[hidden email]>
>> >>Send administrative queries to  <[hidden email]>
>> >>
>> >>
>> >
>> >
>> >
>> >--
>> >Mvh
>> >Johan Sölve
>> >____________________________________
>> >Montania System AB
>> >Halmstad   Stockholm   Malmö
>> >http://www.montania.se
>> >
>> >Johan Sölve
>> >Mobil +46 709-51 55 70
>> >[hidden email]
>> >
>> >Kristinebergsvägen 17, S-302 41 Halmstad, Sweden
>> >Telefon +46 35-136800 |  Fax +46 35-136801
>> >
>> >#############################################################
>> >This message is sent to you because you are subscribed to
>> > the mailing list <[hidden email]>.
>> >To unsubscribe, E-mail to: <[hidden email]>
>> >To switch to the DIGEST mode, E-mail to <[hidden email]>
>> >To switch to the INDEX mode, E-mail to <[hidden email]>
>> >Send administrative queries to  <[hidden email]>
>> >
>> >
>> >
>>
>>
>> #############################################################
>> This message is sent to you because you are subscribed to
>>  the mailing list <[hidden email]>.
>> To unsubscribe, E-mail to: <[hidden email]>
>> To switch to the DIGEST mode, E-mail to <[hidden email]>
>> To switch to the INDEX mode, E-mail to <[hidden email]>
>> Send administrative queries to  <[hidden email]>
>>
>
> -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
> Steve Piercy               Web Site Builder               Soquel, CA
> <[hidden email]>                  <http://www.StevePiercy.com/>
>
>
> #############################################################
> This message is sent to you because you are subscribed to
>  the mailing list <[hidden email]>.
> To unsubscribe, E-mail to: <[hidden email]>
> To switch to the DIGEST mode, E-mail to <[hidden email]>
> To switch to the INDEX mode, E-mail to <[hidden email]>
> Send administrative queries to  <[hidden email]>
>
>



--
Mvh
Johan Sölve
____________________________________
Montania System AB
Halmstad   Stockholm   Malmö
http://www.montania.se

Johan Sölve
Mobil +46 709-51 55 70
[hidden email]

Kristinebergsvägen 17, S-302 41 Halmstad, Sweden
Telefon +46 35-136800 |  Fax +46 35-136801

#############################################################
This message is sent to you because you are subscribed to
  the mailing list <[hidden email]>.
To unsubscribe, E-mail to: <[hidden email]>
To switch to the DIGEST mode, E-mail to <[hidden email]>
To switch to the INDEX mode, E-mail to <[hidden email]>
Send administrative queries to  <[hidden email]>

Reply | Threaded
Open this post in threaded view
|

Re: serve large files

stevepiercy
Yeah, it was ambiguous what the OP desired.  Well, now they can
choose from the options offered!

--steve


On 11/10/10 at 10:56 PM, [hidden email] (Johan Solve) pronounced:

>My understanding was that smaller pdfs would be ok to view in browser,
>that's why I suggested a way to decide download or view per file.
>
>On Wed, Nov 10, 2010 at 10:14 PM, Steve Piercy - Web Site Builder
><[hidden email]> wrote:
>>This would be simpler.
>>
>><filesmatch> container in Apache:
>>http://httpd.apache.org/docs/2.0/mod/core.html#filesmatch
>>
>><FilesMatch "\.pdf$">
>>   ForceType application/octet-stream
>></FilesMatch>
>>
>>--steve
>>
>>
>>On 11/10/10 at 1:27 PM, [hidden email] (Miran) pronounced:
>>
>>> thanks, I will see if I can use this
>>>
>>> miran
>>>
>>> Op 10 nov 2010, om 11:21 heeft Johan Solve het volgende geschreven:
>>>
>>> >And there's no way to put the larger files in a subdir (or copy them),
>>> >or name them in a unique manner so you can change the mime type using
>>> >the <files> directive?
>>> >http://httpd.apache.org/docs/2.0/mod/core.html#files
>>> >
>>> >Maybe you could even add some mod_rewrite magic to be able to
>>> >differentiate the larger files for direct download simply with a query
>>> >string on the link, for example
>>> >largefile.pdf?download
>>> >
>>> >Maybe something like (completely untested)
>>> >RewriteCond %{QUERY_STRING} download
>>> >RewriteRule .* - [PT,T=application/octet-stream]
>>> >
>>> >http://httpd.apache.org/docs/2.2/mod/mod_rewrite.html
>>> >
>>> >
>>> >On Wed, Nov 10, 2010 at 11:07 AM, Miran <[hidden email]> wrote:
>>> >>in the same directory where the large files are stored are
>>> >>also low res
>>> >>files, which can be viewed in the browser
>>> >>
>>> >>so telling apache that all files in that directory should be downloaded
>>> >>instead of opened is also a nogo
>>> >>and the directories are created dynamically, every client that
>>> >>is using the
>>> >>system gets his own directory
>>> >>
>>> >>
>>> >>
>>> >>Op 10 nov 2010, om 10:59 heeft Johan Solve het volgende geschreven:
>>> >>
>>> >>>I think you can set the mime type to something different than
>>> >>>application/pdf for a specific directory, for example
>>> >>>application/octet-stream.
>>> >>>http://httpd.apache.org/docs/2.0/mod/core.html#forcetype
>>> >>>
>>> >>>This will tell the browser to download the file instead of
>>> >>>showing it.
>>> >>>
>>> >>>On Wed, Nov 10, 2010 at 10:47 AM, Miran <[hidden email]> wrote:
>>> >>>>
>>> >>>>thanks, but some files are pdf files
>>> >>>>with a direct link to the file, the browser will try to open
>>> >>>>the document
>>> >>>>this takes also too long
>>> >>>>
>>> >>>>and not all users understand that you can save the document
>>> >>>>with control
>>> >>>>click (or how windows users do that :-)
>>> >>>>
>>> >>>>miran
>>> >>>>
>>> >>>>
>>> >>>>Op 10 nov 2010, om 10:36 heeft Johan Solve het volgende geschreven:
>>> >>>>
>>> >>>>>So it's a plain static file? In that case there's no reason
>>> >>>>>to involve
>>> >>>>>Lasso and you can just link directly to the file.
>>> >>>>>
>>> >>>>>
>>> >>>>>On Wed, Nov 10, 2010 at 8:49 AM, Miran <[hidden email]> wrote:
>>> >>>>>>
>>> >>>>>>thanks for your replies
>>> >>>>>>the file is already stored on the disk (in the webroot)
>>> >>>>>>
>>> >>>>>>I will look into 'mod_deflate'
>>> >>>>>>
>>> >>>>>>miran
>>> >>>>>>
>>> >>>>>>Op 9 nov 2010, om 23:57 heeft Johan Solve het volgende geschreven:
>>> >>>>>>
>>> >>>>>>>file_stream is not compatible with gzip compression in
>>> >>>>>>>the web server,
>>> >>>>>>>such as mod_gzip or mod_deflate. This is because the
>>> >>>>>>>entire file must
>>> >>>>>>>be buffered to the gzip module before the download can begin.
>>> >>>>>>>
>>> >>>>>>>mod_deflate can be configured to ignore certain paths,
>>> >>>>>>>such as the url
>>> >>>>>>>used for the file_stream.
>>> >>>>>>>
>>> >>>>>>>On Tue, Nov 9, 2010 at 9:55 PM, Steve Piercy - Web Site Builder
>>> >>>>>>><[hidden email]> wrote:
>>> >>>>>>>>
>>> >>>>>>>>Where is the file stored?  Disk or memory?
>>> >>>>>>>>
>>> >>>>>>>>file_serve would be a bad choice for large files on
>>> >>>>>>>>disk.  The entire
>>> >>>>>>>>file
>>> >>>>>>>>must be stored in memory before it is sent to the
>>> >>>>>>>>client.  If the
>>> >>>>>>>>file
>>> >>>>>>>>is
>>> >>>>>>>>in
>>> >>>>>>>>memory already, then it should be OK to use.
>>> >>>>>>>>
>>> >>>>>>>>file_stream should be immediate because it serves the
>>> >>>>>>>>file from disk
>>> >>>>>>>>in
>>> >>>>>>>>small chunks.  For file_stream the file should already
>>> >>>>>>>>be written to
>>> >>>>>>>>the
>>> >>>>>>>>file system.
>>> >>>>>>>>
>>> >>>>>>>>If file_stream is not immediate, then perhaps you have
>>> >>>>>>>>memory or
>>> >>>>>>>>other
>>> >>>>>>>>resource issues on your server?
>>> >>>>>>>>
>>> >>>>>>>>--steve
>>> >>>>>>>>
>>> >>>>>>>>
>>> >>>>>>>>On 11/9/10 at 12:47 PM, [hidden email] (Miran) pronounced:
>>> >>>>>>>>
>>> >>>>>>>>>Hi List,
>>> >>>>>>>>>
>>> >>>>>>>>>I want to serve files that are up to 40 Mb (user clicks
>>> >>>>>>>>>on a link
>>> >>>>>>>>>'download file')
>>> >>>>>>>>>
>>> >>>>>>>>>I have tried to use file_serve, but it takes about 4
>>> >>>>>>>>>minutes before
>>> >>>>>>>>>the
>>> >>>>>>>>>download actually starts
>>> >>>>>>>>>with file_stream it takes about 3 minutes before the
>>> >>>>>>>>>download starts
>>> >>>>>>>>>
>>> >>>>>>>>>how can ik make sure that the download starts
>>> >>>>>>>>>immediately when a
>>> >>>>>>>>>download
>>> >>>>>>>>>link is clicked ?
>>> >>>>>>>>>
>>> >>>>>>>>>thanks,
>>> >>>>>>>>>miran
>>> >>>>>>>>>
>>> >>>>>>>>>#############################################################
>>> >>>>>>>>>This message is sent to you because you are subscribed to
>>> >>>>>>>>>the mailing list <[hidden email]>.
>>> >>>>>>>>>To unsubscribe, E-mail to: <[hidden email]>
>>> >>>>>>>>>To switch to the DIGEST mode, E-mail to
>>> >>>>>>>>><[hidden email]>
>>> >>>>>>>>>To switch to the INDEX mode, E-mail to
>>> >>>>>>>>><[hidden email]>
>>> >>>>>>>>>Send administrative queries to  <[hidden email]>
>>> >>>>>>>>>
>>> >>>>>>>>
>>> >>>>>>>>-- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
>>> >>>>>>>>-- -- -- --
>>> >>>>>>>>Steve Piercy               Web Site
>>> >>>>>>>>Builder               Soquel, CA
>>> >>>>>>>><[hidden email]>                  <http://www.StevePiercy.com/>
>>> >>>>>>>>
>>> >>>>>>>>
>>> >>>>>>>>#############################################################
>>> >>>>>>>>This message is sent to you because you are subscribed to
>>> >>>>>>>> the mailing list <[hidden email]>.
>>> >>>>>>>>To unsubscribe, E-mail to: <[hidden email]>
>>> >>>>>>>>To switch to the DIGEST mode, E-mail to
>>> >>>>>>>><[hidden email]>
>>> >>>>>>>>To switch to the INDEX mode, E-mail to
>>> >>>>>>>><[hidden email]>
>>> >>>>>>>>Send administrative queries to  <[hidden email]>
>>> >>>>>>>>
>>> >>>>>>>>
>>> >>>>>>>
>>> >>>>>>>
>>> >>>>>>>
>>> >>>>>>>--
>>> >>>>>>>Mvh
>>> >>>>>>>Johan Sölve
>>> >>>>>>>____________________________________
>>> >>>>>>>Montania System AB
>>> >>>>>>>Halmstad   Stockholm   Malmö
>>> >>>>>>>http://www.montania.se
>>> >>>>>>>
>>> >>>>>>>Johan Sölve
>>> >>>>>>>Mobil +46 709-51 55 70
>>> >>>>>>>[hidden email]
>>> >>>>>>>
>>> >>>>>>>Kristinebergsvägen 17, S-302 41 Halmstad, Sweden
>>> >>>>>>>Telefon +46 35-136800 |  Fax +46 35-136801
>>> >>>>>>>
>>> >>>>>>>#############################################################
>>> >>>>>>>This message is sent to you because you are subscribed to
>>> >>>>>>> the mailing list <[hidden email]>.
>>> >>>>>>>To unsubscribe, E-mail to: <[hidden email]>
>>> >>>>>>>To switch to the DIGEST mode, E-mail to
>>> >>>>>>><[hidden email]>
>>> >>>>>>>To switch to the INDEX mode, E-mail to
>>> >>>>>>><[hidden email]>
>>> >>>>>>>Send administrative queries to  <[hidden email]>
>>> >>>>>>>
>>> >>>>>>>
>>> >>>>>>>
>>> >>>>>>
>>> >>>>>>
>>> >>>>>>#############################################################
>>> >>>>>>This message is sent to you because you are subscribed to
>>> >>>>>> the mailing list <[hidden email]>.
>>> >>>>>>To unsubscribe, E-mail to: <[hidden email]>
>>> >>>>>>To switch to the DIGEST mode, E-mail to
>>> >>>>>><[hidden email]>
>>> >>>>>>To switch to the INDEX mode, E-mail to
>>> >>>>>><[hidden email]>
>>> >>>>>>Send administrative queries to  <[hidden email]>
>>> >>>>>>
>>> >>>>>>
>>> >>>>>
>>> >>>>>
>>> >>>>>
>>> >>>>>--
>>> >>>>>Mvh
>>> >>>>>Johan Sölve
>>> >>>>>____________________________________
>>> >>>>>Montania System AB
>>> >>>>>Halmstad   Stockholm   Malmö
>>> >>>>>http://www.montania.se
>>> >>>>>
>>> >>>>>Johan Sölve
>>> >>>>>Mobil +46 709-51 55 70
>>> >>>>>[hidden email]
>>> >>>>>
>>> >>>>>Kristinebergsvägen 17, S-302 41 Halmstad, Sweden
>>> >>>>>Telefon +46 35-136800 |  Fax +46 35-136801
>>> >>>>>
>>> >>>>>#############################################################
>>> >>>>>This message is sent to you because you are subscribed to
>>> >>>>> the mailing list <[hidden email]>.
>>> >>>>>To unsubscribe, E-mail to: <[hidden email]>
>>> >>>>>To switch to the DIGEST mode, E-mail to
>>> >>>>><[hidden email]>
>>> >>>>>To switch to the INDEX mode, E-mail to <[hidden email]>
>>> >>>>>Send administrative queries to  <[hidden email]>
>>> >>>>>
>>> >>>>>
>>> >>>>>
>>> >>>>
>>> >>>>
>>> >>>>#############################################################
>>> >>>>This message is sent to you because you are subscribed to
>>> >>>> the mailing list <[hidden email]>.
>>> >>>>To unsubscribe, E-mail to: <[hidden email]>
>>> >>>>To switch to the DIGEST mode, E-mail to
>>> >>>><[hidden email]>
>>> >>>>To switch to the INDEX mode, E-mail to <[hidden email]>
>>> >>>>Send administrative queries to  <[hidden email]>
>>> >>>>
>>> >>>>
>>> >>>
>>> >>>
>>> >>>
>>> >>>--
>>> >>>Mvh
>>> >>>Johan Sölve
>>> >>>____________________________________
>>> >>>Montania System AB
>>> >>>Halmstad   Stockholm   Malmö
>>> >>>http://www.montania.se
>>> >>>
>>> >>>Johan Sölve
>>> >>>Mobil +46 709-51 55 70
>>> >>>[hidden email]
>>> >>>
>>> >>>Kristinebergsvägen 17, S-302 41 Halmstad, Sweden
>>> >>>Telefon +46 35-136800 |  Fax +46 35-136801
>>> >>>
>>> >>>#############################################################
>>> >>>This message is sent to you because you are subscribed to
>>> >>> the mailing list <[hidden email]>.
>>> >>>To unsubscribe, E-mail to: <[hidden email]>
>>> >>>To switch to the DIGEST mode, E-mail to <[hidden email]>
>>> >>>To switch to the INDEX mode, E-mail to <[hidden email]>
>>> >>>Send administrative queries to  <[hidden email]>
>>> >>>
>>> >>>
>>> >>>
>>> >>
>>> >>
>>> >>#############################################################
>>> >>This message is sent to you because you are subscribed to
>>> >> the mailing list <[hidden email]>.
>>> >>To unsubscribe, E-mail to: <[hidden email]>
>>> >>To switch to the DIGEST mode, E-mail to <[hidden email]>
>>> >>To switch to the INDEX mode, E-mail to <[hidden email]>
>>> >>Send administrative queries to  <[hidden email]>
>>> >>
>>> >>
>>> >
>>> >
>>> >
>>> >--
>>> >Mvh
>>> >Johan Sölve
>>> >____________________________________
>>> >Montania System AB
>>> >Halmstad   Stockholm   Malmö
>>> >http://www.montania.se
>>> >
>>> >Johan Sölve
>>> >Mobil +46 709-51 55 70
>>> >[hidden email]
>>> >
>>> >Kristinebergsvägen 17, S-302 41 Halmstad, Sweden
>>> >Telefon +46 35-136800 |  Fax +46 35-136801
>>> >
>>> >#############################################################
>>> >This message is sent to you because you are subscribed to
>>> > the mailing list <[hidden email]>.
>>> >To unsubscribe, E-mail to: <[hidden email]>
>>> >To switch to the DIGEST mode, E-mail to <[hidden email]>
>>> >To switch to the INDEX mode, E-mail to <[hidden email]>
>>> >Send administrative queries to  <[hidden email]>
>>> >
>>> >
>>> >
>>>
>>>
>>> #############################################################
>>> This message is sent to you because you are subscribed to
>>>  the mailing list <[hidden email]>.
>>> To unsubscribe, E-mail to: <[hidden email]>
>>> To switch to the DIGEST mode, E-mail to <[hidden email]>
>>> To switch to the INDEX mode, E-mail to <[hidden email]>
>>> Send administrative queries to  <[hidden email]>
>>>
>>
>>-- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
>>Steve Piercy               Web Site Builder               Soquel, CA
>><[hidden email]>                  <http://www.StevePiercy.com/>
>>
>>
>>#############################################################
>>This message is sent to you because you are subscribed to
>> the mailing list <[hidden email]>.
>>To unsubscribe, E-mail to: <[hidden email]>
>>To switch to the DIGEST mode, E-mail to <[hidden email]>
>>To switch to the INDEX mode, E-mail to <[hidden email]>
>>Send administrative queries to  <[hidden email]>
>>
>>
>
>
>

-- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
-- --
Steve Piercy               Web Site Builder              
Soquel, CA
<[hidden email]>                  <http://www.StevePiercy.com/>


#############################################################
This message is sent to you because you are subscribed to
  the mailing list <[hidden email]>.
To unsubscribe, E-mail to: <[hidden email]>
To switch to the DIGEST mode, E-mail to <[hidden email]>
To switch to the INDEX mode, E-mail to <[hidden email]>
Send administrative queries to  <[hidden email]>