Note: This is a beta release of Red Hat Bugzilla 5.0. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Also email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback here.
Bug 983780 - oo-last-access got old datestamp from web socket proxy log
Summary: oo-last-access got old datestamp from web socket proxy log
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: OpenShift Online
Classification: Red Hat
Component: Containers
Version: 2.x
Hardware: Unspecified
OS: Unspecified
high
high
Target Milestone: ---
: ---
Assignee: Rob Millner
QA Contact: libra bugs
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-07-12 00:25 UTC by Rob Millner
Modified: 2015-05-14 23:23 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2013-07-22 15:24:32 UTC
Target Upstream Version:


Attachments (Terms of Use)

Description Rob Millner 2013-07-12 00:25:59 UTC
Description of problem:
Apache log had newer timestamps for an application but the web socket proxy log had a really old one.  The oo-last-access command used the web socket proxy's old timestamp because it read it last rather than keep the newer one from the Apache log that it read in first.

Note: this problem is easily reversible; the dates should be compared.

Version-Release number of selected component (if applicable):


How reproducible:
Always under the right conditions

Steps to Reproduce:
1. Create an app
2. Access it via port 80
3. Access it via port 8000
4. Edit /var/log/node-web-proxy/access.log and change the log entry for your gear to be several months ago.
5. Run oo-last-access
6. Inspect the last_access file for you gear.

Actual results:
The old timestamp from step 4.

Expected results:
The new timestamp from the Apache log for step 2.

Additional info:

Comment 1 Rob Millner 2013-07-12 00:28:11 UTC
Pull request:

https://github.com/openshift/origin-server/pull/3073

Comment 2 openshift-github-bot 2013-07-12 02:20:54 UTC
Commit pushed to master at https://github.com/openshift/origin-server

https://github.com/openshift/origin-server/commit/4be799d5d419a25c6b34f3da5a2fe7183b9f9d33
Bug 983780 - parse log files separately and compare timestamps on merge

Comment 3 Meng Bo 2013-07-12 09:48:24 UTC
Checked on devenv_3491, issue has been fixed.

1. Remove all files under .last_access
2. Visit the 80 and 8000 port for the app
3. Modify the Access date to several months ago.
># cat /var/log/node-web-proxy/access.log
# Log opened @ Fri Jul 12 2013 00:55:19 GMT-0400 (EDT)
# Log opened @ Fri Jul 12 2013 01:47:12 GMT-0400 (EDT)
66.187.233.202 app1-bmengdev.dev.rhcloud.com - - [12/Feb/2013:05:38:25 -0400] "GET / HTTP/1.1" 200 61 "-" "Mozilla/5.0 (X11; Linux i686; rv:21.0) Gecko/20100101 Firefox/21.0" (81ms) +
66.187.233.202 app1-bmengdev.dev.rhcloud.com - - [12/Feb/2013:05:38:26 -0400] "GET /favicon.ico HTTP/1.1" 404 301 "-" "Mozilla/5.0 (X11; Linux i686; rv:21.0) Gecko/20100101 Firefox/21.0" (10ms) +
66.187.233.202 app1-bmengdev.dev.rhcloud.com - - [12/Feb/2013:05:38:26 -0400] "GET /favicon.ico HTTP/1.1" 404 301 "-" "Mozilla/5.0 (X11; Linux i686; rv:21.0) Gecko/20100101 Firefox/21.0" (56ms) +

[root@ip-10-152-168-54 .last_access]# oo-last-access 
[root@ip-10-152-168-54 .last_access]# cat 51dfcdd11e9ab97f2500000b 
12/Jul/2013:05:38:23 -0400 


Move bug to verified.


Note You need to log in before you can comment on or make changes to this bug.