locked
Need help in log files RRS feed

  • Question

  • We have a project and we need to monitor the log files for remote multiple server. Think that we have server and in that we have two server 192.47.155.300 and 192.47.155.250. 

    In 192.47.155.300 server we have the database connected. We need to connect the 192.47.155.250 server from 192.47.155.300 and open the access.log file and fetch the information from that log file and store it in database.

    We have the permission to access the log file and enter into the server as we can do ssh.

    Now we are using php command:     shell_exec(cat /var/log/apache2/access.log) with this command i am able to get the log file of 192.47.155.300 as the code is running in this server. Please tell me a way to access the 192.47.155.250 server log file using php.

     

    Thanks in advance

    Sunday, May 29, 2011 2:34 PM