проблема после обновления и некоторые вопросы :)
Форум
  1. Forums
  2. General
  3. General Discussion
  1. Adam Wróbel
  2. Thursday, 19 August 2010
  3.  Subscribe via email
I have problem after update to 2.6.18-294.8.1.el5.lve0.7.32. I have lve with id 500, and user with id 500 (test). User have /bin/lve_bash as shell. With previouse version everyting works fine, but now when I try login i get this error:
[[email protected] ~]# cat /etc/passwd | grep test
test:x:500:500::/home/test:/bin/bash
[[email protected] ~]# su - test
[[email protected] ~]$ id
uid=500(test) gid=500(test) grupy=500(test)
[[email protected] ~]$ /bin/lve_bash
lve_bash: Unable to allocate memory for LVE -38

[[email protected] ~]# cat /proc/lve/list
veid enters cpu io cpu_usage
500 0 40 10 4880

# cat /etc/container/ve.cfg
<lveconfig>
<defaults>
<cpu limit=\" 25\"></cpu>
<io limit=\" 25\"></io>
<other maxentryprocs=\" 20\"></other>
</defaults>
<lve id=\"500\">
<cpu limit=\" 40\"></cpu>
<io limit=\" 10\"></io>
<other maxentryprocs=\" 10\"></other>
<chroot></chroot>
</lve>
</lveconfig>

And I have some questions:
-when memory limits become available?
-and in this output:
[[email protected] ~]# lveps -d
LVE REF PNO TNO USR GRP CPU MEM I/O
27 0 2 11 N/A N/A 0% 14168 N/A
in what unit MEM is given? Mb, Kb ?
-Is it possible to make mod_passenger (ruby) / mod_wsgi (python) work in lve like suphp?
-When I create 5 lve with 30% CPU / 30% IO and this 5 lve take heavy load and want use 30% of CPU, how much everyone gets? 100%/5 ~ 20%? And when I create another lve for root with 5% CPU/IO under heavy load, how much of CPU I get? 100% - 5% (for root) / 5 users lve =~ 19% ?

This project is cool and improve performance on my servers
Sorry for my english :)
Rate this post:
  1. 19.08.2010 14:08:13
  2. # 1
Igor Seletskiy Accepted Answer
Posts: 1200
Joined: 09.02.2010
0
Votes
Undo
Try doing:
# yum update lve-wrappers
This should resolve it.

Memory limits: Hopefully -- September. We have seen 3 servers with OOM (which are still not clear why, something to do with PHP spawning processes uncontrollably), and I want to fix it asap.
Memory output is in bytes.
mod_passenger / mod_wsgi -- as long as it doesn\'t have stand alone deamon -- sure, just add a handler to mod_hostinglimts -- it will start limiting it right away.

Regarding your last question -- yes, it is fair share scheduler, so each LVE (site) will get equal share (as long as it needs it).
If you have one site that needs 5% of CPU and 5 sites each asking for 30%, you will have one site using 5%, and the rest of them using another 19% each... well, a bit less, as system/other processes are counted as one big LVE as well, and they will get their cut also.
  1. 19.08.2010 15:08:46
  2. # 2
Adam Wróbel Accepted Answer
Posts: 10
Joined: 19.08.2010
0
Votes
Undo
[[email protected] ~]# yum upd ate lve-wrappers
Loaded plugins: fastestmirror, rhnplugin
Loading mirror speeds from cached hostfile
* rpmforge: ftp-stud.fht-esslingen.de
Se tting up Update Process
No Packages marked for Update

I try remove and install again, and problem still exists.

So If mod_passenger doesn\'t provide se thandler options it can\'t be used with mod_hostinglimnits? mod_wsgi should work, I try it ASAP http://code.google.com/p/modwsgi/wiki/ConfigurationDirectives#WSGIScriptAlias
  1. 19.08.2010 15:08:28
  2. # 3
Igor Seletskiy Accepted Answer
Posts: 1200
Joined: 09.02.2010
0
Votes
Undo
I was able to replicate the issue with lve-wrappers. Will try to fix it asap.

mod_passenger -- looks like we would have to do some custom coding to handle it, as it has weired (not bad, but unusual) way to detect when it should run.
  1. 19.08.2010 15:08:46
  2. # 4
Adam Wróbel Accepted Answer
Posts: 10
Joined: 19.08.2010
0
Votes
Undo
I look forward for information about mod_passenger it\'s simplest way for shared hosting to serve ruby apps.

I was pleasantly surprised with Your support :)
  1. 19.08.2010 16:08:54
  2. # 5
Adam Wróbel Accepted Answer
Posts: 10
Joined: 19.08.2010
0
Votes
Undo
mod_wsgi also doesn\'t work correctly .
<VirtualHost *:80>
ServerName py.centos1.zaszyfruj.pl
WSGIScriptAlias / /home/py/fib/start.wsgi
WSGIDaemonProcess py user=py group=py threads=3 display-name=%{GROUP}
WSGIProcessGroup py
<Directory /home/py/fib>
#LVEId 503
WSGIApplicationGroup %{GLOBAL}
SetHandler wsgi-script
Order deny,allow
Allow fr om all
</Directory>
</VirtualHost>

<IfModule mod_hostinglim its.c>
SkipErrors Off
AllowedHandlers wsgi-script x-httpd-php cgi-script php5-script php4-script php-script application/x-httpd-php5 application/x-httpd-php
</IfModule>

created lve with user id 503 (py). When I add LVEId 503 in <Directory> it working but:
[[email protected] ~]# lveps -d
LVE REF PNO TNO USR GRP CPU MEM I/O
503 1 1 1 apache apache 0% 3016 N/A

user is apache not py, and CPU usage is 0, htop shows about 70%
  1. 19.08.2010 16:08:59
  2. # 6
Igor Seletskiy Accepted Answer
Posts: 1200
Joined: 09.02.2010
0
Votes
Undo
Ignore user -- it is wrong indicator / meant for a different thing

Can you write a small python script that just sleeps for 5 minutes
Run it via browser,
And then do
lveps -d

and lveps -p

also get pid of that python process if you can.
Then I can say for sure if it works or not.

I think what is happening -- this module is working like mod_fcgid -- forking on startup, and then using the fork as a daemon, to run python scripts.

If that is the case -- we might still be able to handle it -- but it is a bit more complex.
  1. 19.08.2010 16:08:02
  2. # 7
Igor Seletskiy Accepted Answer
Posts: 1200
Joined: 09.02.2010
0
Votes
Undo
lve_wrappers -- will start working right after reboot (once new kernel will be running). Looks like we didn\'t test enough for backward compatibility.
  1. 19.08.2010 16:08:57
  2. # 8
Adam Wróbel Accepted Answer
Posts: 10
Joined: 19.08.2010
0
Votes
Undo
this is pylons app and do this:

def fib(self, n2):
n = int(n2)
if n == 0:
return str(0)
elif n == 1:
return str(1)
else:
ret = int(self.fib(n-1)) + int(self.fib(n-2))
return str(ret)

in browser: http://host/main/fib/50 , this take long time and it\'s very CPU intensive.

[[email protected] ~]# lveps -d
LVE REF PNO TNO USR GRP CPU MEM I/O
503 1 1 1 apache apache 0% 3020 N/A
27 0 2 11 N/A N/A 0% 14264 N/A
[[email protected] ~]# ps auxw | grep wsgi
py 6556 94.0 0.7 75564 15292 ? Sl 22:17 1:12 (wsgi:py)
root 6585 0.0 0.0 4028 764 pts/0 S+ 22:18 0:00 grep wsgi

and yes, after apache startup I see wsgi process with 3 threads waiting for request, owned by user 503 (py)

==

lve_wrappers:

[[email protected] ~]# uptime
22:25:03 up 11 min, 1 user, load average: 1.22, 0.97, 0.47
[[email protected] ~]# uname -a
Linux centos1.zaszyfruj.pl 2.6.18-294.8.1.el5.lve0.7.32 #1 SMP Fri Jul 23 15:21:12 EEST 2010 i686 i686 i386 GNU/Linux
[[email protected] ~]# su - test
[[email protected] ~]$ /bin/lve_bash
lve_bash: Unable to allocate memory for LVE -38

I reboot server 5 or 6 times
  1. 19.08.2010 16:08:25
  2. # 9
Igor Seletskiy Accepted Answer
Posts: 1200
Joined: 09.02.2010
0
Votes
Undo
could you do
rpm -qa liblve and give the output

Regarding wsgi/passenger -- I believe we can do it quite easy actually, but it will require full recompile of cPanel apache. Let me talk to my developers.
  1. 19.08.2010 17:08:16
  2. # 10
Adam Wróbel Accepted Answer
Posts: 10
Joined: 19.08.2010
0
Votes
Undo
[[email protected] ~]# rpm -qa liblve
liblve-0.7-6.el5.cloudlinux

I use DirectAdmin panel, but this server is for test only, without DA
  1. 20.08.2010 09:08:27
  2. # 11
Igor Seletskiy Accepted Answer
Posts: 1200
Joined: 09.02.2010
0
Votes
Undo
I think we fixed the issue with lve_wrappers
Please, do:
# yum clean all
# yum update liblve
That should resolve it.
  1. 20.08.2010 11:08:38
  2. # 12
Adam Wróbel Accepted Answer
Posts: 10
Joined: 19.08.2010
0
Votes
Undo
Yes :) Thanks for help
  1. 14.10.2010 08:10:43
  2. # 13
Adam Wróbel Accepted Answer
Posts: 10
Joined: 19.08.2010
0
Votes
Undo
Any update on memory limits with lve?
And wsgi/passenger compatybility?
Lve run great with DirectAdmin on php account.
  1. 14.10.2010 21:10:48
  2. # 14
Igor Seletskiy Accepted Answer
Posts: 1200
Joined: 09.02.2010
0
Votes
Undo
Memory limits -- it is close, but not yet.
wsgi/passenger -- we haven\'t had a chance to deal with it yet :(
  1. 15.10.2010 03:10:19
  2. # 15
Adam Wróbel Accepted Answer
Posts: 10
Joined: 19.08.2010
0
Votes
Undo
i just can\'t wait for it :)
  1. 13.12.2010 04:12:09
  2. # 16
Adam Wróbel Accepted Answer
Posts: 10
Joined: 19.08.2010
0
Votes
Undo
Any update on memory/io limits ?
  1. 13.12.2010 08:12:55
  2. # 17
Igor Seletskiy Accepted Answer
Posts: 1200
Joined: 09.02.2010
0
Votes
Undo
Memory -- very soon (public beta tests will start next week, and hopefully -- production one/two weeks after).

IO -- few more months.
  1. 08.01.2011 05:01:20
  2. # 18
Griya Hosting Accepted Answer
Posts: 14
Joined: 18.12.2010
0
Votes
Undo
[<pts/1> [email protected] /root]$ yum upd ate lve-wrappers
Loaded plugins: fastestmirror, rhnplugin
Loading mirror speeds from cached hostfile
* rpmforge: fr2.rpmfind.net
Excluding Packages in global exclude list
Finished
Se tting up Update Process
Package(s) lve-wrappers available, but not installed.
No Packages marked for Update



My lve-wrappers not installed, what function ?
  1. 08.01.2011 12:01:39
  2. # 19
Igor Seletskiy Accepted Answer
Posts: 1200
Joined: 09.02.2010
0
Votes
Undo
do you install lve-wrappers
  1. 16.03.2013 15:03:53
  2. # 20
Mrg Accepted Answer
Posts: 1
Joined: 16.03.2013
0
Votes
Undo
What about mod_wsgi, is it possible to limit (lve) this like php / cgi ?
  • Page :
  • 1


There are no replies made for this post yet.
Be one of the first to reply to this post!
гость
Submit Your Response
Upload files or images for this discussion by clicking on the upload button below. Supports gif,jpg,png,zip,rar,pdf
• Insert • Remove Upload Files (Maximum File Size: 2 MB)
Captcha
To protect the site from bots and unauthorized scripts, we require that you enter the captcha codes below before posting your question.