innobackupex should not assume /usr/bin/perl

Bug #892393 reported by aeva black
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Percona XtraBackup moved to https://jira.percona.com/projects/PXB
Fix Released
Low
Stewart Smith
1.6
Fix Released
Low
Stewart Smith
2.0
Fix Released
Low
Stewart Smith

Bug Description

On hosts where perl is not installed in /usr/bin/, the innobackup script fails to find a valid interpreter.

[deva@host ]$ innobackupex --apply-log --use-mem=2G ./
bash: /usr/local/bin/innobackupex: /usr/bin/perl: bad interpreter: No such file or directory
[deva@host ]$ which perl
/usr/local/bin/perl

By comparison, all the percona-toolkit scripts work fine because they begin with:

#!/usr/bin/env perl

instead of:

#!/usr/bin/perl

Related branches

Stewart Smith (stewart)
Changed in percona-xtrabackup:
importance: Undecided → Low
status: New → In Progress
assignee: nobody → Stewart Smith (stewart)
Revision history for this message
Brian Fraser (fraserbn) wrote :

I wonder if using env perl is correct in any case -- for instance, my Linux box didn't have env originally. A nice point of comparison is Tom Christiansen's Unicode::Tussle, particularly the hacks that scripts like unichars ( http://cpansearch.perl.org/src/BDFOY/Unicode-Tussle-1.03/script/unichars ) go through to find a usable Perl.

But this is more of a nitpick than anything, so don't give it too much attention.

Revision history for this message
Stewart Smith (stewart) wrote :

Well... it works on all the platforms we officially support :)

Revision history for this message
Baron Schwartz (baron-xaprb) wrote :

It'll usually work on platforms we don't support, too. I've never seen it fail, personally. If it doesn't work, then I don't think any standard shebang line would work.

Revision history for this message
Shahriyar Rzayev (rzayev-sehriyar) wrote :

Percona now uses JIRA for bug reports so this bug report is migrated to: https://jira.percona.com/browse/PXB-838

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.