Error reporting script


 
Thread Tools Search this Thread
Top Forums UNIX for Dummies Questions & Answers Error reporting script
# 1  
Old 05-16-2009
Error reporting script

I am very new to unix/linux and am unsure how to do the following tasks within my script

1) append a log file and add a timestamped echo "Error occured" to it, if posibble to print it to file and on screen at the same time would be even better.
2) As my main script will be calling on a couple of my other scripts I want to create a setup file so i can take my setup script from site to site and have it write the 2 or 3 scripts that it needs to. What command should i use to make the setup file write a section of script to a new file?
e.g. lines 5-8 to file called "login_script"

K thanks, i have probably asked some really easy questions so please forgive my noobness Smilie
# 2  
Old 05-19-2009
man tee
 
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. AIX

How to disable an error reporting ???

Hi A few days ago I attached an usb external disk to a server running AIX, then I removed it without typing any commands. Now, the server can't find the usb device and it keeps reporting the errors every 3 hours, like this 55479D40 0112080017 T H usbms0 ADDITIONAL INFORMATION... (2 Replies)
Discussion started by: bobochacha29
2 Replies

2. SCO

du and dfspace reporting

Hi, I am using SCO UNIX version 6.0.0 release 5. I am using du and df space to see the used space in the / partition. I am using du -k option to get count in 1024 k so that it directly makes kb. In dfspace I subtracted the used mb from total size mb which should be the used space and then... (40 Replies)
Discussion started by: dextergenious
40 Replies

3. OS X (Apple)

Software Update reporting script

I need a script that gets the output of softwareupdate -al on each machine (the list of available updates) and reports how many updates are needed in total by all the machines on the network, and the results to 4 different recipients. i.e. total patches required = 12 hostname1 =4 patch(es)... (1 Reply)
Discussion started by: glev2005
1 Replies

4. UNIX for Advanced & Expert Users

reporting NS-12564 error as ORA-12564

Hi My client connection to RAC Oracle Release 10.2.0.4.0 database suddenly stopped working. ACPT_1 - works but not with OEM. ACPT_2 - does not work at all. Getting error ORA-12564: TNS:connection refused Any ideas very much appreciated Thanks ACPT_1 = (DESCRIPTION = ... (4 Replies)
Discussion started by: zam
4 Replies

5. Shell Programming and Scripting

Script for checking and reporting file sizes in a directory.

Hi, Need help for a Script for checking and reporting database file sizes in a directory. Request you to please give your valuable inputs. Thanks a lot in advance. Best Regards, Marconi (1 Reply)
Discussion started by: marconi
1 Replies

6. Shell Programming and Scripting

Script for reporting network printers

Does anyone have a script that would detect (and create a flat-file) of all printing devices (printers/plotters) attached on a network? I need a single script or tool that would allow me to collect a data file for our asset management tool. Example format: manufacturer, model name, serial... (0 Replies)
Discussion started by: glefko
0 Replies

7. Shell Programming and Scripting

Reporting SU and Failedlogins

Hi:- I am working on an audit report that produces a monthly summary of account activity on a particular AIX host. I am struggling with su activity and failed logins as these tend to come back with more then a month's data. Is there a easy way that these files can be rotated/cleaned out on a... (1 Reply)
Discussion started by: janet
1 Replies

8. Shell Programming and Scripting

Question about error reporting

hi all, i've got a script that takes in what a user enters (multiple entries) and then joins them all together and appends this to a file. what i want to happen now is the terminal should display "record saved" if the save to the file is successful, if it isn't just display the standard unix... (2 Replies)
Discussion started by: wazzag
2 Replies

9. UNIX for Dummies Questions & Answers

Progress reporting

Hi everyone, I'm completely new to the board and to UNIX and I have the following question regarding a script I am building. I am trying to copy an entire directory into a new directory and I was wondering if there is any way of printing on screen a progress report, for example a percentage. It... (9 Replies)
Discussion started by: Ypnos
9 Replies

10. UNIX for Dummies Questions & Answers

Reporting

I have to do a lot of reporting for the company that I work for and was wondering if anyone had suggestions for a way to create professional looking reports. I currently use Filepro so much that I rarely see the shell. Any help is appreciated. (3 Replies)
Discussion started by: Mike11
3 Replies
Login or Register to Ask a Question