Use exec to move file on Linux?

Hi,
I am trying to move a file from one directory to another using the exec function in DS, here is my script:
exec('/bin/sh', ' -c "mv /sapmnt/DSD/DataServices/Incoming/GCL/Neulion/test.dat  /sapmnt/DSD/DataServices/Successful/GCL/Neulion"', 8);
My script works, except it move the entire Neulion directory instead of the file test.dat.
Does anyone have any idea why?
TIA

why don't you give file name as mentioned below:
exec('/bin/sh', ' -c "mv /sapmnt/DSD/DataServices/Incoming/GCL/Neulion/test.dat  /sapmnt/DSD/DataServices/Successful/GCL/Neulion/test.dat"', 8);
Bold part if added part.

Similar Messages

  • I would like to use FireWire to move files between 2 iBook G3's.

    I would like to use FireWire to move files between 2 iBook G3's but the disk icon for the target disk computer does not show on the other. I've tried using 3 different iBooks and 2 different Firewire cables. Are there any other settings I should use?  Any ideas?
    Thanks in advance,
    Mike

    Check the settings in the General tab of the Finder's preferences, and whether or not the drive appears in the Disk Utility.
    (79213)

  • Problems using CFFile to move files

    Hi there - I am having some problems using CFFile to move
    files from one directory to another. It only seems to only move
    some of the files in the group that I choose to move over, and
    there is nothing specific about which files are moved - different
    files are moved each time. There are no error messages that are
    showing up, so I am totally baffled. Has anyone else experienced
    this or does anyone else have any ideas on how to fix this problem?
    Any help would be much appreciated!! My code is below.

    First, an incidental matter. I don't think there's any need
    for so many try-catch tags. I would expect all the tags <cffile
    action="move"> to throw the same class of exception, and so
    would use one try-catch for them all. Even if you expect different
    exceptions to be thrown, one cftry tag might still be sufficient,
    if implemented as follows
    <cftry>
    <!--- code block 1 --->
    <!--- code block 2 --->
    <!--- ... etc... --->
    <cfcatch type="exceptionType1"></cfcatch>
    <cfcatch type="exceptionType2"></cfcatch>
    <!--- ... etc... --->
    </cftry>
    I suspect the cause of the problems lies in the dynamic
    values that you give the attributes. Perhaps incorrect values are
    passed for the source and/or destination values in certain
    circumstances. As A3gis has said, if that were to happen you
    probably wouldn't notice, because of the try-catches. Find a way to
    ensure that all the generated values for source and destination are
    correct.

  • Use Automator to move files and folder structure to another folder, retaining destination contents

    I have been struggling trying to setup Automator to move files and folder structure to another folder, retaining the destination contents.  Basically, I need to add files at the destination, within the same folder structure that exists at the source.  Here's some details about the scenario:
    -I have PDF files that I create on a seperate computer than I my daily use machine
    -For security reasons, the source computer doesn't have access to any shares on the destination computer
    -The destination computer has access to shares on the source computer
    -I want to delete the original PDFs at the source after they are moved or copied
    I haven't been able to get Automator to move or copy the folder contents (files and subfolders) without dropping everything copied at the top level of the destination, resulting in many duplicate folders and a broken folder structure.
    So far I've only had luck getting this to work at the command line, but I'd really like to have this setup in Automator so that I could have either a service or application that I could use for any folder, prompting for the source and destination folders.  I'm a relatively new Mac user with limited Linux experience, so this is the command that I've cobbled together and currently accomplishes what I'm looking for:
    ditto /Volumes/SMB_Temp/SOURCE ~/Desktop/Documents/DESTINATION
    cd /Volumes/SMB_Temp/SOURCE
    find . -type f -name "*.pdf" -exec rm -f {} \;
    Thanks for any ideas!

    If you have a command-line syntax that works, why not just create an Automator workflow with a single 'Utilities -> Run Shell Script' action, where that action has your (working) shell commands?
    Seems way, way simpler to me than trying to reinvent the wheel and transcribe shell commands into individual Automator actions

  • How do I find the codec used for a .mov file?

    I have a .mov file from 2001 that I can't play. How do I find the correct codec to use for this. Is there somewhere in the file itself some kind of reference to the codec used? I've installed pretty much everything I could find in terms of codecs. I don't care whether on mac or windows. Just need the right codec.
    Thorbjørn Vynne

    Still no luck
    If anybody out there wanna give it a try please download this clip
    http://mhp.tv2nord-digital.dk/fileadmin/resources/thor/dv-00.27.04.11-V180.mov
    If you can play it please please let me know with which codec.... I have a whole bunch of files with this codec I need to use
    Best regards
    Thorbjørn

  • Trouble using or encoding mov files

    I am operating on Mac OS 10.8.3.  I am trying to import some .mov files that were recorded using the Canon XF 105 and 305. Opposed to being shot on CF card, the cameras were connected to a Newtek tricaster 855. The footage is from the drives attached to the Tricaster. The files play on quicktime and VLC but do not work when i try to import them with Adobe products including Premiere Pro and Encoder.    
    I tried setting the sequence to Canon XF MPEG 2 but had no luck.
    Does anyone have any suggestions or need anymore information?

    Report back with the codec details of your file, use the program below... A screen shot works well to SHOW people what you are doing
    http://forums.adobe.com/thread/592070?tstart=30
    For Mac http://mediainspector.massanti.com/

  • Best codec to use to encode MOV files? H.264?

    Adobe Premiere CS5 beginner here, though I have used earlier versions of Premiere Elements quite a bit.
    I'm trying to export video clips for web viewing. These clips must be in MOV format (i.e. no mp4, flv, etc). Some of them are high-motion and I'd like the best possible quality with reasonable filesize, but not sure what codecs offered by Premiere are best. I tried using the Quicktime H.264 codec, but the control panel options are limited (no options for 2-pass VBR, setting min/max bitrates, etc) and honestly the result was surprisingly blocky.
    Is there a way to expand the control panel for Quicktime H.264? Or is there a preferable QT codec offered in CS5? Any help would be much appreciated...

    Because the gallery software I'm currently using presents MOV files much better than the other formats. I'll be changing this in the future, but for now MOV is what I've got to work with.

  • Use Automator to move files to trash

    I've spent quite a bit of time trying to work out how to move files with automator to another folder - finally worked this out using a folder action.
    I am now trying to do similar, but this time using a folder action to move files to the trash.  Again, I don't seem to be getting this right.  I have the following:
    There are definitely files in the folder that meet the criteria - but the workflow is not working.  Any suggestions, please?
    Cheers,
    Mike

    sdiaz34 wrote:
    The external hard drive was partitioned to have a back up drive for time machine and another drive for other (pics&vids) use.
    If it is possible can the automator task then trash all files in original pictures subfolder when task is complete to avoid any memory use on macbook air?
    You really don't want to do that. 
    You'll have only one copy of the files, on the external HD.  When (not if) it fails, they'll be lost.  
    For best results, get another external HD for your photos.  Then let Time Machine back up both your internal HD and the external.  See Time Machine - Frequently Asked Question #32 for details.

  • Using .motn and .mov files in FCP

    I am starting to use Motion much more in FCP Projects and I was just wondering if I should using .motn files in my FCP timeline in most circumstances or is there a time when actually having the .mov file is better?  Other then render time is there much advatange or disadvantage from one to the other? 

    Better depends on the project and what you need.  I look at it this way:
    Use .motn
    -If I think I will have many revisions to the effect.
    Use .mov
    -When I have to send the result to some who doesn't have Final Cut
    -When I'm sure things are not going to change.

  • Using 16:9 .mov file in iDVD

    Hello,
    When I add my 16:9 .mov video, created in FCP with Export: Quicktime Movie: DV PAL anamorphic to iDVD I get a 4:3 video.
    I changed to .mov file with QT: properties: conform aperture, but this does not help.
    I have an old .mov file from February where I have no problems that iDVD is converting the 16:9 to 4:3.
    How can I get a 16:9 video in iDVD ?
    Thanks,
    Hubert Anemaat

    I have managed to burn with iDVD and 16:9 no problem exporting movies out of both iMovie09and FCE.
    What theme are you using? Some of the themes in iDVD are 4:3 themes and may very well mess up your movie?
    If you want one of the 4:3 themes, you can always letterbox your 16:9 movie so that it has black bands top and bottom and fills the 4:3 window. But that diminishes the visual size of the movie.
    Otherwise be sure that you have selected a widescreen iDVD theme.
    Terri

  • Can't use HDV quicktime .mov files (captured in Final Cut Pro) on a mac at work) on my PC at home

    Hiya everyone!
    I've taken some work home from the macs at work, but can't open it on my PC.
    Footage was captured in FCP on a mac at work, HDV quicktime .mov, but won't open in the newest quicktime, windows media player and more importantly in Adobe After Effects CS3 or Premiere Pro CS3 on my PC at home.
    When I try opening the files in quicktime, the screen is white, but the audio plays. They don't open in windows media player at all. When I try to import them into Premiere, I get a message reading, "Error Message, Codec missing or unavailable". But they import into After Effects, except they only play as white...
    I've tried converting them into almost everything, and they often play (as .avi for example in the newest QT, WMP, Adobe Premiere and AE), but they increase A LOT in size and decrease A LOT in quality.
    The HDV files that won't open read as:
    Source: *.mov
    Format: HDV 1080i50, 1920 x 1080, Millions 16-bit Integer (Little Endian), 48.000 kHz
    Movie FPS: 25.00
    Playing FPS: (Available when playing)
    Data Size: 69.53 MB
    Data Rate: 28.10 mbits/sec
    Current time: 00:00:01.64
    Duration: 00:00:20.76
    Normal size: 1920 x 1080
    Current size: 1920 x 1080
    Anything smaller than 1920 x 1080 plays fine.
    I've been all through google, and the adobe and apple sites, and the best I could find is here:
    http://discussions.apple.com/message.jspa?messageID=7753066#7753066
    and
    http://discussions.apple.com/thread.jspa?messageID=8159317&#8159317
    My problem is almost identical to these 2...
    No one in the whole world seems to have an answer...
    Does anyone here know how I can use the HDV files from the work macs on my PC at home?
    -Kaiwin

    As a rule of thumb, any CoDec associated with the Apple Pro applications is generally not available on Windows. This also includes their flavor of HDV. The only exception at this point is ProRes, for which they added a player component recently. So therefore this would have to be what you use for capture/ export from FCP. Apart from that you can of course always buy a capture card from Blackmagic or AJA with the benefit of the CoDecs being available cross-platform... Or you use a commercial software-only CoDec like Cineform.
    Mylenium

  • Can't use HDV quicktime .mov files (captured in FCP on a mac at work) on PC

    Hiya everyone!
    I've taken some work home from the macs at work, but can't open it on my PC.
    Footage was captured in FCP on a mac at work, HDV quicktime .mov, but won't open in the newest quicktime, windows media player and more importantly in Adobe After Effects CS3 or Premiere Pro CS3 on my PC at home.
    When I try opening the files in quicktime, the screen is white, but the audio plays. They don't open in windows media player at all. When I try to import them into Premiere, I get a message reading, "Error Message, Codec missing or unavailable". But they import into After Effects, except they only play as white...
    I've tried converting them into almost everything, and they often play (as .avi for example in the newest QT, WMP, Adobe Premiere and AE), but they increase A LOT in size and decrease A LOT in quality.
    The HDV files that won't open read as:
    Source: *.mov
    Format: HDV 1080i50, 1920 x 1080, Millions 16-bit Integer (Little Endian), 48.000 kHz
    Movie FPS: 25.00
    Playing FPS: (Available when playing)
    Data Size: 69.53 MB
    Data Rate: 28.10 mbits/sec
    Current time: 00:00:01.64
    Duration: 00:00:20.76
    Normal size: 1920 x 1080
    Current size: 1920 x 1080
    Anything smaller than 1920 x 1080 plays fine.
    I've been all through google, and the adobe and apple sites, and the best I could find is here:
    http://discussions.apple.com/message.jspa?messageID=7753066#7753066
    and
    http://discussions.apple.com/thread.jspa?messageID=8159317&#8159317
    My problem is almost identical to these 2...
    No one in the whole world seems to have an answer...
    Does anyone here know how I can use the HDV files from the work macs on my PC at home?
    -Kaiwin

    HEy, I have been looking into this problem... i also wanted to play quicktime files using my pc... The last thing i tried was downloadiing these codecs
    1)apple pro res *for pc
    2)mpeg 2 codec for pc
    I have HDV files captured on a Mac G5 they are 30p 720,
    I think i am close to solving the problem because: before installing the codecs i couldn't see the video and only audio.. but now i open it and i can see the video partially... here are my screen captures....
    anyone interested in getting this solved???,... i would also like some help in importing m2t files from VLC player to HDV split where they can be read and edited. Thank you.
    Ultimately my goal is to be able to edit these HDV files directly and export them back out with good quality.. because my only editing choice right now is Windows movie maker.
    this is an error i got from the HDV split program. Its supposed to read m2t files..

  • I was wondering if it was possible to use Automator to move files based on the filename.

    Hi,
    I'm kind of new to Automator and I'm trying to come up with a sequence that will severely save me a few hours a day moving files from two larger folders into smaller folders. Basically the setup is that I have two folders, one constantly being populated with images and the other with video files. They each have file names starting with a two digit number (i.e. 12, 11, 10...) or "BG" and then a two digit number (i.e. BG12, BG11, BG10...) with the digits corresponding to a year. Essentially, I'd need to move the files into folders corresponding to the year (i.e. files starting with BG12 and 12 would be moved to 2012, files starting with BG11 and 11 would be moved to 2011, etc). As it stands now, I've only been able to get the 2012 folder populated. Any help would be greatly appreciated. Thanks.

    Hi,
    Here's a solution that uses a script, because it is not possible, at least to make twenty or more Workflows
    In Automator :
    Create a new worflow.
    Add the action "Run Shell Script", select "/bin/bash" in the popup menu
    Cut the text in the action.
    Copy/paste this script in the action :
    targetsDir=('/Users/jack/Desktop/MyImagesFolder' '/Users/jack/Desktop/MyVideosFolder')
    destDir=('/Users/jack/Desktop/yearImageFolder' '/Users/jack/Desktop/yearVideoFolder')
    for i in 0 1;do
          subfolder="${destDir[$i]}"/20
          for each in "${targetsDir[$i]}"/*;do
                if [ ! -d "$each" ];then ## not a directory
                      name=${each##*/};
                      if [[ $name =~ ^([0-9]{2})|^..([0-9]{2}) ]]; then
                            [[ $name =~ ([0-9]{2}) ]] && year=${BASH_REMATCH[1]};
                            /bin/mv -n "$each" "$subfolder$year"
                      fi
                fi
          done
    done
    Replace the paths in the first line by the path of your Images Folder  and Video Folder, use drag/drop between the simple quote ''
    Replace the paths in the second line by the path of your destibation Folders, use drag/drop between the simple quote ''.
    This script will not overwrite existing files, If you want to replace the existing file, use the /bin/mv -f instead of /bin/mv -n
    That's it.

  • Using "848x480, 60fps, .mov" files in FCP

    Here's my scenario:
    Source files:
    .mov
    60fps
    848x480
    Intended use:
    I want to slow down these files to 30fps so that they're in slow motion.
    Question:
    How can I do this most efficiently?
    Question:
    Can I convert these files to slow motion outside of Final Cut Pro to save time and promote efficiency?

    Use Cinema Tools to "Conform" them to a new frame rate...
    This doesn't alter the picture data (odd dimensions, btw), it simply changes the playback rate setting in the QuickTime movie.
    Patrick

  • Is there a footpedal that can be used to run movie files using QuickTime?

    I'm a musician and need to run some movie clips using a footpedal.  Any suggestions?

    Check whether this might work:
    http://www.vpedal.com/

Maybe you are looking for