Bug 508724

Summary: collectl changes cwd
Product: [Fedora] Fedora Reporter: James M. Leddy <james.leddy>
Component: collectlAssignee: Dan Horák <dan>
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: medium Docs Contact:
Priority: low    
Version: 11CC: dan, gborsuk, kzak
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: 3.3.4-2.fc10 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2009-07-19 10:21:23 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description James M. Leddy 2009-06-29 16:26:27 UTC
The collectl wrapper script changes the current working directory, thus making things confusing.  

$ collectl -p file.raw.gz -sJ -oT --from 07:02:40 --thru 07:04:40
Error: can't find 'file.raw.gz'
type 'collectl -h' for help
$ collectl -p $(pwd)/file.raw.gz -sJ -oT --from 07:02:40 --thru 07:04:40

# INTERRUPT DETAILS
#          Int    Cpu0   Cpu1   Cpu2   Cpu3   Cpu4   Cpu5   Cpu6   Cpu7   Type            Device(s)
etc...



$ cat $(which collectl)
#!/bin/sh
cd /usr/libexec/collectl
exec /usr/bin/perl collectl.pl $@


I'm wondering if it's strictly necessary to change directory.  Do the perl scripts require you to be _in_ /uer/libexec/collectl in order to execute them?  In this particular case I was able to run the perl script without a problem w/o changing directory.

Comment 1 Dan Horák 2009-06-29 17:51:49 UTC
Probably it was required in the past, now the modules are loaded with absolute path, where the dirname part is taken from the path of the main script. I will replace the startup script with a symlink pointing to /usr/libexec/collectl/collectl.pl as upstream is doing.

Comment 2 Fedora Update System 2009-06-29 18:05:18 UTC
collectl-3.3.4-2.fc11 has been submitted as an update for Fedora 11.
http://admin.fedoraproject.org/updates/collectl-3.3.4-2.fc11

Comment 3 Fedora Update System 2009-06-29 18:05:23 UTC
collectl-3.3.4-2.fc10 has been submitted as an update for Fedora 10.
http://admin.fedoraproject.org/updates/collectl-3.3.4-2.fc10

Comment 4 Fedora Update System 2009-07-02 05:48:33 UTC
collectl-3.3.4-2.fc10 has been pushed to the Fedora 10 testing repository.  If problems still persist, please make note of it in this bug report.
 If you want to test the update, you can install it with 
 su -c 'yum --enablerepo=updates-testing update collectl'.  You can provide feedback for this update here: http://admin.fedoraproject.org/updates/F10/FEDORA-2009-7231

Comment 5 Fedora Update System 2009-07-02 05:52:13 UTC
collectl-3.3.4-2.fc11 has been pushed to the Fedora 11 testing repository.  If problems still persist, please make note of it in this bug report.
 If you want to test the update, you can install it with 
 su -c 'yum --enablerepo=updates-testing update collectl'.  You can provide feedback for this update here: http://admin.fedoraproject.org/updates/F11/FEDORA-2009-7264

Comment 6 Fedora Update System 2009-07-19 10:21:18 UTC
collectl-3.3.4-2.fc11 has been pushed to the Fedora 11 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 7 Fedora Update System 2009-07-19 10:23:47 UTC
collectl-3.3.4-2.fc10 has been pushed to the Fedora 10 stable repository.  If problems still persist, please make note of it in this bug report.