Freeside:4:Documentation:Developer/bin/freeside-cdr-sftp and import

From Freeside
Jump to: navigation, search


freeside-cdr-sftp_and_import - Download CDR files from a remote server via SFTP


 cdr.sftp_and_import [ -m method ] [ -p prefix ] [ -e extension ] 
   [ -r remotefolder ] [ -d donefolder ] [ -v level ] [ -P port ]
   [ -a ] [ -g ] [ -s ] [ -c cdrtypenum ] user format [sftpuser@]servername


Command line tool to download CDR files from a remote server via SFTP or FTP and then import them into the database.

-m: transfer method (sftp or ftp), defaults to sftp

-p: file prefix, if specified

-e: file extension, defaults to .csv

-r: if specified, changes into this remote folder before starting

-d: if specified, moves files to the specified folder when done

-P: if specified, sets the port to use

-a: use ftp passive mode

-b: use ftp binary mode

-v: set verbosity level; this script only has one level, but it will be passed as the 'debug' argument to the transport method

-c: cdrtypenum to set, defaults to none

-g: File is gzipped

-s: Warn and skip files which could not be imported rather than abort

user: freeside username

format: CDR format name

[sftpuser@]servername: remote server (or ftpuser:ftppass@servername)