Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Search results for query: *

  1. talisker123gjs

    Trapping a process crash

    Hello I am aware of the "trap" command to trap various signals. I am running a shell script as a daemon. In case this daemon crashes for some reason, I wish to trap the relevant signal and echo some information into a file. Which signal do I need to trap when my daemon simply crashes...
  2. talisker123gjs

    crontab question

    As an addendum to the above post, if yo cron job is generating errors/output that you can safely ignore, then you can change the redirection of output and errors to /dev/null . When setting up a cron job, it is good practice to redirect output and errors to different files. Ideally these...
  3. talisker123gjs

    crontab question

    gfunk123 A cron job sends only errorsto the mailbox. So, if yo mailbox id filling up, then yo cron job may be generating errors mate. Redirect output and error to separate files and check them after cron job is executed. something like... 10 10 * * * $HOME/somescript.sh > $HOME/somescript.log...
  4. talisker123gjs

    Disabling Anonomous Users in FTP

    Check your /etc/passwd file. You may have an entry for the anonymous ftp user like the one below: ============ ftp:*:9922:90:Anonymous FTP:: ============ Remove the above line and add a new user to the system. The new user can be used for FTP....or any other existing user can be used.
  5. talisker123gjs

    Deleting files??? files that seem to exist and not exist

    As an addendum to the above post, The command 'set -o noglob' turns off globbing (file name generation). The command 'set +o noglob' turns on globbing. For more details, refer to 'man set' Hope this helps ya.
  6. talisker123gjs

    Deleting files??? files that seem to exist and not exist

    Chrissirhc Can you please list the output of the `ls -lt | grep PDF` command ? Also, which shell are you using ? If you are using the ksh shell, then your noglob option must be turned on. Try using `set +o noglob` and then re-execute your commands above. Hope this helps ya.
  7. talisker123gjs

    Adding options to a script

    johngiggs Try the following: =========================================== #!/bin/ksh if [ "$1" = "help" -o "$1" = "-h" ]; then echo "\nHELP\n==========\n" echo "Help commands" else exit 1 fi...
  8. talisker123gjs

    how to call a file dynamically in shell script

    navink123 Let's assume that your input files that are generated daily (eg. abc20030826123) are stored in a directory called /dailydata. If your shell script needs to refer to a file generated in /dailydata on that day, then use the following in your shell script : ============================...
  9. talisker123gjs

    Checking FTP connectivity to remote host

    marsd I have worked on Applications such as CONNECT DIRECT and XFB.CFT for doing FTP stuff. These applications provide secure FTP and good error-trapping. However, for certain reasons, I was asked to use a shell script and hence I wanted to know if there're any error trapping mechanisms in...
  10. talisker123gjs

    Checking FTP connectivity to remote host

    Hi If I try to ftp an invalid IP address, I get no result (which is obvious) and the command seems to be hanging. HOW DO I TRAP THIS KIND OF ERROR ? For eg., I am using FTP in a "here" document within a shell script. If the remote system isn't available or if there is a network...
  11. talisker123gjs

    To get rid of special characters in filenames

    As per your example, if you have files with names like filename[1].jpg and you want to strip off the '[1]', then you can try the following script : ========================= #!/bin/ksh for i in `ls *\[*\].jpg` do mv $i `echo ${i%%\[*\]*}.jpg` done ========================== Hope this helps ya !
  12. talisker123gjs

    how to write a script remove files older than 5 days?

    To remove files older than 5 days, you can run the following command in the directory containing the files to be removed : find . -type f -mtime +5 | xargs rm -f
  13. talisker123gjs

    Hello I am trying to connect to my

    Hello I am trying to connect to my company's VPN via DSL. I'm using the Avaya VPN Remote Client (Windows 2000 Pro). When I try to connect to my VPN, I get the following errors: VPNremote is unable to contact it's Virtual Adapter. It can not continue. See More Details for troubleshooting. More...
  14. talisker123gjs

    find and executing tar

    Chrissirhc, A .tar file is an archive file and a .Z file is a compressed file. The 'zcat' command is used to print out the contents of a compresed text file. The 'tar tvf' command lists the contents of a TAR archive. So, keeping the above in mind, what do you wanna do ?

Part and Inventory Search

Back
Top