2

I have Ubuntu 14.04 which needs the "ftppwd" utility installed.

I'm trying to run a Unix shell script on Ubuntu. The Unix shell script uses the ftppwd command.

As of now FTPPWD utility is not installed hence the command as such is not found on Ubuntu.

vagrant@dev-hadoop:~$ ftppwd; lsb_release -a; uname -a
ftppwd: command not found
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 12.04 LTS
Release:    12.04
Codename:   precise
Linux dev-hadoop 3.2.0-92-generic #131-Ubuntu SMP Tue Oct 20 16:16:02 UTC 2015 x86_64 x86_64 x86_64 GNU/Linux
terdon
  • 100,812
  • There is no such package for Ubuntu, although there is a callable routine by that name in the package ftplib-dev. From what I read, all it does is find out the current default working directory on the FTP server. Perhaps you can determine that directory manually and hardcode it into your script? – Jos Oct 29 '15 at 15:27
  • I understand. However I would not be able to edit the script. I have the FTPLIB-DEV package installed. It does not help. How to make sure all the commands that work on my UNIX box work on my UBUNTU machine as well? – Gayathri Balakumar Oct 29 '15 at 15:43
  • Making sure that all commands work may be a bit of a tall order. But I'm sure someone here can write a small C program that calls ftppwd and can be compiled to an executable program. (I couldn't, though.) – Jos Oct 29 '15 at 15:53
  • What does the script do? What does it use ftppwd for? We might be able to help if you [edit] your question and include the script, or at least, the lines of the script that run ftppwd. – terdon Oct 29 '15 at 15:54
  • Another idea would be to write a bash script called ftppwd that simply outputs the current default working directory that you have manually determined. That way, at least your script will work. – Jos Oct 29 '15 at 15:56
  • What my code is trying to do: String command = "ftppwd” + id + " dqpwd"; Process p = Runtime.getRuntime().exec(command); ======================== However, setting aside what my code does for a minute I am trying to understand how to install this utility. ================= For example from my UNIX box, whereis ftppwd ftppwd: /usr/local/bin/ftppwd.bak /usr/local/bin/ftppwd /usr/local/ftppwd ================ From my UBUNTU box, whereis ftppwd does not return anything. – Gayathri Balakumar Oct 29 '15 at 16:59

0 Answers0