I have Apache HTTP server configured on Linux machine. I am sending requests to it from my Windows machine. I want to check the contents of incoming request. Where does it stores the data of incoming request? I think on Windows machine it uses C:\Users\username\AppData\Local\Temp file for this. I have looked into /var/tmp folder on Linux machine but all files in that folder are empty.
I have a json web service developed using web2py framework and it is hosted on Apache HTTP server on Linux machine. It has get_tkn web service which I am trying to access from Python shell.
import jsonrpclib
import json
server_url = 'http://ip_address/appname/controllername/call/jsonrpc/'
api = jsonrpclib.Server(server_url)
tk_request = {
'header' : {
'a_id':u'f23ew343',\
'a_key':u'ldddk333k444d4',
'r_id':'12345',
't_id':'mec','uip_address':'someipaddr',
'tkn':''
},
'body' : {'prms' :{}}
}
api.get_tkn(tk_request)
It logs all the incoming requests or any errors that occur. To view the log live in your Linux terminal use the following command
tail -f /var/log/apache2/other_vhosts.access.log
The location and the name of the log file depends on your linux distribution. Under debian/ubuntu it is /var/log/apache2 and on centos/fedora it is /var/log/httpd folder. After the command above, send your requests from windows and view the live logs in your linux terminal.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With