FAQ Search Today's Posts Mark Forums Read
» Video Reviews

» Linux Archive

Linux-archive is a website aiming to archive linux email lists and to make them easily accessible for linux users/developers.


» Sponsor

» Partners

» Sponsor

Go Back   Linux Archive > Ubuntu > Ubuntu Server Development

 
 
LinkBack Thread Tools
 
Old 11-13-2009, 01:14 PM
Mark van Harmelen
 
Default finding bottlenecks on ubuntu systems

Hi everyone

I've never done this before so all hints would be gratefully received.

We are running a 9.04 server, with a single unthreaded process that is of interest, basically one that is busy transforming the contents of a mysql db. I want to find out if we can improve the performance of this process.


Seems potential limitations are

- limited by CPU speed
- limited by access to mysql data on disc
- limited by memory size, and therefore spending its time paging

I'm wondering if anyone has any great commands* and/or command options for me to start my investigations with, please.


Or any strategies, words of advice, or (instructional) sources that you found useful in tuning your own systems.

thanks
mark






*
--
ubuntu-server mailing list
ubuntu-server@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-server
More info: https://wiki.ubuntu.com/ServerTeam
 
Old 11-13-2009, 05:57 PM
David Miller
 
Default finding bottlenecks on ubuntu systems

iostat - will show you what sort of IO operations are going on
vmstat - will show you whats happening in the memory management of the system
top - will show you cpu activity broken down by processes

There is some overlap in the data from these tools but those are a good place to start.


Other things that may be interesting to look into is what IO schedulers you're using.* Deadline may be better for your workload than the default CFQ.

To list the available io schedulers use this command.




cat /sys/block/sdb/queue/scheduler

This should return "noop anticipatory deadline [cfq]"



To change your scheduler to deadline use the following command on the appropriate device.



sudo echo "deadline" > /sys/block/sdb/queue/scheduler
--
David

On Fri, Nov 13, 2009 at 9:14 AM, Mark van Harmelen <markvanharmelen@gmail.com> wrote:

Hi everyone

I've never done this before so all hints would be gratefully received.


We are running a 9.04 server, with a single unthreaded process that is of interest, basically one that is busy transforming the contents of a mysql db. I want to find out if we can improve the performance of this process.



Seems potential limitations are

- limited by CPU speed
- limited by access to mysql data on disc
- limited by memory size, and therefore spending its time paging

I'm wondering if anyone has any great commands* and/or command options for me to start my investigations with, please.



Or any strategies, words of advice, or (instructional) sources that you found useful in tuning your own systems.

thanks
mark






*

--

ubuntu-server mailing list

ubuntu-server@lists.ubuntu.com

https://lists.ubuntu.com/mailman/listinfo/ubuntu-server

More info: https://wiki.ubuntu.com/ServerTeam


--
ubuntu-server mailing list
ubuntu-server@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-server
More info: https://wiki.ubuntu.com/ServerTeam
 
Old 11-13-2009, 06:12 PM
Joseph Salisbury
 
Default finding bottlenecks on ubuntu systems

On Fri, Nov 13, 2009 at 9:14 AM, Mark van Harmelen
<markvanharmelen@gmail.com> wrote:
> Hi everyone
>
> I've never done this before so all hints would be gratefully received.
>
> We are running a 9.04 server, with a single unthreaded process that is of
> interest, basically one that is busy transforming the contents of a mysql
> db. I want to find out if we can improve the performance of this process.
>
> Seems potential limitations are
>
> - limited by CPU speed
> - limited by access to mysql data on disc
> - limited by memory size, and therefore spending its time paging
>
> I'm wondering if anyone has any great commands* and/or command options for
> me to start my investigations with, please.

If you haven't already, install the sysstat package:

sudo apt-get install sysstat

This will give you some tools to gather performance statistics. To
start you need to identify where the bottleneck is. Use cpustat to
see if you are cpu bound, iostat to see if you are disk bound, vmstat
for pageing / memory stats, etc.

For more detailed analysis, you can install and use profiling tools
such as oprofile or systemtap.

>
> Or any strategies, words of advice, or (instructional) sources that you
> found useful in tuning your own systems.

This can be an open ended question when it comes to performance
tuning. The very simple answer is find your bottleneck and fix it.
There will always be a bottleneck and it will always move to another
resource once you fix it. The goal is to have your cpu become the
bottleneck(Then continue to tune your application).

It is best to try and tune your application first to use the available
resource most efficiently. Don't just add more memory because your
swapping. First identify why the process is consuming so much memory
in the first place.

Hope this helps,

Joe

>
> thanks
> mark
>
>
>
>
>
>
>
> --
> ubuntu-server mailing list
> ubuntu-server@lists.ubuntu.com
> https://lists.ubuntu.com/mailman/listinfo/ubuntu-server
> More info: https://wiki.ubuntu.com/ServerTeam
>

--
ubuntu-server mailing list
ubuntu-server@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-server
More info: https://wiki.ubuntu.com/ServerTeam
 
Old 11-13-2009, 06:14 PM
Joseph Salisbury
 
Default finding bottlenecks on ubuntu systems

On Fri, Nov 13, 2009 at 2:12 PM, Joseph Salisbury
<josephtsalisbury@gmail.com> wrote:
> On Fri, Nov 13, 2009 at 9:14 AM, Mark van Harmelen
> <markvanharmelen@gmail.com> wrote:
>> Hi everyone
>>
>> I've never done this before so all hints would be gratefully received.
>>
>> We are running a 9.04 server, with a single unthreaded process that is of
>> interest, basically one that is busy transforming the contents of a mysql
>> db. I want to find out if we can improve the performance of this process.
>>
>> Seems potential limitations are
>>
>> - limited by CPU speed
>> - limited by access to mysql data on disc
>> - limited by memory size, and therefore spending its time paging
>>
>> I'm wondering if anyone has any great commands* and/or command options for
>> me to start my investigations with, please.
>
> If you haven't already, install the sysstat package:
>
> sudo apt-get install sysstat
>
> This will give you some tools to gather performance statistics. *To
> start you need to identify where the bottleneck is. *Use cpustat to
> see if you are cpu bound, iostat to see if you are disk bound, vmstat
> for pageing / memory stats, etc.

Woops: s/cpustat/mpstat/g :-)

>
> For more detailed analysis, you can install and use profiling tools
> such as oprofile or systemtap.
>
>>
>> Or any strategies, words of advice, or (instructional) sources that you
>> found useful in tuning your own systems.
>
> This can be an open ended question when it comes to performance
> tuning. *The very simple answer is find your bottleneck and fix it.
> There will always be a bottleneck and it will always move to another
> resource once you fix it. *The goal is to have your cpu become the
> bottleneck(Then continue to tune your application).
>
> It is best to try and tune your application first to use the available
> resource most efficiently. *Don't just add more memory because your
> swapping. *First identify why the process is consuming so much memory
> in the first place.
>
> Hope this helps,
>
> Joe
>
>>
>> thanks
>> mark
>>
>>
>>
>>
>>
>>
>>
>> --
>> ubuntu-server mailing list
>> ubuntu-server@lists.ubuntu.com
>> https://lists.ubuntu.com/mailman/listinfo/ubuntu-server
>> More info: https://wiki.ubuntu.com/ServerTeam
>>
>

--
ubuntu-server mailing list
ubuntu-server@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-server
More info: https://wiki.ubuntu.com/ServerTeam
 

Thread Tools




All times are GMT. The time now is 08:02 AM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright 2007 - 2008, www.linux-archive.org