3 Replies Latest reply on Oct 4, 2010 7:25 AM by homermg

    deploy txt file

    Apprentice

      Hi all,

       

      i would like to deploy a txt file to folder that i have create first. (on mac)

      I'm not sure how i can do this? I have tried the "New file transfer script" but i allways recieve an error: Unkon status code (0x8DB0007F,3504:127)

       

      or im doing wrong is there an another way to do this?

       

      can anyone help me please?

       

      Im using LDMS 9.0.0.473 and V9 agents

      That is my script:

      [JOBPARAM]
      MAX_MULTICAST_THREADS=5
      MAX_MC_FAILURES_THREADS=240
      STEPS=1
      [MULTICAST]
      FILE=http://test/test.txt
      FILE_TTL_TARGET=172800
      FILE_TTL_SUBREP=1209600
      BANDWIDTH_LAN=90
      BANDWIDTH_WAN=60
      WAKE_ON_LAN=0
      WAIT_FOR_WAKE_ON_LAN=120
      [MACHINES]
      REMEXEC0=<qt/>%LDMS_CLIENT_DIR%\sdclient.exe<qt/> /f /p="http:/test/test.txt" /dest="\Library\Application Support\test.txt" /lan=90 /wan=60

       

       

      cheers

        • 1. Re: deploy txt file
          Employee

          Hi Homermg,

           

          I am not sure if all of those LANDesk scripting options work on Mac's but I see at least one big issue, sdclient.exe does *not* exist in a Mac, you should just call 'sdclient' (without the .exe), also you seem to be using the wrong slashes, ( '\' -> Windows, '/' -> Unix).

           

          Also, the %LDMS_CLIENT_DIR% seems to be a Windows only environment variable, unix one should be something like $MYVAR.

          If the %VAR% does not work you can write the full ldscan path, "/Library/Application Support/LANDesk/bin".

           

           

           

          If you are not able to get it to work you can try setting just the following options in the script.

           

          [MACHINES]

          ;This will download the file

          REMEXEC0="curl http://test/test.txt -o test.txt -s"

          ;This will move the file to the path you require

          REMEXEC1="mv test.txt /Library/Application Support/test.txt"

           

          If this still fails, check if you can move the file to a different folder, try using /tmp.

          • 2. Re: deploy txt file
            Apprentice

            If this is just a static text file, why don't you just package it up with Package Maker or Iceberg and deploy the package?

             

            Or you can create a shell script that looks something like this:

            #!/bin/sh
            
            curl -s http://server/test.txt /Library/Application\ Support/test.txt
            

             

            Save that with a .sh extension, make it executable (chmod +x script.sh), zip it up and deploy that as a distribution package.

            • 3. Re: deploy txt file
              Apprentice

              thank you guys!