Advertisement
petermolnar

tumblr-crosspostr-ok

Apr 8th, 2014
45
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 5.97 KB | None | 0 0
  1. POST /v2/blog/tumblr.petermolnar.eu/post/edit HTTP/1.1
  2. Host: api.tumblr.com
  3. User-Agent: PHP-OAuth-API (http://www.phpclasses.org/oauth-api $Revision: 1.83 $)
  4. Accept: */*
  5. Authorization: OAuth oauth_consumer_key="KEY",oauth_nonce="NONCE",oauth_signature_method="HMAC-SHA1",oauth_timestamp="1396908388",oauth_version="1.0",oauth_token="SsmEfOJVW2Gpm8RsP5GYVdOm3c03sKjfx1TaODBIUuPLufb8Vs",type="text",state="published",tags="linux%2Clog%2Cnginx%2C",date="2014-04-02%2016%3A08%3A32%20GMT",format="html",slug="log-nginx-to-rsyslog",source_url="https%3A%2F%2Fpetermolnar.eu%2Flinux-tech-coding%2Flog-nginx-to-rsyslog%2F",title="logging%20nginx%20to%20rsyslog",body="%3Cp%3EI%20wanted%20to%20test%20the%20mainline%201.5.12%20version%20of%20nginx%2C%20but%20it%20turned%20out%20that%20the%20%3Ca%20href%3D%22https%3A%2F%2Fgithub.com%2Fyaoweibin%2Fnginx_syslog_patch%22%3Enginx_syslog_patch%3C%2Fa%3E%20I%20was%20using%20for%20a%20while%20is%20not%20compatible%20with%20it.%3Cbr%20%2F%3E%0AI%20also%20read%20upon%20why%20nginx%20still%20refuses%20to%20have%20a%20built-in%20syslog%20module%3A%20the%20reason%20is%20that%20syslog%20blocks%20until%20the%20message%20is%20written%20to%20disk%20and%20nginx%20would%20become%20much%20less%20responsive.%3C%2Fp%3E%0A%3Cp%3ESo%20I%20needed%20to%20look%20upon%20the%20other%20possibilities%20of%20rsyslog%2C%20and%20I%26%238217%3Bve%20come%20across%20with%20the%20imfile%20module.%20This%20is%20basically%20a%20copy%20from%20file%20in%20rsyslog%2C%20so%20to%20use%20it%20with%20nginx%2C%20this%20is%20all%20I%20need%3A%3C%2Fp%3E%0A%3Cp%3EAdd%20%3C%2Fp%3E%0A%3Cpre%20class%3D%22line-numbers%22%3E%3Ccode%20class%3D%22language-bash%22%3E%24ModLoad%20imfile%3C%2Fcode%3E%3C%2Fpre%3E%0A%3Cp%3Eto%20%60%2Fetc%2Frsyslog.conf%60%20somewhere%20before%20the%20%60%24IncludeConfig%20%2Fetc%2Frsyslog.d%2F%2A.conf%60%20line.%3C%2Fp%3E%0A%3Cp%3ECreate%20%60%2Fetc%2Frsyslog.d%2Fnginx.conf%60%20with%3A%3C%2Fp%3E%0A%3Cpre%20class%3D%22line-numbers%22%3E%3Ccode%20class%3D%22language-bash%22%3E%23%20error%20log%0D%0A%24InputFileName%20%2Fvar%2Flog%2Fnginx%2Ferror.log%0D%0A%24InputFileTag%20nginx%3A%0D%0A%24InputFileStateFile%20stat-nginx-error%0D%0A%24InputFileSeverity%20error%0D%0A%24InputFileFacility%20local6%0D%0A%24InputFilePollInterval%201%0D%0A%24InputRunFileMonitor%0D%0A%0D%0A%23%20access%20log%0D%0A%24InputFileName%20%2Fvar%2Flog%2Fnginx%2Faccess.log%0D%0A%24InputFileTag%20nginx%3A%0D%0A%24InputFileStateFile%20stat-nginx-access%0D%0A%24InputFileSeverity%20notice%0D%0A%24InputFileFacility%20local6%0D%0A%24InputFilePollInterval%201%0D%0A%24InputRunFileMonitor%3C%2Fcode%3E%3C%2Fpre%3E%0A%3Cp%3ERestart%20rsyslog.%3C%2Fp%3E%0A%3Cp%20class%3D%22tumblr-crosspostr-linkback%22%3E%3Ca%20href%3D%22https%3A%2F%2Fpetermolnar.eu%2Flinux-tech-coding%2Flog-nginx-to-rsyslog%2F%22%20title%3D%22Go%20to%20the%20original%20post.%22%20rel%3D%22bookmark%22%3Elogging%20nginx%20to%20rsyslog%3C%2Fa%3E%20was%20originally%20published%20on%20%3Ca%20href%3D%22https%3A%2F%2Fpetermolnar.eu%22%3EP%C3%A9ter%20Moln%C3%A1r%20Portfolio%20%26amp%3B%20Blog%3C%2Fa%3E%3C%2Fp%3E",tweet="off",id="81494577133",oauth_signature="8YUPH49H8hWk8Tz6cGEECXyTDQs%3D"
  6. Connection: Keep-Alive
  7. Content-Type: application/x-www-form-urlencoded
  8. Content-Length: 2391
  9.  
  10. type=text&state=published&tags=linux%2Clog%2Cnginx%2C&date=2014-04-02+16%3A08%3A32+GMT&format=html&slug=log-nginx-to-rsyslog&source_url=https%3A%2F%2Fpetermolnar.eu%2Flinux-tech-coding%2Flog-nginx-to-rsyslog%2F&title=logging+nginx+to+rsyslog&body=%3Cp%3EI+wanted+to+test+the+mainline+1.5.12+version+of+nginx%2C+but+it+turned+out+that+the+%3Ca+href%3D%22https%3A%2F%2Fgithub.com%2Fyaoweibin%2Fnginx_syslog_patch%22%3Enginx_syslog_patch%3C%2Fa%3E+I+was+using+for+a+while+is+not+compatible+with+it.%3Cbr+%2F%3E%0AI+also+read+upon+why+nginx+still+refuses+to+have+a+built-in+syslog+module%3A+the+reason+is+that+syslog+blocks+until+the+message+is+written+to+disk+and+nginx+would+become+much+less+responsive.%3C%2Fp%3E%0A%3Cp%3ESo+I+needed+to+look+upon+the+other+possibilities+of+rsyslog%2C+and+I%26%238217%3Bve+come+across+with+the+imfile+module.+This+is+basically+a+copy+from+file+in+rsyslog%2C+so+to+use+it+with+nginx%2C+this+is+all+I+need%3A%3C%2Fp%3E%0A%3Cp%3EAdd+%3C%2Fp%3E%0A%3Cpre+class%3D%22line-numbers%22%3E%3Ccode+class%3D%22language-bash%22%3E%24ModLoad+imfile%3C%2Fcode%3E%3C%2Fpre%3E%0A%3Cp%3Eto+%60%2Fetc%2Frsyslog.conf%60+somewhere+before+the+%60%24IncludeConfig+%2Fetc%2Frsyslog.d%2F%2A.conf%60+line.%3C%2Fp%3E%0A%3Cp%3ECreate+%60%2Fetc%2Frsyslog.d%2Fnginx.conf%60+with%3A%3C%2Fp%3E%0A%3Cpre+class%3D%22line-numbers%22%3E%3Ccode+class%3D%22language-bash%22%3E%23+error+log%0D%0A%24InputFileName+%2Fvar%2Flog%2Fnginx%2Ferror.log%0D%0A%24InputFileTag+nginx%3A%0D%0A%24InputFileStateFile+stat-nginx-error%0D%0A%24InputFileSeverity+error%0D%0A%24InputFileFacility+local6%0D%0A%24InputFilePollInterval+1%0D%0A%24InputRunFileMonitor%0D%0A%0D%0A%23+access+log%0D%0A%24InputFileName+%2Fvar%2Flog%2Fnginx%2Faccess.log%0D%0A%24InputFileTag+nginx%3A%0D%0A%24InputFileStateFile+stat-nginx-access%0D%0A%24InputFileSeverity+notice%0D%0A%24InputFileFacility+local6%0D%0A%24InputFilePollInterval+1%0D%0A%24InputRunFileMonitor%3C%2Fcode%3E%3C%2Fpre%3E%0A%3Cp%3ERestart+rsyslog.%3C%2Fp%3E%0A%3Cp+class%3D%22tumblr-crosspostr-linkback%22%3E%3Ca+href%3D%22https%3A%2F%2Fpetermolnar.eu%2Flinux-tech-coding%2Flog-nginx-to-rsyslog%2F%22+title%3D%22Go+to+the+original+post.%22+rel%3D%22bookmark%22%3Elogging+nginx+to+rsyslog%3C%2Fa%3E+was+originally+published+on+%3Ca+href%3D%22https%3A%2F%2Fpetermolnar.eu%22%3EP%C3%A9ter+Moln%C3%A1r+Portfolio+%26amp%3B+Blog%3C%2Fa%3E%3C%2Fp%3E&tweet=off&id=81494577133HTTP/1.1 200 OK
  11. Server: nginx
  12. Date: Mon, 07 Apr 2014 22:06:30 GMT
  13. Content-Type: application/json; charset=utf-8
  14. Transfer-Encoding: chunked
  15. Connection: close
  16. Vary: Accept-Encoding
  17. Set-Cookie: tmgioct=53432165dfbab00294695660; expires=Thu, 04-Apr-2024 22:06:29 GMT; path=/; httponly
  18. P3P: CP="ALL ADM DEV PSAi COM OUR OTRo STP IND ONL"
  19. X-UA-Compatible: IE=Edge,chrome=1
  20.  
  21. 40
  22. {"meta":{"status":200,"msg":"OK"},"response":{"id":81494577133}}
  23. 0
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement