Bug 171736 - kadischi won't build using sudo account
kadischi won't build using sudo account
Product: Fedora
Classification: Fedora
Component: kadischi (Show other bugs)
All Linux
medium Severity medium
: ---
: ---
Assigned To: Chitlesh GOORAH
Darko Ilic
Depends On:
  Show dependency treegraph
Reported: 2005-10-25 14:46 EDT by Luya Tshimbalanga
Modified: 2007-11-30 17:11 EST (History)
0 users

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2006-05-29 12:58:52 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)
patch that fixed path (8.55 KB, text/x-patch)
2005-10-25 15:04 EDT, Luya Tshimbalanga
no flags Details

  None (edit)
Description Luya Tshimbalanga 2005-10-25 14:46:06 EDT
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.8b5) Gecko/20051008 Fedora/1.5-0.5.0.beta2 Firefox/1.4.1

Description of problem:
This scenario applied when an users use kadischi with sudo account causing
problem with commands that require root privilege. For example, anaconda command 
will fail if sudo users tries to use it. The correct path should be /usr/sbin/chroot instead.

Version-Release number of selected component (if applicable):

How reproducible:

Steps to Reproduce:
1. Use kadischi with sudo account

Actual Results:  Error generated by commands such as chroot

Expected Results:  kadisci should build livecd with sudo privilege

Additional info:

A complete generated codes:

$ sudo kadischi http://fedora.mirrored.ca/fedora/4/i386/os/ /tmp/livecd/fedora-live.iso
Sorry, try again.
Starting kadischi...
Parsing command line arguments
Checking UID
Using buildstamp file /etc/kadischi/buildstamp.
Product path set to Fedora.
Now we are going to try to validate your repository (for now, only http, ftp and local repositories can be checked)
URL http://fedora.mirrored.ca/fedora/4/i386/os contacted. OK
URL http://fedora.mirrored.ca/fedora/4/i386/os/Fedora contacted. OK
URL http://fedora.mirrored.ca/fedora/4/i386/os/Fedora/base contacted. OK
URL http://fedora.mirrored.ca/fedora/4/i386/os/Fedora/RPMS contacted. OK
Repository seems to be OK.
Checking required packages
Looking for config file
Loadnig config file options

  ***  running anaconda  ***

* Display mode = t
* Method = http://fedora.mirrored.ca/fedora/4/i386/os
Probing for video card:   NVIDIA GeForce FX (generic)
Probing for monitor type:   L1730S
Probing for mouse type:   Skipped mouse probe.
* anaconda floppy device fd0

  ***  anaconda has finished the job ***

running post installation scripts
/usr/local/share/kadischi/post_install_scripts/04auth.sh: line 3: chroot: command not found
/usr/local/share/kadischi/post_install_scripts/04auth.sh: line 5: chroot: command not found
/usr/local/share/kadischi/post_install_scripts/04auth.sh: line 7: chroot: command not found

  ***  Fatal error: /usr/local/share/kadischi/post_install_scripts/04auth.sh returned non zero (32512) exit code. Aborting execution.

Cleaning up temporary files...

Traceback (most recent call last):
  File "/usr/local/share/kadischi/kadischi.py", line 248, in ?
    run ("%s %s" % (script, sysdir), builddir)
  File "/usr/local/share/kadischi/lib/functions.py", line 115, in run
    cleanup (builddir)
  File "/usr/local/share/kadischi/lib/functions.py", line 107, in cleanup
    clean_directory (builddir)
  File "/usr/local/share/kadischi/lib/functions.py", line 83, in clean_directory    keep_child_directories)
  File "/usr/local/share/kadischi/lib/functions.py", line 83, in clean_directory    keep_child_directories)
  File "/usr/local/share/kadischi/lib/functions.py", line 83, in clean_directory    keep_child_directories)
  File "/usr/local/share/kadischi/lib/functions.py", line 80, in clean_directory    if os.path.isdir (path) and not os.path.islink (path):
  File "/usr/lib/python2.4/posixpath.py", line 195, in isdir
Comment 1 Luya Tshimbalanga 2005-10-25 15:04:12 EDT
Created attachment 120379 [details]
patch that fixed path

set the correct path for anaconda as /usr/sbin/anaconda
Comment 2 Jasper O. Hartline 2005-11-02 14:34:55 EST
(In reply to comment #1)
> Created an attachment (id=120379) [edit]
> patch that fixed path
> set the correct path for anaconda as /usr/sbin/anaconda

I'm stumped.
Thats not a patch file.
Where in the file was /usr/bin/anaconda changed?
Why would /usr/bin/anaconda need to be changed if your kadischi is faiing
looking for chroot? To my knowledge, anaconda != chroot.

Could you elaborate a little further please?
Comment 3 Jasper O. Hartline 2005-11-02 21:06:59 EST
You might just get away scott free with this one, by first exporting a root-like
$PATH, since sudo does not inherit root's environment, chroot is not going to be
found. Just a suggestion, try that and see if it works.

e.g. [user@localhost]# export PATH=$PATH:

The colons, seperate each directory path.
Comment 4 Jasper O. Hartline 2006-01-23 13:45:45 EST
Could the poster of comment #1 repost with a patch file included.
Surely we can get this stuff into CVS.
Comment 5 Luya Tshimbalanga 2006-05-29 12:58:52 EDT
The patch is practically useless which the current kadischi status. I am closing
this bug report.

Note You need to log in before you can comment on or make changes to this bug.