Bug 824409 - Symbolic link for mysql gear is not created after move mysql gear from one node to another node.
Symbolic link for mysql gear is not created after move mysql gear from one no...
Status: CLOSED CURRENTRELEASE
Product: OpenShift Origin
Classification: Red Hat
Component: Containers (Show other bugs)
2.x
Unspecified Unspecified
low Severity low
: ---
: ---
Assigned To: Jhon Honce
libra bugs
: Triaged
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2012-05-23 08:20 EDT by Johnny Liu
Modified: 2015-05-14 18:54 EDT (History)
5 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2012-06-25 14:26:50 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Johnny Liu 2012-05-23 08:20:37 EDT
Description of problem:
Symbolic link for mysql gear is not created after move mysql gear from one node to another node.
Before move:
# ll
<--snip-->
drwxr-x---.  8 root 70c40eec853649f7a4e61238989f9e83 4096 May 23 08:11 70c40eec853649f7a4e61238989f9e83
lrwxrwxrwx.  1 root root                               52 May 23 08:11 70c40eec85-jialiu -> /var/lib/stickshift/70c40eec853649f7a4e61238989f9e83
<--snip-->

# ls 70c40eec85-jialiu
70c40eec85  git  mysql-5.1

After move:
# ll
total 12
<--snip-->
drwxr-x---. 8 root 70c40eec853649f7a4e61238989f9e83 4096 May 23 08:11 70c40eec853649f7a4e61238989f9e83
<--snip-->



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

How reproducible:
Always

Steps to Reproduce:
1. Create a scalable app
2. Embed mysql to this app
3. Move mysql gear from one node to another
  
Actual results:
Symbolic link for mysql gear is not created after move mysql gear from one node to another node.

Expected results:
Symbolic link for mysql gear should be created after move

Additional info:
Comment 1 Rob Millner 2012-05-23 15:37:46 EDT
This only affects devenv; stg and prod do not create these symlinks in the first place.
Comment 2 Ram Ranganathan 2012-06-05 14:18:00 EDT
Assigning to rchopra -- looks like gear move is not creating the symlink.
Comment 3 Dan McPherson 2012-06-05 14:42:38 EDT
This is a cartridge level operation.  Why assign to rchopra?
Comment 4 Ram Ranganathan 2012-06-05 15:48:30 EDT
Ideally, we should do this on a gear move -- not in each cartridge ... today its done in stickshift/abstract/abstract/info/lib/util  (originally only for the "framework"). 
That util function is also called via abstract/info/hooks/move but not in any other "embeddable" cartridge (ala mongo/mysql, eventually postgres and anything else that requires to override the default move hook -- which could be a lot more once we completely get to typeless gears) -- and that will result in a lot of duplication/potential failure points.
 
Having it done once as part of the application/gear workflow makes more sense ... imho, we should do it when the gear is created -- really a stickshift-node thing (based on the stickshift-node.conf config). So do it in stickshift-node/model/application_container.rb  -- it will get called on gear create [both when its originally created and on moves]. Probably should have made that clearer, my bad.
Comment 5 Dan McPherson 2012-06-05 15:58:41 EDT
That's still node code :)  And sounds like a future topic.  Same with everything else that should be moved into stickshift-node from the carts.  For now it's owned by the carts and should be fixed there.  If the fix is to move into stickshift-node then great.
Comment 6 Ram Ranganathan 2012-06-05 16:07:47 EDT
Okay  -- will fix it for now in both mysql and mongo ... I can do that its not a biggie -- one call in each. Just wanted to call out there's potential for more stuff like this happening -- example the mysql's move hook's not been changed in a while.
Comment 7 Jhon Honce 2012-06-12 21:21:57 EDT
Mongo/Mysql fix in crankcase commit f8b8c646d127a3449448f5550abd942286c832cf

All cartridge suppot tracked here: https://rally1.rallydev.com/#/4670516379d/detail/userstory/6625302852
Comment 8 Rony Gong 2012-06-14 03:27:10 EDT
This issue still exist on devenv_1843
Comment 9 Jhon Honce 2012-06-14 12:08:10 EDT
Where there any errors in the logs during the move?
Comment 10 Rony Gong 2012-06-25 02:55:13 EDT
verified on devenv_1863
Comment 11 Rony Gong 2012-06-25 03:07:52 EDT
verified on devenv_1863
Comment 12 Rony Gong 2012-06-25 03:23:46 EDT
After move mysql gear to destination node could find the symbol link and $gera_uuid.conf created.

d5ef78a368bb466d87afa6799b24753c is the mysql gear_uuid.


[root@ip-10-120-206-229 stickshift]# ls -al
total 44
drwxr-x--x. 11 root root                             4096 Jun 25 02:15 .
drwxr-xr-x. 37 root root                             4096 Jun 23 21:56 ..
drwxr-x---. 12 root 11816b28a7e644eca19fdad42ae0600f 4096 Jun 25 01:44 11816b28a7e644eca19fdad42ae0600f
drwxr-x---. 13 root 6921073c20894e9dbebb5dcf344fc63e 4096 Jun 24 22:43 6921073c20894e9dbebb5dcf344fc63e
drwxr-x---. 12 root b29fee16aef24a538897a975c4e49523 4096 Jun 25 02:19 b29fee16aef24a538897a975c4e49523
drwxr-x---.  8 root d5ef78a368bb466d87afa6799b24753c 4096 Jun 24 22:49 d5ef78a368bb466d87afa6799b24753c
lrwxrwxrwx.  1 root root                               52 Jun 25 01:12 d5ef78a368-qgong -> /var/lib/stickshift/d5ef78a368bb466d87afa6799b24753c
drwxr-x---.  8 root ecc2e556c2c2455ea495476c73074eb3 4096 Jun 25 01:55 ecc2e556c2c2455ea495476c73074eb3
lrwxrwxrwx.  1 root root                               52 Jun 25 01:55 ecc2e556c2-qgong -> /var/lib/stickshift/ecc2e556c2c2455ea495476c73074eb3
drwxr-x---.  7 root root                             4096 Jun 25 02:15 .httpd.d
drwxr-xr-x.  2 root root                             4096 Jun 25 02:00 .last_access
-rw-r--r--.  1 root root                                0 Jun 25 03:00 last_access.log
lrwxrwxrwx.  1 root root                               52 Jun 25 01:54 myapp2-qgong -> /var/lib/stickshift/b29fee16aef24a538897a975c4e49523
lrwxrwxrwx.  1 root root                               52 Jun 24 22:43 qsjboss-qgong -> /var/lib/stickshift/6921073c20894e9dbebb5dcf344fc63e
lrwxrwxrwx.  1 root root                               52 Jun 25 01:44 qsperl-qgong -> /var/lib/stickshift/11816b28a7e644eca19fdad42ae0600f
drwxr-xr-x.  2 root root                             4096 Jun 24 22:30 .settings
drwxr-x---.  2 root root                             4096 Jun 25 02:15 .stickshift-proxy.d

[root@ip-10-120-206-229 stickshift]# ls -al .httpd.d/
total 48
drwxr-x---.  7 root root 4096 Jun 25 02:15 .
drwxr-x--x. 11 root root 4096 Jun 25 02:15 ..
drwxr-xr-x.  2 root root 4096 Jun 25 01:44 11816b28a7e644eca19fdad42ae0600f_qgong_qsperl
-rw-r--r--.  1 root root  695 Jun 25 01:44 11816b28a7e644eca19fdad42ae0600f_qgong_qsperl.conf
drwxr-xr-x.  2 root root 4096 Jun 24 22:43 6921073c20894e9dbebb5dcf344fc63e_qgong_qsjboss
-rw-r--r--.  1 root root  697 Jun 24 22:43 6921073c20894e9dbebb5dcf344fc63e_qgong_qsjboss.conf
drwxr-xr-x.  2 root root 4096 Jun 25 01:54 b29fee16aef24a538897a975c4e49523_qgong_myapp2
-rw-r--r--.  1 root root  695 Jun 25 01:54 b29fee16aef24a538897a975c4e49523_qgong_myapp2.conf
drwxr-xr-x.  2 root root 4096 Jun 25 01:12 d5ef78a368bb466d87afa6799b24753c_qgong_d5ef78a368
-rw-r--r--.  1 root root  703 Jun 25 01:12 d5ef78a368bb466d87afa6799b24753c_qgong_d5ef78a368.conf
drwxr-xr-x.  2 root root 4096 Jun 25 01:55 ecc2e556c2c2455ea495476c73074eb3_qgong_ecc2e556c2
-rw-r--r--.  1 root root  703 Jun 25 01:55 ecc2e556c2c2455ea495476c73074eb3_qgong_ecc2e556c2.conf

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