LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 09-06-2012, 11:49 AM   #1
Pscylo
Member
 
Registered: Mar 2008
Distribution: Slackware 13.37 64bit & 32bit
Posts: 48

Rep: Reputation: 2
Environment variable - only root can log in graphically, lots of programs won't start


Like it says on the tin. Since yesterday evening, I've been unable to log in graphically as a regular user though root can do so successfully (if you log in as a user the screen goes black and cycles back to the login screen). I'm assuming I hosed something last night though I was only messing with a DVB stick and was installing patch-utils etc I can't think of anything that would cause the problems I have.

I can log in graphically as root, and can su to a regular user. All files are still there but although I can successfully run ls, cd, vi I can't run vim, mc, pine, opera and mplayer (says command not found).

If I su to a regular user it doesn't appear that I can su back to root. I may be typing the password wrong, but doubt I could consistently make the same error.

The path env variable for users seems very short comparing to root's env variable.

For users:

Code:
/usr/local/bin:/bin:/usr/bin
For root:

Code:
/usr/local/sbin:/usr/sbin:/sbin:/usr/local/bin:/usr/bin:/bin:/usr/games:/usr/lib/ant/bin:/usr/lib/java/bin:/usr/lib/java/jre/bin:/usr/lib/qt/bin:/usr/share/texmf/bin
naturally if I then su (from root - can't do it from a regular user account) the path variable reduces considerably since it's not reading the full environment.

I added a new user, and it seems to come encumbered with the same problems. My guess is that I'm looking for a path/permission issue here as I think the lack of login is no more than a symptom of x not starting (startx manually results in "command not found") and various programs not starting is likely to be as a result of path/permission if it works fine for root.

Any ideas?
 
Old 09-06-2012, 12:24 PM   #2
amani
Senior Member
 
Registered: Jul 2006
Location: Kolkata, India
Distribution: Debian 64-bit GNU/Linux, Kubuntu64, Fedora QA, Slackware,
Posts: 2,766

Rep: Reputation: Disabled
.ICEauthority permission?

But seems to be a more complicated mess.
What did you install?

Last edited by amani; 09-06-2012 at 12:26 PM.
 
Old 09-06-2012, 12:31 PM   #3
Alien Bob
Slackware Contributor
 
Registered: Sep 2005
Location: Eindhoven, The Netherlands
Distribution: Slackware
Posts: 8,559

Rep: Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106
Did you mess up permisisons of /tmp ? (fixed with the command "chmod 1777 /tmp").
Did you install a package for the wrong architecture? Did you install a Slackware package at all or compile some program manually?
What is the output of "uname -a" and "ls -lart /var/log/packages |tail -20" ?

Many more roads to follow but let's see these results first.

Eric
 
Old 09-06-2012, 01:02 PM   #4
Pscylo
Member
 
Registered: Mar 2008
Distribution: Slackware 13.37 64bit & 32bit
Posts: 48

Original Poster
Rep: Reputation: 2
Code:
bash-3.1# ls -lart /var/log/packages |tail -20
-rw-r--r--  1 root root   23736 2012-01-12 14:42 wxGTK-2.8.9-i486-1_SBo
-rw-r--r--  1 root root    1066 2012-01-21 11:55 remind-03.01.11-i486-1_SBo
-rw-r--r--  1 root root   11279 2012-01-31 21:15 irssi-0.8.12-i486-1
-rw-r--r--  1 root root    1973 2012-02-12 15:40 flash-player-plugin-11.1.102.55-i386-1_SBo
-rw-r--r--  1 root root     870 2012-03-02 21:46 memtest86-4.0a-i486-1_SBo
-rw-r--r--  1 root root    2553 2012-03-03 19:08 lshw-B.02.13-i486-1_SBo
-rw-r--r--  1 root root    6137 2012-03-05 23:55 apache-ant-1.7.1-i586-1bj
-rw-r--r--  1 root root   17963 2012-03-23 20:23 qucs-0.0.16-i486-1_SBo
-rw-r--r--  1 root root    4522 2012-03-24 20:24 mathomatic-15.6.4-i486-1_SBo
-rw-r--r--  1 root root  103312 2012-03-25 00:28 maxima-5.24.0-i486-1_SBo
-rw-r--r--  1 root root    1541 2012-04-25 22:41 jaolt-0.6.9.3-1181.noarch
-rw-r--r--  1 root root    1247 2012-05-30 16:48 sqlite-3.6.2-i486-1_SBo
-rw-r--r--  1 root root     986 2012-05-31 13:07 stfl-0.22-i486-1_SBo
-rw-r--r--  1 root root    2885 2012-05-31 13:11 json-c-0.9-i486-1_SBo
-rw-r--r--  1 root root    2710 2012-05-31 13:16 newsbeuter-2.5-i486-1_SBo
-rw-r--r--  1 root root   33270 2012-08-31 00:09 cinepaint-0.22.1-i486-3sl
-rw-r--r--  1 root root   12091 2012-09-05 19:21 dvb-apps-20080512-i686-1an
-rw-r--r--  1 root root    1506 2012-09-05 20:46 patchutils-0.3.0-i486-1_SBo
drwxr-xr-x  2 root root   69632 2012-09-06 08:49 .
drwxr-xr-x 15 root root    4096 2012-09-06 10:23 ..
bash-3.1#
Code:
bash-3.1# uname -a
Linux Pscylo 2.6.24.4lappy-smp #3 SMP Wed May 30 14:46:57 BST 2012 i686 Intel(R) Core(TM)2 Duo CPU     T5670  @ 1.80GHz GenuineIntel GNU/Linux
bash-3.1#
No apparent difference with chmod 1777 /tmp
 
Old 09-06-2012, 01:10 PM   #5
ReaperX7
LQ Guru
 
Registered: Jul 2011
Location: California
Distribution: Slackware64-15.0 Multilib
Posts: 6,558
Blog Entries: 15

Rep: Reputation: 2097Reputation: 2097Reputation: 2097Reputation: 2097Reputation: 2097Reputation: 2097Reputation: 2097Reputation: 2097Reputation: 2097Reputation: 2097Reputation: 2097
Try adding your primary User account to the "Wheel" group.
 
Old 09-06-2012, 02:51 PM   #6
Pscylo
Member
 
Registered: Mar 2008
Distribution: Slackware 13.37 64bit & 32bit
Posts: 48

Original Poster
Rep: Reputation: 2
Well I've solved the "su"ing problem. Still have the running programs/logging in problem to do.
 
Old 09-06-2012, 03:11 PM   #7
Alien Bob
Slackware Contributor
 
Registered: Sep 2005
Location: Eindhoven, The Netherlands
Distribution: Slackware
Posts: 8,559

Rep: Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106Reputation: 8106
It's always polite to tell the people who are trying to help you, how you solved your issues.

Eric
 
Old 09-06-2012, 03:11 PM   #8
Pscylo
Member
 
Registered: Mar 2008
Distribution: Slackware 13.37 64bit & 32bit
Posts: 48

Original Poster
Rep: Reputation: 2
Some more info. I can share the home directory with a dual bootable 64 bit install of Slackware, and it appears that pine (for example) will run fine. Starting X up is a problem on the 64bit install but I think that's unrelated to the issues I'm having here (throws an error about timing out on Xauthority files). The point is that the console software started up fine which implies there's nothing wrong with/in the home directory.

Other than that from a terminal that I su'd to a user account:

Code:
bash-3.1$ pine
bash: pine: command not found
bash-3.1$ which vi
/bin/vi
bash-3.1$ which vim
which: no vim in (/usr/local/bin:/bin:/usr/bin)
bash-3.1$ which startx
which: no startx in (/usr/local/bin:/bin:/usr/bin)
bash-3.1$
And directly from the root account:

Code:
bash-3.1# which vi
/usr/bin/vi
bash-3.1# which vim
/usr/bin/vim
bash-3.1# whoami
root
bash-3.1# which startx
/usr/bin/startx
bash-3.1#
which seems some indication of the oddness since root can start a program such as /usr/bin/vim but the user account reports that "no vim in (/usr/local/bin:/bin:/usr/bin)" which is clearly not the case since root runs /usr/bin/vim.


If I try and run it by the full path from the user account, I get this:

Code:
bash-3.1$ /usr/bin/vim
bash: /usr/bin/vim: Permission denied
Which would imply permission since the path seems to be included within the user account.
 
Old 09-06-2012, 03:13 PM   #9
Pscylo
Member
 
Registered: Mar 2008
Distribution: Slackware 13.37 64bit & 32bit
Posts: 48

Original Poster
Rep: Reputation: 2
Quote:
Originally Posted by Alien Bob View Post
It's always polite to tell the people who are trying to help you, how you solved your issues.

Eric
suid I think. Changing the permissions of su to rws rather than rwx.
 
Old 09-06-2012, 03:31 PM   #10
Pscylo
Member
 
Registered: Mar 2008
Distribution: Slackware 13.37 64bit & 32bit
Posts: 48

Original Poster
Rep: Reputation: 2
Yes, it was permissions. The permission on /bin were set quite differently to /usr/bin so I replicated them. Not sure if the permissions are set correctly now, but I'll double check it against a fairly virginal install later. This is hardly a production machine anyway so I'm sure it will be fine in the sort term.

Anyway, marked as solved.
 
  


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] Upon start up, I am instructed to create a PRINTER environment variable... BMan8577 Linux - Newbie 3 04-17-2011 12:00 AM
Cannot start Tomcat and get "The BASEDIR environment variable is not defined correctl thomas2004ch Linux - Software 1 07-14-2010 05:07 AM
Cannot start vnc server because the USER environment variable is not set izac5 Linux - Newbie 4 11-21-2009 08:10 PM
1:root vncserver: The USER environment variable is not set. Niceman2005 Linux - Software 1 05-24-2006 10:13 PM
programs won't start, even if they do, they won't run smoothly sometimes, why? randytsx Linux - Software 4 12-23-2004 02:19 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 05:32 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