![]() |
Hello and Welcome from United States to the UNIX and Linux Forums! Thank You for Visiting and Joining Our Global Community.
|
|
google unix.com
|
|||||||
| Forums | Register | Forum Rules | Links | Albums | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| Shell Programming and Scripting Post questions about KSH, CSH, SH, BASH, PERL, PHP, SED, AWK and OTHER shell scripts and shell scripting languages here. |
More UNIX and Linux Forum Topics You Might Find Helpful
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Changing Creation Date to a Prespecified Date of a File In Unix | monkfan | UNIX for Dummies Questions & Answers | 4 | 11-28-2006 07:15 AM |
| Displaying file names before a particular creation date | dhruv_saksena | UNIX for Dummies Questions & Answers | 1 | 09-02-2005 08:19 AM |
| file creation date & time | alisevA3 | UNIX for Dummies Questions & Answers | 3 | 07-08-2005 05:21 AM |
| file creation date including seconds | krishna | UNIX for Advanced & Expert Users | 7 | 08-26-2002 08:45 AM |
| Converting the File Creation Date to a new format | barney_clough | UNIX for Dummies Questions & Answers | 1 | 06-12-2002 07:43 AM |
![]() |
|
|
LinkBack | Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|
|
||||
|
Creation of log file under dynamic date folder
HI
I want to create a date folder and then a log file under it, which will hold all output of shell script. Say shell script abc.sh runs every day and I want to redirect the output of abc.sh > /opt/bea/wls81/Pkmtest/$(date +%Y%m%d)/ant.log. Here date should always change according to system date and else everything should remain same. Thanks Pankaj |
|
||||
|
Is it not easier to have all the log files under the one directory and tag the date to the log file name? Otherwise you will end up with 365 directories all containg only one file of the same name? A little trouble some if you need to check back throgh history and look at put put details... etc etc
ie abc.sh > /opt/bea/wls81/Pkmtest/logs/ant_$(date +%Y%m%d).log |
![]() |
| Bookmarks |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|