-
kurtjx
man i can't do it
2011-01-17 01744, 2011
-
kurtjx
i would but wife is passed out basically sick from insomnia
2011-01-17 01758, 2011
-
ruaok
thanks for trying. I appreciate it. good luck with the one woman horror show. :)
2011-01-17 01759, 2011
-
kurtjx
i can't just dip - that would be way too shady
2011-01-17 01713, 2011
-
kurtjx
well there's two actually if you count my wife ;-)
2011-01-17 01756, 2011
-
ruaok
lol
2011-01-17 01706, 2011
-
ruaok
thankfully she's sleeping. :)
2011-01-17 01732, 2011
-
ocharles
ruaok: do we have a running nginx on hobbes?
2011-01-17 01749, 2011
-
ruaok
we do not. we need to bug djce about that today.
2011-01-17 01701, 2011
-
ruaok
want me to push my stats branch so you can keep playing with it?
2011-01-17 01705, 2011
-
ocharles could copy the lingling one
2011-01-17 01720, 2011
-
ruaok
might be a good starting point.
2011-01-17 01704, 2011
-
ruaok pedals to the office
2011-01-17 01717, 2011
-
lfranchi
ok we gotta head out
2011-01-17 01723, 2011
-
lfranchi
his email is still not here...
2011-01-17 01756, 2011
-
lfranchi
when he gets back, can someone ask him to text or call 781-249-1362? thanks
2011-01-17 01702, 2011
-
lfranchi
alastairp: kurtjx ^
2011-01-17 01738, 2011
-
alastairp
sweet
2011-01-17 01757, 2011
-
ocharles
Is there anyway to check if a file is under debian management?
2011-01-17 01703, 2011
-
ocharles
like the inverse of dpkg -L ?
2011-01-17 01713, 2011
-
alastairp
-S
2011-01-17 01718, 2011
-
ocharles
ta
2011-01-17 01727, 2011
-
ruaok joined the channel
2011-01-17 01747, 2011
-
ruaok
lfranchi: mail arrive
2011-01-17 01748, 2011
-
ruaok
?
2011-01-17 01710, 2011
-
nikki
[19:39] lfranchi: when he gets back, can someone ask him to text or call 781-249-1362? thanks
2011-01-17 01725, 2011
-
djce joined the channel
2011-01-17 01732, 2011
-
nikki
ruaok: that was for you
2011-01-17 01736, 2011
-
ruaok
thanks nikki.
2011-01-17 01748, 2011
-
ruaok
nikki: are any of the proposed meeting times acceptable to you?
2011-01-17 01751, 2011
-
ruaok waves at djce
2011-01-17 01704, 2011
-
nikki
all of them
2011-01-17 01707, 2011
-
djce
%T!
2011-01-17 01746, 2011
-
ruaok
nikki: thanks!
2011-01-17 01758, 2011
-
ruaok
djce: we have two things for you.
2011-01-17 01711, 2011
-
ruaok
one I got two backup disk reminders. one for sex, one for drugs.
2011-01-17 01714, 2011
-
ruaok
which one should I heed?
2011-01-17 01747, 2011
-
djce
Ah. Should be SEX, shouldn't it? It's because I ran the script twice not once.
2011-01-17 01758, 2011
-
djce
and the script says, "if it's Monday, rotate the disks".
2011-01-17 01748, 2011
-
ocharles
djce: while you're here, how do I setup the "supervise" directory in /usr/local/mb_server-fastcgi?
2011-01-17 01748, 2011
-
ruaok
SEX sounds right.
2011-01-17 01720, 2011
-
ruaok
djce: and over to ocharles for the second issue.
2011-01-17 01727, 2011
-
djce
ocharles: ignore it.
2011-01-17 01732, 2011
-
djce
it's created automatically.
2011-01-17 01735, 2011
-
ocharles
djce: it won't let me start the service without it
2011-01-17 01737, 2011
-
MBChatLogger
2011-01-17 01737, 2011
-
ruaok
we need to expose hobbes port 80 and change
test.mb.org to point from lingling to hobbes.
2011-01-17 01737, 2011
-
ocharles
but I'm probably doing it wrong :)
2011-01-17 01757, 2011
-
ocharles
I've added the initscript and the service run file to git
2011-01-17 01700, 2011
-
djce
Is this on hobbes?
2011-01-17 01703, 2011
-
ocharles
yea
2011-01-17 01708, 2011
-
djce looks
2011-01-17 01714, 2011
-
ocharles
see /usr/local/mb_server-fastcgi and the same /etc files as lingling
2011-01-17 01718, 2011
-
ocharles
I've tried to copy the layout and links
2011-01-17 01746, 2011
-
djce
Roughly the way to set up a daemontools service is:
2011-01-17 01712, 2011
-
djce
- choose a directory, mkdir it (usually supervise will run as root, so do all this as root)
2011-01-17 01716, 2011
-
djce
mkdir "log"
2011-01-17 01728, 2011
-
djce
create executables called "run" and "log/run"
2011-01-17 01743, 2011
-
djce
(one runs the service, one runs the logger to handle the service's stdout)
2011-01-17 01700, 2011
-
ocharles
ah, missed the logger, but ok
2011-01-17 01714, 2011
-
djce
Symlink the service dir into the svscan directory, e.g. "ln -s $PWD /etc/service/"
2011-01-17 01721, 2011
-
djce
Wait up to 5 seconds.
2011-01-17 01723, 2011
-
djce
Service starts.
2011-01-17 01727, 2011
-
djce
done.
2011-01-17 01722, 2011
-
djce
If you want the service to be stopped by default (e.g. to be started by something else, perhaps something in init.d), "touch ./down"
2011-01-17 01701, 2011
-
ocharles
ok, that's all pretty simple
2011-01-17 01735, 2011
-
ocharles
but I wonder what's missing that's stopping the fastcgi workers to spawn now
2011-01-17 01750, 2011
-
djce
Is it meant to be running right now?
2011-01-17 01757, 2011
-
ocharles
well, I'd like it to :)
2011-01-17 01722, 2011
-
ocharles
Then I was going to use curl against localhost to make sure it was all working, then we can expose it
2011-01-17 01737, 2011
-
djce
The fact that daemontools isn't installed on hobbes yet :-)
2011-01-17 01748, 2011
-
ocharles
I just installed that though I thought
2011-01-17 01749, 2011
-
ocharles
hrm.
2011-01-17 01700, 2011
-
djce
ah, /me checks...
2011-01-17 01711, 2011
-
ocharles
yea, it's installed
2011-01-17 01711, 2011
-
djce
daemontools-run
2011-01-17 01737, 2011
-
djce
Ubuntu splits it into two packages: daemontools == just the toolset, daemontools-run == actually runs it.
2011-01-17 01750, 2011
-
ocharles
ah
2011-01-17 01756, 2011
-
ocharles
ok, got run - do I need to start a service?
2011-01-17 01756, 2011
-
djce
hmm, not sure. /me reads docs
2011-01-17 01714, 2011
-
ocharles
it only gives the update-service binary it seems
2011-01-17 01743, 2011
-
djce
"sudo start svscan" would be my guess
2011-01-17 01705, 2011
-
djce
(or reboot :-)
2011-01-17 01711, 2011
-
ocharles
heh
2011-01-17 01734, 2011
-
ocharles
no errors now
2011-01-17 01749, 2011
-
djce
not working though...
2011-01-17 01703, 2011
-
djce
ps -C readproctitle ww
2011-01-17 01716, 2011
-
ocharles
mm, no logs either
2011-01-17 01721, 2011
-
djce
You have no "run" script yet
2011-01-17 01734, 2011
-
djce
and log/run needs chmod +x
2011-01-17 01736, 2011
-
ocharles
oops, it's called mb_server
2011-01-17 01749, 2011
-
djce
Often a good idea to test by hand first:
2011-01-17 01750, 2011
-
ocharles
oh wait no, I didn't link it
2011-01-17 01753, 2011
-
djce
svc -d . log
2011-01-17 01702, 2011
-
djce
cd log ; echo test | ./run
2011-01-17 01704, 2011
-
djce
cd ..
2011-01-17 01709, 2011
-
djce
./run
2011-01-17 01712, 2011
-
djce
^C
2011-01-17 01725, 2011
-
djce
then when it all looks good, svc -u . log
2011-01-17 01754, 2011
-
ocharles
ok
2011-01-17 01701, 2011
-
ocharles
now to figure out how this local::lib stuff will work :)
2011-01-17 01744, 2011
-
alastairp
<3 local lib
2011-01-17 01752, 2011
-
ocharles
awesome eh?
2011-01-17 01706, 2011
-
alastairp
eval `perl -Mlocal::lib`
2011-01-17 01708, 2011
-
alastairp
done/done
2011-01-17 01746, 2011
-
ocharles
not quite here though...
2011-01-17 01750, 2011
-
alastairp
doh
2011-01-17 01700, 2011
-
ocharles
local::lib is setup as the musicbrainz user
2011-01-17 01714, 2011
-
ocharles
I can't seem to get it to import environment variables into the correct environment in our runscript
2011-01-17 01728, 2011
-
alastairp
ah, yeah
2011-01-17 01741, 2011
-
alastairp
can you put it in .bash* ?
2011-01-17 01703, 2011
-
ocharles
roots?
2011-01-17 01715, 2011
-
ocharles
we have a run script and I tried putting it in there, but it doesn't seem to do anything
2011-01-17 01725, 2011
-
ocharles
"eval $(perl -I/home/musicbrainz/perl5/lib/perl5 -Mlocal::lib)"
2011-01-17 01751, 2011
-
alastairp
you start it as root and it drops to teh mb user?
2011-01-17 01757, 2011
-
ocharles
yea, in an exec block
2011-01-17 01704, 2011
-
ocharles
but that eval is outside the exec
2011-01-17 01705, 2011
-
ocharles
maybe that's why?
2011-01-17 01707, 2011
-
alastairp
hrm
2011-01-17 01708, 2011
-
alastairp
yes
2011-01-17 01711, 2011
-
ocharles
it's also before setuidgid
2011-01-17 01721, 2011
-
alastairp
you need the environment inside the setuid
2011-01-17 01723, 2011
-
alastairp
I think
2011-01-17 01733, 2011
-
alastairp
maybe you can pass an environment parameter?
2011-01-17 01753, 2011
-
ocharles
djce: halps! :)
2011-01-17 01758, 2011
-
djce reads
2011-01-17 01708, 2011
-
ocharles
can you see /usr/local/mb_server-fastcgi/run?
2011-01-17 01709, 2011
-
alastairp
gist the startup script?
2011-01-17 01724, 2011
-
ocharles
2011-01-17 01731, 2011
-
ocharles
setuidgid: fatal: unable to run eval: file does not exist
2011-01-17 01740, 2011
-
djce
ocharles: try something like:
2011-01-17 01750, 2011
-
djce
exec setuidgid musicbrainz bash -c '
2011-01-17 01751, 2011
-
djce
eval foo
2011-01-17 01753, 2011
-
djce
whatever
2011-01-17 01756, 2011
-
djce
set up stuff
2011-01-17 01759, 2011
-
djce
exec fastcgi
2011-01-17 01700, 2011
-
djce
'
2011-01-17 01719, 2011
-
alastairp
yeah
2011-01-17 01742, 2011
-
djce
or, create a script under mb_server which assumes only that the uid and cwd is correct, then sets up the env and execs fastcgi.
2011-01-17 01756, 2011
-
alastairp
or, you may be able to get rid of the evan $()
2011-01-17 01702, 2011
-
alastairp
er, the eval
2011-01-17 01716, 2011
-
alastairp
since then it'll be like going
2011-01-17 01721, 2011
-
alastairp
FOO=1 echo $FOO
2011-01-17 01724, 2011
-
djce
I've addressed this before by creating a script called (say) with-local-lib
2011-01-17 01734, 2011
-
djce
which does stuff like the eval, then execs "$@"
2011-01-17 01739, 2011
-
alastairp
you just set the environment for the fgci script
2011-01-17 01742, 2011
-
ocharles
I think we'll need to do that
2011-01-17 01755, 2011
-
ocharles
now local::Lib is trying to create /root/perl5 as the musicbrainz user, which doesn't work either
2011-01-17 01755, 2011
-
djce
then you write: setuidgid foo with-local-lib fastcgi.pl ...
2011-01-17 01707, 2011
-
djce
don't assume $HOME is set up.