Link to home
Start Free TrialLog in
Avatar of goransun
goransun

asked on

Applications very slow sometimes

Hello,

 we are running a terminal server with LTSP, Ubuntu 8.04 and Gnome. Due to users preferences, there is also Konqueror installed, and used frequently. All of them are using Open Office, Firefox and Thunderbird. Some of them additional applications like VMWare. Hardware is 2x Opteron 2 GHz with 4 GB Ram. There are 6 clients connected with 100 mbit.

 Most of the time and for most users everything runs fine. But two of them complain pretty often about a slow system. One of them told me, that it sometimes takes up to 5 minutes, before a new email window in Thunderbird opens. How can I find out the reason for this?

Avatar of Member_2_4694817
Member_2_4694817

Watch the load using "top". The most likely cause for delay is memory consumption leading to swapping.
Avatar of goransun

ASKER

Hello thehagman,

thank's a lot for your answer. Is there another way than "top"? I'm not permanently at the office and the problem occurs only sometimes. I'm looking for some kind of log that is showing me what's happening, if there exists something like this. Sorry for not being precise enough.
SOLUTION
Avatar of Roachy1979
Roachy1979
Flag of United Kingdom of Great Britain and Northern Ireland image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Hi Roachy1979,

thank you for the link. MRTG looks pretty good, but also pretty complex. I took a look at the links, installed it in a vm and did a man mrtg, but didn't get the point how to use it. I found munin, which implements a similar funcionality as MRTG in regard of system monitoring and seems to be easier to use.

But what do I have to look for? How can I see, what is actually slowing the system down for a particular user? With TOP I could use u to filter a particular user and see which processes are using a lot of memory, cpu etc. How can I get the problem with these kind of tools? Sorry if this is a stupid question. I didn't do too much monitoring yet.
That's fine...thinking on, it would only really show you if there was a huge processor usage at a specific time, or a huge RAM usage and not the process responsible...

To get more detailed information, you could effectively screen scrape a top at regular intervals - using a cron job to run:

top -b -n1 >> topoutput

or you could filter this further based on user by

top -b -n1 | grep username >> topoutput

This will create a pretty large file though depending on the frequency you run it...

You could also look at the performance testing for BigBlueButton on Google code - they use a few in built *nix tools to get interesting output:
http://code.google.com/p/bigbluebutton/wiki/PerformanceTesting




O.k., thank's a lot for your answers. I'll try out all of this tomorrow. As soon as I got the results, I'll be back.
...  takes up to 5 minutes ...

It sounds like their machines are not well published in DNS ...
At the moment the clients connect via dhcp to the  terminal server. No fixed addresses. Do you think it would help to give the clients fixed addresses and proper DNS entries?

isc dhcp can update dns on behalf of clients. no need for fixed addresses.
ask those hurt to execute who am i and whoami commands. if they are slow then it is DNS timeout in server side. Why?
I wasn't sure what exactly you mean with not well published in DNS. Therefor I asked. I'm new to LTSP and not sure where to look first. But I got another question. If it's a DNS timeout, why there are only affected  specific clients and not all of them?

Thank's for your answers.
Sporadic problems are hard to trace... I suggest you check if server can resolve client when it gets slow (missed DNS upd or so)
ASKER CERTIFIED SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Jumping back in here as well and re-reading the original thread - are your users running virtual machines WITHIN a thin client environment?  What does the resource usage look like for these users - allocated RAM and so on?  4 Gb Ram for 6 clients and some running VM's isn't that great....

I suggest you look at Swap usage as macker suggests - this will give you an indication....
Sorry for replying this late, but it was not until today that I was in the office. But that's a lot for all of your replies.  They were really helpful.

@Roachy1979
Yes, the virtual machine is executed directly on the terminal server. It's a Windows machine with 512 mb Ram that is only used by one user at a time. And these users don't have real Thin Clients. They still have their old PCs connecting via LTSP  to the Terminal Server.


This is what I did today at the office.

Asked all of the users.

There is one more with problems using Thunderbird. He told me he has to wait 2-3 minutes  after he opened Thunderbird until everything works fine. Until then, working with  Thunderbird is slow.  Afterwards: no problem. This user is using vmware and a pc as Thin Client.

The one with the most problems told me, she has one of these difficulties at least once a day:
-      Thunderbird is slow
-      Thunderbird not sending attachments
-      Open office not responding
-      Client not responding. She reboots the client.
This one uses a real Thin Client and not VMWare. The rest is happy.

Htop for swap, ram and cpu
Swap  -> 40 mb
Ram -> 800 mb
Cpu -> up to 100 % on both  processors, but not permanently
I forgot to use free, Ill do it tomorrow.

Installed sar and munin. Users have to write down time and type of problem. I will look at the results tomorrow.

Whoami
Executed whoami on Thin Client with most problems.  -> Seemed to be o.k.

I guess the long-term-values will show better results. Or did I miss something?
Long term tests will be more telling - can you see what application is utilising most of the high CPU usage?

Also - have you tried a lighter desktop environment for your client images?  XFCE or ICEWM might be better.

Also did a little more reading and fell over this port on a mailing list:

http://www.mail-archive.com/ltsp-discuss@lists.sourceforge.net/msg34385.html

Suggestions here were:

"Another shot in the dark, in Acroread (sic) options, switch off Fast Web View and ensure that, if you have a proxy server, it is stated in the proxy settings.  
This needs to be done for all users."

To do this, open Acrobat Reader and change the settings EDIT--> PREFERENCES --> INTERNET --> Web Browser Options and EDIT--> PREFERENCES --> DOCUMENTS --> Save Settings
 
Apparently you also need to change the settings to your proxy server manually within Acrobat Reader to the IP address and port.....as this has been known to cause problems (as per the article above and also http://blogs.adobe.com/acroread/2008/04/100_cpu_utilization_problem.html)

Let me know how you get on - I'm looking at the possibility of implementing LTSP soon, as an alternative to server/client LDAP to try and squeeze some life out of old hardware...so really interested in views as to how this works in a real-world environment....
Slowness of all applications could be network congestion or re-negotiation somewhere on network link.
Signs include DNS disappearance that makes problem even worse...
If you run cpufreq or similar 100% cpu use is OK - eg CPU runs at 1/10 or 3/10 of frequency and executes tasks all the time
Please gather output of "uptime" (probably using SNMP, mrtg or so) - that is more indicative of CPU load - process queue waiting for CPU time. <1 perfect <10 OK <100 still runs
More information will be useful, but it does sound as though you might be hammering the CPU, especially since you're running VMware.  RAM is likely to become a bottleneck in the future, but it doesn't appear to be an issue just yet.

If there is any CPU speed controls in place, I would suggest disabling them; while they're useful for power conservation, it's been shown with benchmarks that it will reduce performance on a busy server, e.g. database servers, and LTSP would likely suffer similarly.

Realistically, VMware can tax an Opteron CPU on a single client system, let alone a multi-user system like this.  Also, are these single-core or dual-core Opteron's?  E.g. 2216's, or .. ?
Hello,

sorry for replying this late, but for various reasons it wasn't possible earlier.

Long term monitoring showed, that it was indeed a memory problem. After adding another 2 GB of RAM to the server and installing the server kernel from repositories, almost everything worked well. One thin client was still freezing, but this was due to graphics memory. I changed the bios settings from 16 to 64 mb and now everything works perfectly.

Thank you all for your tremendous help.

@Roachy1979
I can only recommend LTSP. It's very easy to install and to maintain. I used Ubuntu 8.04 LTS alternate with the LTSP option. It worked out of the box. The only problem besides memory was with one Thin Client from HP, where I had to disable the splash screen in order to connect. But we have only one server, so I don't know how it works if you have to implement load balancing etc.
I hope it is o.k. if I split points. Roachy1979 led me to munin, and macker-: to looking at memory, therefore the ratio.

@Roachy1970
If you got any questions in regard of LTSP, please feel free to contact me.