DXi Collect Auto Upload script

Overview

The attached AutoUpload.zip file incudes the autoUpload script called dataCollect.pl and a small install script file called installDC.sh. The install file copies dataCollect.pl to /opt/DXi/scripts and adds the following cron entry to /etc/crontab:   

 

00 8 * * * root /usr/bin/perl /opt/DXi/scripts/dataCollect.pl >> /root/dc.out 2>&1

 

This script can be used on galaxy 1.x and all 2.x systems.  dataCollect.pl does the following:

 

 

The location to where files are uploaded is controlled using $ftpDir and can/should be modified for each customer if possible:

 

  1. Find the following section within dataCollect.pl:

 

# Initialize FTP variables

my $ftpHost = '146.174.225.50';

my $ftpDir = '/incoming/ASPS/2.0AutoUpload';

 

  1. Change the path in $ftpDir to desired location

# Initialize FTP variables

my $ftpHost = '146.174.225.50';

my $ftpDir = '/incoming/ASPS/CustomerName'

 

  1. Login to gps.quantum.com using sw_support and create the folder listed in step 2

 

 


Instructions

The files in the attached zip are in Unix format and with the following instructions chaning permissions is not required.

  1. Download AutoUpload.zip either from the attatchment tab or here: AutoUpload.zip
  2. Use winscp or other scp tool to copy AutoUpload.zip to DXi in /root
  3. ssh to DXi as root
  4. unzip file
    1. unzip AutoUpload.zip
  5. Make sure you are in /root.  Should be there if logged in as root via ssh
    1. pwd
  6. Install script and configure cron by typing:
    1. bash installDC.sh

The install script is simple and shouldn't require additional work.  However, you can confirm that the script was installed and that cron was configured properly by:

  1. Check to see if script is located in proper location
    1. ls /opt/DXi/scripts/dataCollect.pl
    2. If the file isn't there then it can manually be copied from /root where the zip file was extracted
  2. Verify that cront entry was added:
    1. tail /etc/crontab
    2. You should see the following line
      1. 00 8 * * * root /usr/bin/perl /opt/DXi/scripts/dataCollect.pl >> /root/dc.out 2>&1
    3. This will be added to /etc/crontab each time the install script is run.

 

 

 

Attachments
Title Last Updated Updated By
AutoUpload.zip
02/25/2011 02:16 PM Tom McFaul


This page was generated by the BrainKeeper Enterprise Wiki, © 2018