Expected Program Not Found in PATH or not Executable

3.1k views Asked by At

I keep running lb build, fixing problem after problem and then running it again, and now i'm getting this message:

dpkg: warning: 'start-stop-daemon' 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)
P: Begin unmounting filesystems...
P: Saving caches...
Reading package lists... Done
Building dependency tree... Done

I then went to check my path and i see

/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin

This clearly shows /usr/local/sbin, /usr/sbin, and /sbin.

Any suggestions?

**UPDATE 1**

Followed this guide

http://ubuntuforums.org/showthread.php?t=1449322

every command ran fine but still the same error message after running lb build again.

**UPDATE 2 -- Additional Info**

root@kali:~# ls -lA /sbin (Other files) -rwxr-xr-x 1 root root 28208 Aug 12 15:00 start-stop-daemon

2

There are 2 answers

0
juhengzhe On

First, you must check the feedback information from the first line (although it is just a warning).

Then, you must have understand that the warning is the key. All the mistakes are caused by this warning. You have to add start-stop-daemon to your pc.

According to the following:

cd /tmp
wget http://developer.axis.com/download/distribution/apps-sys-utils-start-stop-daemon-IR1_9_18-2.tar.gz
tar zxf apps-sys-utils-start-stop-daemon-IR1_9_18-2.tar.gz
cd apps/sys-utils/start-stop-daemon-IR1_9_18-2/
gcc start-stop-daemon.c -o start-stop-daemon
cp start-stop-daemon /usr/local/bin/start-stop-daemon

Now you can help yourself,and others

0
centic On

I have the same problem, according to https://debianforum.de/forum/viewtopic.php?f=34&t=155279 (in german) the only known solution is to run sudo lb clean before sudo lb build.