473,382 Members | 1,313 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,382 software developers and data experts.

How can Permissions affect Performance ?

Hi,

We have noticed some of our complex queries run much faster when
connected as
the instance owner, compared to a userA who has explcitly granted
privileges on all the required Tables & SQL Table Functions.

e.g 1 query runs in 10ms for the Instance Owner and 1.9s for the
user i.e greater than 100x faster!

If we add the instance owners (Linux) Primary group to userA's list of
(linux)groups, the query then runs in 10ms for him too.

Can anybody explain this as expected/reasonable behaviour ?

NB. We have run the query multiple times to eliminate compilation time
as a factor etc....

I have never seen query performance varying like this when using
different users/privileges.

Many thanks.

Paul.
Nov 12 '05 #1
5 1419
Paul,

I take a wild guess here. If permissions need to be checked through a
group, DB2 needs to call out to the OS to establish group membership.
If that callout takes a while (domains?) then it explains for the
difference.

Cheers
Serge
--
Serge Rielau
DB2 SQL Compiler Development
IBM Toronto Lab
Nov 12 '05 #2
Do you have any MQT's that only have access for the instance owner?

Paul Reddin wrote:
Hi,

We have noticed some of our complex queries run much faster when
connected as
the instance owner, compared to a userA who has explcitly granted
privileges on all the required Tables & SQL Table Functions.

e.g 1 query runs in 10ms for the Instance Owner and 1.9s for the
user i.e greater than 100x faster!

If we add the instance owners (Linux) Primary group to userA's list of
(linux)groups, the query then runs in 10ms for him too.

Can anybody explain this as expected/reasonable behaviour ?

NB. We have run the query multiple times to eliminate compilation time
as a factor etc....

I have never seen query performance varying like this when using
different users/privileges.

Many thanks.

Paul.

Nov 12 '05 #3

"Paul Reddin" <pa**@abacus.co.uk> wrote in message
news:1f**************************@posting.google.c om...
Hi,

We have noticed some of our complex queries run much faster when
connected as
the instance owner, compared to a userA who has explcitly granted
privileges on all the required Tables & SQL Table Functions.

e.g 1 query runs in 10ms for the Instance Owner and 1.9s for the
user i.e greater than 100x faster!

If we add the instance owners (Linux) Primary group to userA's list of
(linux)groups, the query then runs in 10ms for him too.

Can anybody explain this as expected/reasonable behaviour ?

NB. We have run the query multiple times to eliminate compilation time
as a factor etc....

I have never seen query performance varying like this when using
different users/privileges.


Interesting problem.

The two experiments I'd try are:
1) Adding the instance owner's group to userA's group list [ you've already
done this, seems to fix the degradation ]
2) Changing SYSADM_GROUP (dbm parameter) to be userA's group and see if
queries run quickly.

If 2) works just as well as 1), then there's definitely a problem with DB2,
and a call to DB2 Support would be warranted.

--
Matt Emmerton
DB2 OLTP Performance
IBM Toronto Lab
Nov 12 '05 #4
"Paul Reddin" <pa**@abacus.co.uk> wrote in message
news:1f**************************@posting.google.c om...
Hi,

We have noticed some of our complex queries run much faster when
connected as
the instance owner, compared to a userA who has explcitly granted
privileges on all the required Tables & SQL Table Functions.

e.g 1 query runs in 10ms for the Instance Owner and 1.9s for the
user i.e greater than 100x faster!

If we add the instance owners (Linux) Primary group to userA's list of
(linux)groups, the query then runs in 10ms for him too.

Can anybody explain this as expected/reasonable behaviour ?

NB. We have run the query multiple times to eliminate compilation time
as a factor etc....

I have never seen query performance varying like this when using
different users/privileges.

Many thanks.

Paul.


When I first installed RH9, I noticed that the logon to Linux for non-root
users took a lot longer than root. This was true for the GUI desktop and
remote telnet sessions. The delay was several seconds for non-root users.

Since that time I have reinstalled RH9 and applied all the latest updates
and the problem seems to have gone away. I don't know if this has anything
to do with your DB2 problem on Linux, but that is the only thing I can think
of.
Nov 12 '05 #5
Thanks for the ideas.

- we don't use group permissions, so I guess the OS call isn't relevant.
- we don't use MQT's

I'll raise a PMR on this if/when fp6 doesn't fix it.

Thanks

Paul.
Nov 12 '05 #6

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: Phil Powell | last post by:
if ($this->isSuccessful && !$hasMogrified) { // SMACK IT ALL TOGETHER @imagecopyresampled($newImage, $image, $config, $config, 0, 0, $config, $config, $origWidth, $origHeight); // SAVE TO FILE...
2
by: K Finegan | last post by:
I have an archival process on a large database that runs once a month. At the beginning of the process the triggers and indexes on the tables whose data is moved are dropped, the data is moved and...
5
by: Ross Presser | last post by:
As our customers demand that we tighten our IT security in the company, I've been asked to prepare a report quarterly showing, for each user in Active directory, what his effective permissions are...
6
by: !!! Klutzo !!! | last post by:
I give permissions for ASPNET on a top level subdirectory. A windows program copies a file into the subdirectory, however, my web service cannot access the file because it does not have...
1
by: Robin Tucker | last post by:
I'm considering adding domain integrity checks to some of my database table items. How does adding such constraints affect SQL Server performance? For example, I have a simple constraint that...
10
by: John Salerno | last post by:
I always read about how you need to set certain file permissions (for cgi files, for example), but it's never been clear to me *how* you do this. I know you can run the line chmod 755...
11
by: Raja Chandrasekaran | last post by:
Hai folks, I have a question to get exact answer from you people. My question is How Static class is differ from instance class and If you use static class in ASP.NET, ll it affect speed or...
16
by: John | last post by:
Does the length of my C variable names have any affect, performance-wise, on my final executable program? I mean, once compiled, etc., is there any difference between these two: number = 3; n =...
0
by: Salad | last post by:
A97. Split database. Frontend DB1.MDB. Backend DB1BE.MDB. Tables are linked between DB1 and DB2. From my testing, if I open DB1 exclusively using /excl the backend DB1BE is not opened...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.