Long PATH, LD_LIBRARY_PATH, LIBPATH, … – what kind of performance impact do they have?

Hi, there!

[] a long PATH... makes the OS access the disk quite often, hence there is a lot of disk I/O
[
] a long PATH... makes the OS compute a lot of ..., hence a high CPU load

(Edited/added later: Yes, this is not about the lenght of the env. var., but about the number of directories listed.)

What's the right answer on that?

Do we have to consider PATH, LD_LIBRARY_PATH, LIBPATH separately?
Do different Unix flavour OSs react rather differently?

No, it's not from a quiz or an interview. We got such a problem at work, and "the experts" are telling us, it's more of a CPU load issue. I actually doubt that.

Regards,
~j

This needs to be qualified/quantified. I don't think the length of an environment variable is the issue here, but rather the distinct number of filesystems that are hit when an image activates. Each path along the particular defined variable is a directory on a filesystem. Gather statistics!