Apache2 log file names

I'm running Mac OS X Server 10.6.4, and have 3 web sites that all resolve to the same IP number. All is working just fine except for naming the log files. I'd like to have separate files for each virtual site; that is, traffic to example1.com should go to /var/log/apache2/example1_access)log, traffic to example2.com should go to /var/log/apache2/example2accesslog, etc. I set this up in server admin, but the names of the actual log files are something like example1accesslog.1287014400 and example2accesslog.1286409600.
This causes problems in having my web usage program finding the correct file. Can anyone point me to relevant documentation on how to solve this problem?

The timestamps on the files are related to the fact you have log file rotation turned on.
As for how to solve it that depends a lot on the analytics program you're using, which you omit to mention.
You could turn off the log file rotation, but then you'd have issues with ever-growing log files
You could rename the logs files yourself
You could teach the analytics program to understand your log file names (this is the approach I'd take - rotating logs is VERY common and I can't think there's an analytics that doesn't handle it)

Similar Messages

  • In R12 how to change concurrent output/log file name prefix?

    how to change concurrent output/log file name prefix?

    but i want to change change concurrent output/log file name prefix?You cannot, and I believe it is not supported for all concurrent requests -- Please log a SR to confirm this with Oracle support.
    Thanks,
    Hussein

  • How to add a date suffix to the log file name

    In Windows, I want to run certain commands and save the output to a logfile every day. How to add a suffix to the log file name so I can distinguish which log file for which day?
    e.g. cmd >> logfile.date

    AZ wrote:
    In Windows, I want to run certain commands and save the output to a logfile every day. How to add a suffix to the log file name so I can distinguish which log file for which day?
    e.g. cmd >> logfile.datemy best friend name is "google", refer to this [url | http://stackoverflow.com/questions/203090/how-to-get-current-datetime-on-windows-command-line-in-a-suitable-format-for-usi]
    This is what i did
    1) created a dummy file in c drive
    2) copy pasted below lines, you can play around more with the format
    set _my_datetime=%date%_%time%
    set _my_datetime=%_my_datetime: =_%
    set _my_datetime=%_my_datetime::=%
    set _my_datetime=%_my_datetime:/=_%
    set _my_datetime=%_my_datetime:.=_%3) Rename the file from dos
    ren some.txt dummy_file_%_my_datetime%.txt4) Here goes the output
    C:\dir
    dummy_file_Mon_09_20_2010_161347_21.txt
    Most of the code i copied from above url, you can tweak a little bit based on ur requirement and format.
    Regards
    Learner                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   

  • Log File name and path to check Excel Download

    Hi ,
    When we download a report in Excel/PDF/HTML is it logged in any log file ? What is the log file name and path?
    Regards
    Anand

    Hi...
    one of my user tried to download the report in excel format. that excel was not opening. then he tried to download the same report again. this time he was able to open thee excel.
    So he wants to investigate why this happened first time. could you please suggest how we can investigate this?
    Regards
    Anand

  • How to using variable in log file name on ODI 10.1.3.5?

    Hi,
    how can i put a my variable into my log file name?
    now I use this syntax --> ExRate_<%=odiRef.getSysDate("MMddyyHHmm")%>.log.
    But I have a variable for example #server, the value = "oracleProd" and i want to put the variable value into my log file name.
    so the result that i want to get is --> ExRate_oracleProd_<%=odiRef.getSysDate("MMddyyHHmm")%>.log
    so how can I apply the variable value to my log file name? I try using odiRef.getSessionVarList(#Month) but it didn't work.
    Thanks.
    Regards,
    chris
    Edited by: 877142 on Aug 3, 2011 9:36 PM

    hi,
    You can by
    ExRate-#server-<%=odiRef.getSysDate("MMddyyHHmm")%>.log
    Note that I have changed the underscores to dashes. This is because ODI will assume that this is a wildcard/escape character.
    Hope this helps!!
    Bos

  • Export dump file and log file  name as sysdate in script

    Hi to All,
    Can anybody help me to give logical backup export dump file namd log file name is as contain sysdate in its name so that we can Uniquelly identified it.
    Regards
    DXB_DBA

    On windows it gets a bit hairy as there really is no clean and nice way of doing it.There are a couple of options.
    1. If you can rely on dateformat not changing, you can use a static substring expression. For example, the following might work w/ finnish locale echo %date:~3,2%%date:~6,2%%date:~9,4%Similarly, when you know the dateformat you can tokenize the output of 'date /t' and discard the tokens you don't want.
    2. You can set dateformat to your liking and then just use %date% in your script
    3. You can run a "SELECT to_char(sysdate,..." into a file and then read that file in your script.
    4. Simon Sheppard also has a solution you could use as a basis. I have a slight issue with the approach, but that could just be me.
    5. Use gnuwin32 or similar ;)
    Also note that %date% env var is set automatically from w2k onwards, so some of the solutions might not work w/ older versions.

  • Shell Script to grep Job File name and Log File name from crontab -l

    Hello,
    I am new to shell scripting. I need to write a shell script where i can grep the name of file ie. .sh file and log file from crontab -l.
    #51 18 * * * /home/oracle/refresh/refresh_ug634.sh > /home/oracle/refresh/refresh_ug634.sh.log 2>&1
    #40 17 * * * /home/oracle/refresh/refresh_ux634.sh > /home/oracle/refresh/refresh_ux634.sh.log 2>&1
    In crontab -l, there are many jobs, i need to grep job name like 'refresh_ug634.sh' and corresponding log name like 'refresh_ug634.sh.log '.
    I am thinking of making a universal script that can grep job name, log name and hostname for one server.
    Then, suppose i modify the refresh_ug634.sh script and call that universal script and echo those values when the script gets executed.
    Please can anyone help.
    All i need to do is have footer in all the scripts running in crontab in one server.
    job file name
    log file name
    hostname
    Please suggest if any better solution. Thanks.

    957704 wrote:
    I need help how to grep that information from crontab -l
    Please can you provide some insight how to grep that shell script name from list of crontab -l jobs
    crontab -l > cron.log -- exporting the contents to a file
    cat cron.log|grep something -- need some commands to grep that infoYou are missing the point. This forum is for discussion of SQL and PL/SQL questions. What does your question have to do with SQL or PL/SQL.
    It's like you just walked into a hardware store and asked where they keep the fresh produce.
    I will point out one thing about your question. You are assuming every entry in the crontab has exactly the same format. consider this crontab:
    #=========================================================================
    # NOTE:  If this is on a clustered environment, all changes to this crontab
    #         must be replicated on all other nodes of the cluster!
    # minute        (0 thru 59)
    # hour          (0 thru 23)
    # day-of-month  (1 thru 31)
    # month         (1 thru 12)
    # weekday       (0 thru 6, sunday thru saturday)
    # command
    #=========================================================================
    00 01 1-2 * 1,3,5,7 /u01/scripts/myscript01  5 orcl  dev
    00 04 * * * /u01/scripts/myscript02 hr 365 >/u01/logs/myscript2.lis
    00 6 * * * /u01/scripts/myscript03  >/u01/logs/myscript3.lisThe variations are endless.
    When you get to an appropriate forum (this on is not it) it will be helpful to explain your business requirement, not just your proposed technical solution.

  • Different log file name in the Control file of SQL Loader

    Dear all,
    I get every day 3 log files with ftp from a Solaris Server to a Windows 2000 Server machine. In this Windows machine, we have an Oracle Database 9.2. These log files are in the following format: in<date>.log i.e. in20070429.log.
    I would like to load this log file's data to an Oracle table every day and I would like to use SQL Loader for this job.
    The problem is that the log file name is different every day.
    How can I give this variable log file name in the Control file, which is used for the SQL Loader?
    file.ctl
    LOAD DATA
    INFILE 'D:\gbal\in<date>.log'
    APPEND INTO TABLE CHAT_SL
    FIELDS TERMINATED BY WHITESPACE
    TRAILING NULLCOLS
    (SL1 DATE "Mon DD, YYYY HH:MI:SS FF3AM",
    SL2 char,
    SL3 DATE "Mon DD, YYYY HH:MI:SS FF3AM",
    SL4 char,
    SL5 char,
    SL6 char,
    SL7 char,
    SL8 char,
    SL9 char,
    SL10 char,
    SL11 char,
    SL12 char,
    SL13 char,
    SL14 char,
    SL15 char)
    Do you have any better idea about this issue?
    I thought of renaming the log file to an instant name, such as in.log, but how can I distinguish the desired log file, from the other two?
    Thank you very much in advance.
    Giorgos Baliotis

    I don't have a direct solution for your problem.
    However if you invoke the SQL loader from an Oracle stored procedure, it is possible to dynamically set control\log file.
    # Grant previleges to the user to execute command prompt statements
    BEGIN
    dbms_java.grant_permission('bc4186ol','java.io.FilePermission','C:\windows\system32\cmd.exe','execute');
    END;
    * Procedure to execute Operating system commands using PL\SQL(Oracle script making use of Java packages
    CREATE OR REPLACE AND COMPILE JAVA SOURCE NAMED "Host" AS
    import java.io.*;
    public class Host {
    public static void executeCommand(String command) {
    try {
    String[] finalCommand;
    finalCommand = new String[4];
    finalCommand[0] = "C:\\windows\\system32\\cmd.exe";
    finalCommand[1] = "/y";
    finalCommand[2] = "/c";
    finalCommand[3] = command;
    final Process pr = Runtime.getRuntime().exec(finalCommand);
    new Thread(new Runnable() {
    public void run() {
    try {
    BufferedReader br_in = new BufferedReader(new InputStreamReader(pr.getInputStream()));
    String buff = null;
    while ((buff = br_in.readLine()) != null) {
    System.out.println("Process out :" + buff);
    try {Thread.sleep(100); } catch(Exception e) {}
    catch (IOException ioe) {
    System.out.println("Exception caught printing process output.");
    ioe.printStackTrace();
    }).start();
    new Thread(new Runnable() {
    public void run() {
    try {
    BufferedReader br_err = new BufferedReader(new InputStreamReader(pr.getErrorStream()));
    String buff = null;
    while ((buff = br_err.readLine()) != null) {
    System.out.println("Process err :" + buff);
    try {Thread.sleep(100); } catch(Exception e) {}
    catch (IOException ioe) {
    System.out.println("Exception caught printing process error.");
    ioe.printStackTrace();
    }).start();
    catch (Exception ex) {
    System.out.println(ex.getLocalizedMessage());
    public static boolean isWindows() {
    if (System.getProperty("os.name").toLowerCase().indexOf("windows") != -1)
    return true;
    else
    return false;
    * Oracle wrapper to call the above procedure
    CREATE OR REPLACE PROCEDURE Host_Command (p_command IN VARCHAR2)
    AS LANGUAGE JAVA
    NAME 'Host.executeCommand (java.lang.String)';
    * Now invoke the procedure with an operating system command(Execyte SQL-loader)
    * The execution of script would ensure the Prod mapping data file is loaded to PROD_5005_710_MAP table
    * Change the control\log\discard\bad files as apropriate
    BEGIN
    Host_Command (p_command => 'sqlldr system/tiburon@orcl control=C:\anupama\emp_join'||1||'.ctl log=C:\anupama\ond_lists.log');
    END;Does that help you?
    Regards,
    Bhagat

  • Common log file name for ESB

    What is the log file name which is logging all the informations of ESB?

    There are several
    The most common ones are :
    $OH$\soa\j2ee\home\log\home_default_group_1\oc4j\log.xml
    and
    $OH$\soa\bpel\domains\default\logs\domain.log

  • Adpatch default log file names-Raghuram Kotnana

    Does using of adpatch default log file names during patching makes it difficult to keep an accurate record of your patch history ?

    RaghuramKotnana wrote:
    Does using of adpatch default log file names during patching makes it difficult to keep an accurate record of your patch history ?
    It does make it difficult when you apply many patches and all are logged in the same patch log file. If you encounter issues applying patches while using the default adpatch.log name, it would be also harder to find the proper entries to grep and share with Oracle support.
    I would suggest you use the same patch driver name for the log file and replace .drv with .log (i.e. u<patch number>.log).
    Details about applied patches from your instance can be found in the tables in (Important tables used by and updated by ADPATCH utility (Doc ID 1520703.1)).
    You can also refer to eTRM website for details about each table -- http://etrm.oracle.com/
    Thanks,
    Hussein

  • RESTORE ARCHIVELOG ALL VALIDATE; - returns log file names

    Environment:
    Oracle 11.2.0.3 EE on Solaris 10.5
    RMAN using control file as repository.
    My archive logs are going to /arch/<SID>. During a time of unforeseen high activity the directory was filling up and some of the files had to be move to a different mount point. I have since done several Level 0 incremental backups including (plus) archivelogs.
    My RMAN archivelog deletion setting is: CONFIGURE ARCHIVELOG DELETION POLICY TO BACKED UP 1 TIMES TO DISK;
    I have since begun to run more frequent archive log backups to keep the mount point cleaner.
    Since I have several successful Level 0 backups including archivelogs, I manually deleted the archived logs on the secondary mount point.
    I registered the logs in the secondary mount point using REGISTER ARCHIVELOG START IN '/xxxx';
    I then ran a CROSSCHECK ARCHIVELOG ALL; to update the control file repository.
    When I query the V$ARCHIVED_LOG view I see many entries for my deleted log files with a STATUS = 'X' (Expired) and a BACKUP_COUNT = 0.
    I ran DELETE EXPIRED ARCHIVELOG ALL;
    Now when I query the V$ARCHIVED_LOG view I see many entries with blank name column for the SEQUENCE# in my list and with a STATUS = 'D' (Deleted) and a BACKUP_COUNT = 0.
    When I run a RESTORE ARCHIVELOG ALL VALIDATE; it returns a long list of my deleted files with:
    RMAN-06025: no backup of archived log ... to restore
    OK, enough background. My question is how do I get RMAN to not look for my deleted files since I have several good backups?
    I realize my deletion policy says the files have to be backed up once to disk, which according to the V$ARCHIVED_LOG view they are not, but I was hoping since I ran the CROSSCHECK RMAN would not even be concerned with them.
    Many thanks for any advice!!
    -gary

    Thanks for the help! Square brackets! Doh!
    I changed the SQL just a bit. I have only one (1) thread and the primary database was running for several months before the standby was implemented so there are over 3500 sequence#'s in the V$ARCHIVED_LOG view for the Primary (DEST=1) that are not in the Standby (DEST=2).
    Here's the SQL I ran, using the SQUARE brackets! :-)
    SELECT SEQUENCE#
    FROM V$ARCHIVED_LOG
    WHERE DEST_ID=1
    MINUS
    SELECT SEQUENCE#
    FROM V$ARCHIVED_LOG
    WHERE DEST_ID=2It appears to me the Standby is accepting and applying the archived logs from the Primary based on looking at the most recent archived log sequence#'s.
    I'm just trying to get rid of the entries in the RESTORE ARCHIVELOG VALIDATE; command output.
    I don't have an RMAN Repository but am using the control files at the moment.
    Any other suggestions are very welcomed!!
    Thanks again!
    -gary

  • Dynamic bad and Log file names!!

    Hi

    Hi
    I have the scenario like the data files would be passed as parameter to the mapping , and the mapping would have the premapping procedure which would change the file name in the external table definition. This works fine. But the one more issue I have is that, I would like to change the bad file,log file and discard file name also through this procedure. In other words, for each incoming data file I would like to create a bad ,log and disc file.So How do I accomplish in the present procedure which does the following alter table statement
    execute immediate 'alter table '||p_table_name||' location('''
    ||p_file_name||''')';
    Any suggestion would be greatly appreciated
    Thanks
    Balaji

  • Log4j : how to get log file name and directory

    My log4j is working fine. Below is how I define the property file
    log4j.rootCategory=DEBUG, A1
    log4j.appender.A1=org.apache.log4j.RollingFileAppender
    log4j.appender.A1.layout=org.apache.log4j.PatternLayout
    log4j.appender.A1.layout.ConversionPattern=%d [%t] %-5p %c - %m%n
    log4j.appender.A1.File=temp/log.txtI want to know, from my java program, how to retrieve my log file "temp/log.txt" because I want to display at console and notify user where to find the log file.
    Thanks

    Or perhaps I did not understand your requirement. Which of the following is it?
    1. Given some Java class, you need to do something with its source code?
    2. Given some file whose path is specified by user input or runtime configuration or compile-time constant, you need to do something with that file?
    3. Neither of the above?
    If 1: Can't do it. Don't need to do it. Don't waste your time trying. Unless you're writing something like a debugger. If so, then if you have to ask this question, you do not have the skills necessary for the broader task.
    If 2: Google for java io tutorial. Study it, try some code, and come back with a more specific question if you're still confused.
    If 3: Explain clearly what you're trying to accomplish and why you think this approach is the right one.

  • What is the extension for debug log file name?

    Hi,
    1) Please let me know what is the extension for debug log file....
    is it .dbg or .log ?
    in one of the sr the service engineer asked to put .log as the extension is this correct?
    here is what he said...
    a) Enable the following Profiles at user level:
    OM: Debug Level = 5
    INV: Debug Trace = YES
    INV: Debug Level = 11
    INV: Debug File = [directory value from above query]/logfilename.log
    (make sure that you have write permission for this file and directory)
    WSH: Debug Enabled - Yes
    WSH: Debug Level - Statement
    2) do the end-user (for whom trace is enabled) need to have read and write permissions on the directory and the log file?
    Thanks
    Raju

    user652672 wrote:
    1) Please let me know what is the extension for debug log file....
    is it .dbg or .log ?
    INV: Debug File = [directory value from above query]/logfilename.log
    (make sure that you have write permission for this file and directory) It is what you set in the value of "INV: Debug File" profile option (according to the above value, it will be logfilename.log).
    2) do the end-user (for whom trace is enabled) need to have read and write permissions on the directory and the log file?No, just make sure the directory is writable by the oracle and applmgr users.

  • Changing log file name (weblogic.log)

     

    hi!
    maybe you could try putting this in the weblogic.properties file or the
    starscript shell:
    weblogic.system.logFile= [logfile name]
    Hope this helps!
    Mauricio

Maybe you are looking for

  • T61, OCZ Agility 3 doesn't fit in the HDD cage

    Hi all So, I finally bought myself an SSD for my old ThinkPad. Works wonderfully - except that it doesn't fit quite right.  The OCZ Agility 3 is slightly too wide for the HDD cage, on the bottom of the drive. Recall that the drive sits bottom side up

  • Stored proc returns zero result

    Hello, please help me. I am quite new to oracle stored procedures. I have a proc that returns data to cfm but it keeps giving zero results. But if i don't use stored proc, the same query gives me something. please help. my stored proc and cfm goes so

  • Help needed - weird behavior on 8300

    Hi, I have the Curve for about a month. Lately (for 3 days), the phone's acting weird. It lets me make calls and all of a sudden, it turns itself off. Initially, I thought that the phone may not have enough charge; but today it happened again about 4

  • User Authentication for Internet access

    Hi, Is it possible to configure authentication for internal (LAN) users to Authenticate (local/RADIUS/LDAP) for any kind of internet access through the ISA550/570? (like cut-through authentication proxy in ASA.) And Can the ISA550/570 act as a Web pr

  • PDF description not populating..

    Hi Guru's, When i attch a PDF to a record its all good with thumbnail getting generated..BUT the issue OR question is How can we display the description of PDF .. For e.g when we save any file on our desktop or any folder we get description of that d