[ZendTo] Re: Large Files and Rebuilding libphp5.so

Brian Ott Brian.Ott at oicr.on.ca
Mon Jan 9 15:34:15 GMT 2012


On Sun, Jan 08, 2012 at 04:09:50PM +0000, Jules wrote:
> 
> 
> On 06/01/2012 20:05, Brian Ott wrote:
> > I ended up just going with CentOS 5 It just became way too much
> > trouble trying to rebuild php5. I'm not sure 100% what debian is doing
> > but it builds fine but I just get those issues happening. Even after I
> > played with applying patchs and such.
> >
> > CentOS 5 is working good now, but I do see one issue. I tested
> > uploading a file 4.2 G and it worked but when I look at the "Drop
> > Offs" the file size is incorrect. It shows a file size of 164 MB in the
> > Global Indox list.
> Note down the ClaimID for that dropoff. Then look in 
> /var/zendto/dropoffs and find the directory named the same as that 
> ClaimID. Then in there you should see a randomly named file which is the 
> file they dropped off. Is that file 4.2G or 164MB in size? And if it's 
> roughly 4.2G then *exactly* how big is it? If it's 4.2G then it uploaded 
> fine and somehow it is reporting the wrong size. If it's only 164MB then 
> that's all that got uploaded.

a du -sh on the directory returns a full 6.8G 


> 
> You should be able to run ZendTo fine on CentOS 6, that's what I do. 
> CentOS 5 is not the latest any more. Heaven only knows what Debian was 
> doing, I don't officially support it at all, sorry.
> 
> Jules.
> 
> >
> > On Thu, Jan 05, 2012 at 01:05:10PM -0500, Brian Ott wrote:
> >> On Thu, Jan 05, 2012 at 03:54:49PM +0000, Jules wrote:
> >>>
> >>> On 05/01/2012 15:30, Brian Ott wrote:
> >>>> On Thu, Jan 05, 2012 at 09:07:52AM +0000, Jules wrote:
> >>>>> On 04/01/2012 22:29, Brian Ott wrote:
> >>>>>> Hey Jules,
> >>>>>>
> >>>>>> As a test I went ahead and followed these steps:
> >>>>>> http://zend.to/phpfix.php
> >>>>>>
> >>>>>> I started from fresh the only thing I did NOT do was alter the fix:
> >>>>>>
> >>>>>> perl -i -pe 's/int zend_atoi/long zend_atoi/'
> >>>>>> Zend/zend_operators.[ch];
> >>>>>> perl -i -pe 's/\n/@@@@@@/g' Zend/zend_operators.c;
> >>>>>> perl -i -pe 's/(long zend_atoi.*?)int retval/$1long retval/m'
> >>>>>> Zend/zend_operators.c;
> >>>>>> perl -i -pe 's/@@@@@@/\n/g' Zend/zend_operators.c;
> >>>>>> perl -i -pe 's/atoi\(content_length\)/atol(content_length)/' `find
> >>>>>> sapi -name '*.c'`
> >>>>>> perl -i -pe 's/\(uint\)( SG\(request_info\))/$1/' `find sapi -name
> >>>>>> '*.c'`;
> >>>>>> perl -i -pe 's/uint post_data_length, raw/uint
> >>>>>> IGNORE_post_data_length, IGNORE_raw/' main/SAPI.h;
> >>>>>> perl -i -pe 's/} sapi_request_info/\tlong post_data_length,
> >>>>>> raw_post_data_length;\n} sapi_request_info/' main/SAPI.h;
> >>>>>> perl -i -pe 's/int read_post_bytes/long read_post_bytes/'
> >>>>>> main/SAPI.h;
> >>>>>> perl -i -pe 's/int boundary_len *= *0, *total_bytes *= *0/long
> >>>>>> total_bytes=0; int boundary_len=0/' main/rfc1867.c;
> >>>>>> perl -i -pe 's/int max_file_size *= *0,/long max_file_size = 0; int /'
> >>>>>> main/rfc1867.c;
> >>>>>>
> >>>>>> I left that part out to make sure it wasn't something with Debians
> >>>>>> version of PHP. Anyways I ran through and everything worked. I copied
> >>>>>> over the libphp5.so file and tried to dropoff a file, everything went
> >>>>>> well except of course the 4G file I uploaded failed.
> >>>>> Well it would. You've just built the file you already had.
> >>>>>> So I suspect something within these edits is the problem, I remember
> >>>>>> someone once asked you on this list before where you got this and you
> >>>>>> said to check google. I tried looking but with no success. I'm going
> >>>>>> to try and do it manually and see what happens.
> >>>>> It's possible the PHP source has changed again so one of the patterns is
> >>>>> failing to match. Exactly what version of PHP are you trying to do it
> >>>>> with? Does Ubuntu use the same version now?
> >>>>>
> >>>>> Jules.
> >>>> I just checked Ubuntu 10.10 uses PHP5 5.3.3
> >>>> Ubuntu 10.04 uses PHP5 5.3.2
> >>>> Ubuntu 11.04 uses PHP5 5.3.5
> >>>>
> >>>> Debian 6 (Squeeze) uses PHP5 5.3.3
> >>>>
> >>>> So in theory the notes for Ubuntu 10 should be dead on accurate.
> >>> But only for 10.04 and not 10.10. Sounds like the code has changed since
> >>> 5.3.2. I *might* get around to taking a look at this problem at the
> >>> weekend. I'll need to install an Ubuntu 11.04 box to build it with.
> >>>
> >>> Jules
> >> I think I've found the issue:
> >>
> >> Applying patch CVE-2011-2202.patch
> >> patching file main/rfc1867.c
> >>
> >> Debian has a patch that re-writes the rfc1867 file that we alter, I'm
> >> going to edit that file and do a rebuild and let you know how it goes.
> >>
> >>> -- 
> >>> Julian Field MEng CITP CEng
> >>> www.Zend.To
> >>>
> >>> Follow me at twitter.com/JulesFM
> >>> PGP footprint: EE81 D763 3DB0 0BFD E1DC 7222 11F6 5947 1415 B654
> >>>
> >>> 'It's okay to live without all the answers' - Charlie Eppes, 2011
> >>> 'All programs have a desire to be useful' - Tron, 1982
> >>> 'That is the land of lost content,
> >>>    I see it shining plain,
> >>>    The happy highways where I went,
> >>>    And cannot come again.' - A.E. Houseman
> >>>
> >>> _______________________________________________
> >>> ZendTo mailing list
> >>> ZendTo at zend.to
> >>> http://mailman.ecs.soton.ac.uk/mailman/listinfo/zendto
> >> -- 
> >> Brian Ott
> >> Unix System Administrator
> >>
> >> Ontario Institute for Cancer Research
> >> MaRS Centre, South Tower
> >> 101 College Street, Suite 800
> >> Toronto, Ontario, Canada M5G 0A3
> >>
> >> Telephone:	647-260-7977
> >> Email:		brian.ott at oicr.on.ca
> >> www.oicr.on.ca
> >>
> >>
> >>
> >> This message and any attachments may contain confidential and/or privileged information for the sole use of the intended recipient. Any review or distribution by anyone other than the person for whom it was originally intended is strictly prohibited. If you have received this message in error, please contact the sender and delete all copies. Opinions, conclusions or other information contained in this message may not be that of the organization.
> >> _______________________________________________
> >> ZendTo mailing list
> >> ZendTo at zend.to
> >> http://mailman.ecs.soton.ac.uk/mailman/listinfo/zendto
> 
> Jules
> 
> -- 
> Julian Field MEng CITP CEng
> www.Zend.To
> 
> Follow me at twitter.com/JulesFM
> PGP footprint: EE81 D763 3DB0 0BFD E1DC 7222 11F6 5947 1415 B654
> 
> 'Teach a man to reason, and he will think for a lifetime.' - Phil Plait
> 'All programs have a desire to be useful' - Tron, 1982
> 
> _______________________________________________
> ZendTo mailing list
> ZendTo at zend.to
> http://mailman.ecs.soton.ac.uk/mailman/listinfo/zendto

-- 
Brian Ott
Unix System Administrator

Ontario Institute for Cancer Research
MaRS Centre, South Tower
101 College Street, Suite 800
Toronto, Ontario, Canada M5G 0A3

Telephone:	647-260-7977
Email:		brian.ott at oicr.on.ca
www.oicr.on.ca



This message and any attachments may contain confidential and/or privileged information for the sole use of the intended recipient. Any review or distribution by anyone other than the person for whom it was originally intended is strictly prohibited. If you have received this message in error, please contact the sender and delete all copies. Opinions, conclusions or other information contained in this message may not be that of the organization.


More information about the ZendTo mailing list