Need a Log File for Application
Hi Team,
We are using an application to send the bulk mails. Need to start/stop the application manually. But we don't have any log files. Could you please advise is it possible to create a log file for any particular application through script? That is who is starting/stoping the application and that one has to capture in that log file. Please check and advise. Thanks, Srikanth.V |
Does this application have not got any log file of its own. Instead of creating a script I would suggest that you allow stop / start of this application via sudo. You can then have sudo.log to monitor who is starting / stopping / restarting this application.
Make sure that users are not allowed to restart the application without using sudo. |
Hi,
1. We dont have sudo option for the start/stop the script. 2. It doesn't have any log file of its own. Sometimes the application will stop automatically or someone stop it. Then we'll get an alert to start the applciation and Client will ask the reason how it got stopped. Without log file we are not able to find the "Root Cause". If the script is running to capture to the logs for that applcation, then it will help us to find the Root Cause easily. "For Example: In IBM Websphere we have a log file. It will throw all types of Errors. With the help of that we can easily find the Root Cause." Sameway is there any possible way to create a script to find the results. I'm new to Linux. So please help me. Thanks a lot in advance. Regdars, Srikanth.V |
By script you cannot do logging. I mean you can have a script to check if application is running or not. You can have a script to track when the application went down but what you are looking for is detailed log which I don't think is possible via script.
By default application should have the log if it does not have a log then atleast application should have option to send warnings or errors to standard system log. You have to check with the team who developed this application. Ask them if they have any switch or option to generate the log for the application. |
Hi T3RM1NVT0R,
Thanks for breif explanation. Could you please provide the script which is used to track when the application went down. Might it will helpful for me. Thanks, Srikanth.V |
Quote:
Also, you provide no real details..you say "an application", but don't tell us which one. You don't say what version/distro of Linux, what kind of environment, etc. Also, you're probably not going to find a lot of people willing to help someone shovel out bulk emails...no one likes spam. |
Quote:
What you should be looking at is a script which can check the exit status of the command used to check the script status. You can configure the script to do that every second and you can add it to crontab to run every minute. This pointer should be good enough to give you an idea on how you have to write it. |
All times are GMT -5. The time now is 06:21 AM. |