LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 10-14-2010, 12:11 PM   #1
ncsuapex
Member
 
Registered: Dec 2004
Location: Raleigh, NC
Distribution: CentOS 2.6.18-53.1.4.el5
Posts: 770

Rep: Reputation: 44
vi/vim works for root but not for regular user


If I log in as root I can vi/vim a file with no problems. When I log in as a regular user I get the following error when I try to vi/vim.

Quote:
vim: error while loading shared libraries: libgtk-1.2.so.0: cannot open shared object file: No such file or directory
RHEL 5.5 2.6.18-194.el5

We are in a testing/lab environment so the server is not on the RHN.

ldd /bin/vi
libselinux.so.1 => /lib64/libselinux.so.1 (0x0000003eec600000)
libtermcap.so.2 => /lib64/libtermcap.so.2 (0x0000003eeae00000)
libacl.so.1 => /lib64/libacl.so.1 (0x0000003eeba00000)
libc.so.6 => /lib64/libc.so.6 (0x0000003eeaa00000)
libdl.so.2 => /lib64/libdl.so.2 (0x0000003eeb200000)
libsepol.so.1 => /lib64/libsepol.so.1 (0x0000003eec200000)
/lib64/ld-linux-x86-64.so.2 (0x0000003eea600000)
libattr.so.1 => /lib64/libattr.so.1 (0x0000003eef200000)

ldd /usr/local/bin/vim
linux-gate.so.1 => (0xffffe000)
libgtk-1.2.so.0 => not found
libgdk-1.2.so.0 => not found
libgmodule-1.2.so.0 => not found
libglib-1.2.so.0 => not found
libdl.so.2 => /lib/libdl.so.2 (0x008a8000)
libXext.so.6 => /usr/lib/libXext.so.6 (0x0053f000)
libm.so.6 => /lib/libm.so.6 (0x008ae000)
libXt.so.6 => /usr/lib/libXt.so.6 (0x005e3000)
libncurses.so.5 => /usr/lib/libncurses.so.5 (0xf7ea8000)
libacl.so.1 => /lib/libacl.so.1 (0xf7ea1000)
libgpm.so.1 => /usr/lib/libgpm.so.1 (0xf7e9b000)
libc.so.6 => /lib/libc.so.6 (0x00746000)
libX11.so.6 => /usr/lib/libX11.so.6 (0x009d6000)
/lib/ld-linux.so.2 (0x00728000)
libXau.so.6 => /usr/lib/libXau.so.6 (0x00ae3000)
libSM.so.6 => /usr/lib/libSM.so.6 (0x0063d000)
libICE.so.6 => /usr/lib/libICE.so.6 (0x005c7000)
libattr.so.1 => /lib/libattr.so.1 (0xf7e94000)
libXdmcp.so.6 => /usr/lib/libXdmcp.so.6 (0x00adb000)


rpm -qa | grep gtk
gtkhtml3-3.16.3-1.el5
gtkhtml3-3.16.3-1.el5
gnome-python2-gtkhtml2-2.14.2-6.el5
gtk2-2.10.4-20.el5
gtkhtml2-2.11.0-3
pygtk2-2.10.1-12.el5
gtk2-engines-2.8.0-3.el5
gtk2-engines-2.8.0-3.el5
authconfig-gtk-5.3.21-6.el5
gtksourceview-1.8.0-1.fc6
gnome-python2-gtksourceview-2.16.0-3.el5
gtk2-2.10.4-20.el5
usermode-gtk-1.88-3.el5.2
pygtk2-libglade-2.10.1-12.el5


Why does vi/vim work as root and not a regular user? Also what rpm's can I install to get it working? thanks!
 
Old 10-14-2010, 12:30 PM   #2
raybcher
LQ Newbie
 
Registered: Aug 2003
Location: Fredericton NB
Posts: 4

Rep: Reputation: 0
Check library permissions

Ensure "others" have execute permissions on the /usr/lib objects.
 
Old 10-18-2010, 08:09 AM   #3
ncsuapex
Member
 
Registered: Dec 2004
Location: Raleigh, NC
Distribution: CentOS 2.6.18-53.1.4.el5
Posts: 770

Original Poster
Rep: Reputation: 44
/usr/lib and /usr/lib64 both have permissions set to 755 and the libs inside each directory most all of them have r_x for others. There are a handful of libraries with just r for others.

There are the files that are 644 the rest are 755
libbdevid.so.5.1.19.6
libcrack.a
libfreebl3.chk
libmetacity-private.a
libpopt.a
libsoftokn3.chk
libwrap.a


Something else I just found.

Looks like someone manually installed vim-7.1

which vim-7.1
/usr/software/bin/vim-7.1

ls /usr/software/bin/vim
/usr/software/bin/vim



I can use vim with that path as a regular user. What would the best way to fix this? Delete /usr/local/bin/vim and make a link to /usr/local/bin/vim from /usr/software/bin/vim-7.1 or delete /usr/local/bin/vim and add /usr/software/bin to the path of the user?

Last edited by ncsuapex; 10-18-2010 at 09:01 AM. Reason: .
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Different date shown for regular user and root user tuxtutorials Linux - Server 6 11-27-2013 08:33 AM
Youtube works with root, but not a regular user Darrell22 Linux - Networking 5 12-04-2009 12:05 AM
startx works as root but not as regular user Retne Slackware 14 07-04-2009 06:19 PM
CD writing works in root but not for regular user lasindi Linux - Software 5 08-28-2004 11:25 PM
Modem works as root but not as regular user. bmike1 Linux - Software 16 08-30-2003 02:39 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 10:16 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration