Bug 864008 - [US2599][fork] rhc app tidy can not work well
Summary: [US2599][fork] rhc app tidy can not work well
Keywords:
Status: CLOSED NOTABUG
Alias: None
Product: OKD
Classification: Red Hat
Component: oc
Version: 2.x
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: ---
: ---
Assignee: Dan McPherson
QA Contact: libra bugs
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2012-10-08 10:31 UTC by Wei Sun
Modified: 2015-05-15 02:06 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2012-10-08 14:36:59 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description Wei Sun 2012-10-08 10:31:56 UTC
Description of problem:

 Create an application,and create a test file in /tmp directory,and run "rhc app tidy -a $appname",and can get prompt that application cleaned up,but check /tmp directory,test file is not  cleaned up successfully.
 
Version-Release number of selected component (if applicable):

server:devenv_2295
client: built from fork_ami_US2597_US2599_US2813_US2817_US2872_US2816_US2814_209

How reproducible:

always

Steps to Reproduce:

1.create an application
2. ssh instance and create a test file in /tmp directory
   cd /var/lib/openshift/9d4254864330483bb5680b58e3ce1031/php-5.3/tmp/
   touch test.txt
   echo test >> test.txt
3.check /tmp directory
4.rhc app tidy -a $appname
  rhc app tidy -a phptest
5.check /tmp directory


Actual results:

3.before tidying

[root@ip-10-60-130-169 openshift]# ls -al 9d4254864330483bb5680b58e3ce1031/php-5.3/tmp
total 12
drwxr-xr-x.  2 9d4254864330483bb5680b58e3ce1031 9d4254864330483bb5680b58e3ce1031 4096 Oct  8 04:19 .
drwxr-xr-x. 10 root                             root                             4096 Oct  8 04:15 ..
-rw-r--r--.  1 root                             root                                5 Oct  8 04:22 text.txt

[root@ip-10-60-130-169 openshift]# cat 9d4254864330483bb5680b58e3ce1031/php-5.3/tmp/text.txt
test

4.rhc app tidy

[sunwei@dhcp-8-229 dev]$ rhc app tidy -a phptest
Password: 


**********

RESULT:
phptest cleaned up

5.after tidying

[root@ip-10-60-130-169 openshift]# ls -al 9d4254864330483bb5680b58e3ce1031/php-5.3/tmp
total 12
drwxr-xr-x.  2 9d4254864330483bb5680b58e3ce1031 9d4254864330483bb5680b58e3ce1031 4096 Oct  8 04:19 .
drwxr-xr-x. 10 root                             root                             4096 Oct  8 04:15 ..
-rw-r--r--.  1 root                             root                                5 Oct  8 04:22 text.txt

[root@ip-10-60-130-169 openshift]# cat 9d4254864330483bb5680b58e3ce1031/php-5.3/tmp/text.txt
test


Expected results:

Clean up /tmp directory ,and test file is cleaned up successfully

Comment 1 Hiro Asari 2012-10-08 14:00:29 UTC
The 'tidy' command is making a REST call to tidy up. If /tmp is not getting cleaned up, then it should be fixed there.

I'll assigned this to myself while I track down who should fix the backend.

Comment 2 Hiro Asari 2012-10-08 14:22:29 UTC
I think Dan McPherson knows best about the actual implementation of this part of the broker.

Comment 3 Dan McPherson 2012-10-08 14:36:59 UTC
/var/lib/openshift/9d4254864330483bb5680b58e3ce1031/php-5.3/tmp/ is not one of the official tmp dirs.

cd /tmp  is one.


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