From: Daniel C. <dan...@gm...> - 2012-07-20 22:39:46
|
Hey Ed, I think we've all done this at some point... :) I spent ages trying to work out why a file didn't exist on a live PHP server when I was sending to the development one by mistake. On 20 July 2012 15:12, Ed Hochman <cha...@ho...> wrote: > > Nevermind. I made a stupid error. > > So stupid I'm embarrassed to confess. > > But here goes anyway: I was SSHing to one box where the command worked and > WEBMINing to another where the command didn't exist! > ________________________________ > From: cha...@ho... > To: web...@li... > Subject: Custom Commands: "not found" error > Date: Wed, 18 Jul 2012 12:30:58 -0400 > > > Hi, My first post to this list. > > I wrote a simple script called update-newer to copy some files. Here are > the first few lines: > > #!/bin/bash > # > # Just a Q&D to copy files from one server to another > # Assumes remote drive (starting at /) > # is already mounted at /root/remotesvr > # See /root/Desktop/todo for mounting requirements > # > # Start the copying > echo "Copy newer files from remote" > echo "M Drive:" > cp -ruvp /root/remotesrvr/home/"M Drive"/* /home/"M Drive" > echo "N Drive" > ... > > > This script won't run from "Custom Commands". I just get "Output from > /sbin/update-newer .. /bin/sh: /sbin/update-newer: not found ". It works > fine from a Linux terminal (console). > > In testing I created two identical scripts. One in /root and the other in > /sbin. Both owned by root with execute permissions. > > The custom commands I've tried are like this: > > /root/update-newer > /sbin/update-newer > and specifying running from one of the two directories and using > ./update-newer > > > None of these work and always the same message: "not found". > > Other commands work fine. For example, I have a custom command that just > does "dmraid -r". It works. > > Is there something about my script? > > Thanks for any assistance. > > > > > > ------------------------------------------------------------------------------ > Live Security Virtual Conference > Exclusive live event will cover all the ways today's security and > threat landscape has changed and how IT managers can respond. Discussions > will include endpoint security, mobile security and the latest in malware > threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ > - > Forwarded by the Webmin mailing list at web...@li... > To remove yourself from this list, go to > http://lists.sourceforge.net/lists/listinfo/webadmin-list > |