in reply to LWP file size

Have you checked that the size of the content before writing it to the file matches the size that the web server tells you?

say length $response->content(); say $response->header("Content-Length");

Also have a look at the ->add_handler method to add a progress callback so you see where in the HTTP processing you are.