Description
The new node setup seems to validate for a 'couchbase' user, though the kubernetes setup done by Traun Leyden doesn't seem to run couchbase as a couchbase user.
From discussion with a user who was trying to make this work:
|
|
Tyler House @tyh0 15:22
|
hrmm.... i've since ran chmod on my /data folder, but i'm still being told i can't change the index path to /data (which is where my persistent data volume is mounted). getting ["Could not set the storage path. It must be a directory writable by 'couchbase' user."]
|
|
Matt Ingenthron @ingenthr 15:23
|
can you make it owned by the couchbase user?
|
sudo chown couchbase:couchbase /data
|
|
Tyler House @tyh0 15:23
|
i tried to do sudo chown couchbase /data, but it said invalid user: couchbase
|
oh, couchbase:couchbase
|
|
Matt Ingenthron @ingenthr 15:24
|
that’s odd
|
|
Tyler House @tyh0 15:24
|
i got this: chown: invalid user: `couchbase:couchbase'
|
|
Matt Ingenthron @ingenthr 15:24
|
then I’d getent passwsd | grep couchbase
|
this was in a kubernetes environment?
|
|
Tyler House @tyh0 15:24
|
it may have something to do with the fact this is running on GKE with couchbase running inside docker containers inside pods
|
yeah exactly
|
|
Matt Ingenthron @ingenthr 15:25
|
there may be something special I’m not familiar with
|
|
Tyler House @tyh0 15:25
|
i'm actually using tleyden's code for the pods
|
|
Matt Ingenthron @ingenthr 15:25
|
if you ps -ef | grep beam.smp, what processes do the users run as?
|
|
Tyler House @tyh0 15:26
|
hmm that's a lot of output. i'll make a paste for it
|
|
Matt Ingenthron @ingenthr 15:27
|
with the beam it’s a lot of output?
|
|
Tyler House @tyh0 15:27
|
http://pastebin.com/wjvBj37X
|
yeah i entered the command you provided, and that was the output
|
|
Matt Ingenthron @ingenthr 16:00
|
ah, okay @tyh0
|
|
Tyler House @tyh0 16:01
|
does that output look normal for what you'd expect?
|
|
Matt Ingenthron @ingenthr 16:02
|
it’s user 1000
|
|
Tyler House @tyh0 16:03
|
so would chown 1000 do the trick? or do i first need to find which user corresponds to 1000?
|
|
Matt Ingenthron @ingenthr 16:03
|
you can use the user’s name or uid, either is fine
|
getent passwd 1000 should tell you who that is
|
|
Tyler House @tyh0 16:04
|
thanks for being patient with a noob haha
|
|
Matt Ingenthron @ingenthr 16:04
|
and you’ll want to set the username and group name
|
or @tleyden may be able to fill you in a bit more on how this is intended to work
|
I didn’t know it doesn’t have a couchbase user
|
|
Tyler House @tyh0 16:07
|
unless it's something i've done wrong, but i believe i've followed the instructions as i've needed to according to what @tleyden had written at https://github.com/couchbase/kubernetes
|
|
Matt Ingenthron @ingenthr 16:08
|
I don’t think you have done something wrong, I just didn’t know that something special was done with users
|
|
Tyler House @tyh0 16:10
|
btw when i do getend passwd 1000 i get gke-b43886b1a69399a83153:x:1000:1000::/home/gke-b43886b1a69399a83153:/bin/bash
|
|
Matt Ingenthron @ingenthr 16:12
|
ah, so it’s some kind of generated user
|
|
Tyler House @tyh0 16:12
|
looks that way, yes
|
|
Matt Ingenthron @ingenthr 16:12
|
but the group is 1000 as well, so chown 1000:1000 /data should be fine
|
|
Tyler House @tyh0 16:13
|
hrmm. i did sudo chown 1000:1000 /data and it seemed to execute fine, no output
|
|
Matt Ingenthron @ingenthr 16:13
|
ls -ld /data would let you verify
|
|
Tyler House @tyh0 16:14
|
then did curl http://10.124.0.3:8091/nodes/self/controller/settings -X POST -u artcode -d index_path=/data and got "Could not set the storage path. It must be a directory writable by 'couchbase' user."
|
|
Matt Ingenthron @ingenthr 16:14
|
hm, that seems like it may be a bug then
|
ping @tleyden
|
|
Tyler House @tyh0 16:14
|
ls -ld /data gives drw-rw-rw- 3 gke-b43886b1a69399a83153 gke-b43886b1a69399a83153
|
|
Matt Ingenthron @ingenthr 16:15
|
can you create users on this system?
|
my guess is that there’s some code in the cluster manager that looks specifically for ‘couchbase’ since that’s what’s typically done/supported on Linux systems
|
arguably, it’s a bug that it’s looking for couchbase instead of the user it’s running as
|
as a workaround, we can create a couchbase user and group, and chown it to that with read+write permissions
|
just to get through the validation
|
then remove or disable the couchbase user
|
other workarounds/fixes would be more complex
|