httpd log of the specified file type is not logged

Source: Internet
Author: User

In a large number of visits to the site, some access to the log can not be recorded, Chip js,css
Method One: Logformat "%h%l%u%t \"%r\ "%>s%b \"%{referer}i\ "\"%{user-agent}i\ "" Combinedlogformat "%h%l%u%t \"%r\ "%&gt ; s%b "Commonlogformat"%{referer}i,%u "Refererlogformat"%{user-agent}i "agent  and later add-on file type   setenvif Req Uest_uri \.gif$ gif-image  setenvif request_uri \. gif$ gif-image  setenvif request_uri \.jpg$ gif-image  setenvif request_uri \. jpg$ gif-image  setenvif request_uri \.png$ gif-image  setenvif request_uri \.js$ gif-image  SetEnvIf Requ Est_uri \.bmp$ gif-image  setenvif request_uri \.css$ gif-image  setenvif Request_URI \.mid$ gif-image  Se Tenvif Request_uri \.swf$ gif-image  setenvif request_uri \.mmf$ gif-image  SetEnvIf Request_URI \.wma$ Gif-ima ge  setenvif Request_uri \.midi$ gif-image  diary   Customlog/usr/local/apache/logs/access.log combined Env=!gif-image method Two: <virtualhost *:80>        documentroot/data/web/         ServerName www.test.com        setenvif Request_URI ". *\.gif$" image-request        setenvif Request_uri ". *\.jpg$" image-request         setenvif Request_uri ". *\.png$" image-request         Setenvif Request_uri ". *\.bmp$" image-request        SetEnvIf Request_URI " . *\.swf$ "image-request        setenvif request_uri". *\.js$ "Image-request         setenvif Request_uri ". *\.css$" image-request         Customlog "/logs/access.log" combined env=!image-request</virtualhost>
Description: Likethe name of the image-request can be defined by itself

From for notes (Wiz)

httpd log of the specified file type is not logged

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.