Various environment variables have been configured in the/etc/.bash_profile of the system.
Log in with account A, ldd xxx.so see all links normal.
Log in with account root, ldd xxx.so View all links are ok.
With account a login, and then SU Root to switch to the root account, LDD xxx.so show that one of the dependent yyy.so cannot be found, but yyy.so is present, and its path is already configured in/etc/.bash_profile.
I'm baffled, all kinds of ls-l./directory/path View permissions, conjecture is a read-write permission problem for some directories or files. It's been a long day without fruit. Use env to see, how to use
When Su Root is finished, Ld_library_path no more ... Without...
The correct way to switch users is su-root instead of SU root, otherwise the environment variable is lost. The order in which the system loads the environment variables is the first to read which files are read again which files, when switching the user read the environment variable is the mechanism of time to take a good look at the relevant information
CentOS User Switching