LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 04-20-2012, 05:47 AM   #1
Robelish
LQ Newbie
 
Registered: Apr 2012
Posts: 3

Rep: Reputation: Disabled
Path problem, when updating.


Hello so when im trying to update my packages i get this error.


dpkg: warning: 'ldconfig' not found in PATH or not executable.
dpkg: error: 1 expected program not found in PATH or not executable.
Note: root's PATH should usually contain /usr/local/sbin, /usr/sbin and /sbin.
E: Sub-process /usr/bin/dpkg returned an error code (2)

I also get the same when i do it with sudo.

Im using LinuxMint 12 kde.
Ive sneaked around trying to solve it But i havnt got a decent result yet.
 
Old 04-20-2012, 07:22 AM   #2
pan64
LQ Guru
 
Registered: Mar 2012
Location: Hungary
Distribution: debian/ubuntu/suse ...
Posts: 9,904

Rep: Reputation: 2921Reputation: 2921Reputation: 2921Reputation: 2921Reputation: 2921Reputation: 2921Reputation: 2921Reputation: 2921Reputation: 2921Reputation: 2921Reputation: 2921
are you sure ldconfig is available?
 
Old 04-20-2012, 07:37 AM   #3
Satyaveer Arya
Senior Member
 
Registered: May 2010
Location: Palm Island
Distribution: RHEL, CentOS, Debian, Oracle Solaris 10
Posts: 1,415

Rep: Reputation: 305Reputation: 305Reputation: 305Reputation: 305
In this case, secure_path option needs to be set in /etc/sudoers file.
and after this line in /etc/sudoers file:
Quote:
Defaults env_reset
add this-
Quote:
Defaults secure_path="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"
and then updation process should work fine.
 
Old 04-20-2012, 08:38 AM   #4
VDP76
Member
 
Registered: Apr 2010
Location: Bayreuth, Germany
Distribution: CrunchBang Linux (#!)
Posts: 111

Rep: Reputation: 19
Quote:
Originally Posted by Robelish View Post
Ive sneaked around trying to solve it But i havnt got a decent result yet.
as a suggestion, when you have issues try to searching LQ first, often the solution for you is already out there...
 
Old 04-20-2012, 11:15 AM   #5
Robelish
LQ Newbie
 
Registered: Apr 2012
Posts: 3

Original Poster
Rep: Reputation: Disabled
Defaults env_reset
Defaults secure_path="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"

Thats how my sudoers looks like, and i still get problems updating.

Last edited by Robelish; 04-20-2012 at 12:57 PM.
 
Old 04-20-2012, 03:30 PM   #6
Robelish
LQ Newbie
 
Registered: Apr 2012
Posts: 3

Original Poster
Rep: Reputation: Disabled
Am i missing somthing here or :S, anyone got some more i can work with?
 
Old 04-20-2012, 06:52 PM   #7
VDP76
Member
 
Registered: Apr 2010
Location: Bayreuth, Germany
Distribution: CrunchBang Linux (#!)
Posts: 111

Rep: Reputation: 19
it seems like those two lines are the "usual" solution to this problem.
I'll try just a shot in the dark: have you checked the permissions of your sudoers file??
Code:
ls -l /etc/sudoers

Last edited by VDP76; 04-20-2012 at 06:54 PM.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
Do I have a path problem, an Apache2 problem or a Javascript problem or any other pro rblampain Linux - Networking 0 12-29-2010 04:50 AM
cant "source" bash script with arguments (PATH updating) monkey_king Linux - General 5 12-30-2008 05:34 AM
Updating $PATH and adding packages manimal29 Linux - Newbie 2 07-15-2008 12:24 PM
updating /usr/bin/ld path ??? n00bDanimal Linux - Newbie 6 03-22-2007 12:13 AM
Pernmanently updating PATH Tamsco Mandriva 3 08-15-2004 06:58 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 03:14 PM.

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
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration