Focal Point
[SOLVED] Data Migrator Scheduled Job -- specify an NT Userid?

This topic can be found at:
http://forums.informationbuilders.com/eve/forums/a/tpc/f/1381057331/m/8077071296

December 17, 2019, 11:34 AM
John_Edwards
[SOLVED] Data Migrator Scheduled Job -- specify an NT Userid?
I have a scheduled Data Migrator job that needs to move data to an external machine, i.e., deliver flat files to a directory on another machine that I have Active Directory userid access to.

Question -- is there a way to schedule that particular job to run with a particular user id (so that I have access to the destination folder) without hard-coding a userid and password into my source code?

This message has been edited. Last edited by: FP Mod Chuck,



December 17, 2019, 11:53 AM
Waz
This may be a question for TeshSupport.

It may also depend on how the reporting server has been installed.

Setup is very important here if you don't want to hard code / supply uid and pw in a fex.


Waz...

Prod:WebFOCUS 7.6.10/8.1.04Upgrade:WebFOCUS 8.2.06OS:LinuxOutputs:HTML, PDF, Excel, PPT
In Focus since 1984
Know The Code

December 17, 2019, 12:42 PM
John_Edwards


Last time you recommended Tesh Support I just got this creepy photo back from him. You figure he's worth a second shot?



December 17, 2019, 01:58 PM
Waz
Can't hurt to ask. Cool


Waz...

Prod:WebFOCUS 7.6.10/8.1.04Upgrade:WebFOCUS 8.2.06OS:LinuxOutputs:HTML, PDF, Excel, PPT
In Focus since 1984
Know The Code

December 18, 2019, 08:35 AM
jgelona
You don't say what kind of boxes you're going to or from. Here's how we send files from our Linux Reporting Server to our local Window Server.

Create a fex and write the ftp, scp, sftp, smbclient commands (whatever you are using) into a file. Save the fex, then encrypt it. For example this send a .xlsm report created on the reporting server to our local Windows server.
 FILEDEF FTPSH DISK ftpsh.txt ( LRECL 120 RECFM V
-RUN
-SET &RPTNM=yi768a || '_' || &DATEYY || &DATEM;
-WRITE FTPSH #!/bin/csh
-WRITE FTPSH CURRDT=$(/bin/date +%Y%m%d)
-WRITE FTPSH smbclient //s92x01/workgroups "password" -Ixx.xxx.xx.xx -WOKDHS -UXXXXXX<< :end
-WRITE FTPSH cd "\Child Welfare\REPORTS\YI768A Children Placed Outside the County of the Primary Worker"
-WRITE FTPSH put yi768a.xlsm &RPTNM...xlsm
-WRITE FTPSH quit
-WRITE FTPSH :end
-RUN
-UNIX . ftpsh.txt

password is your password, XXXXXX is your user id, and xx.xxx.xx.xx is the IP address of the box you're going to

save this in a fex, then encrypt the fex. No more plain text. The only issue with this is when you change your password you have to unencrypt the .fex, update it, save it back, then encrypt it again which is why we use proxy ids for these types of tasks. Of course the encryption key has to be saved some where in case you're not around.


In FOCUS since 1985. Prod WF 8.0.08 (z90/Suse Linux) DB (Oracle 11g), Self Serv, Report Caster, WebServer Intel/Linux.
December 18, 2019, 09:16 AM
Clif
When you schedule or submit a flow DataMigrator runs the flow with the user id that saved the flow.

Also DataMigrator can write files to an ftp or sftp server without the need to write batch files or shell scripts. Configure an additional connection for a flat or delimited flat file and you can specify server, initial directory and credentials which are stored encrypted.
December 19, 2019, 08:46 AM
John_Edwards
Yeah, I'd really like this to be more fluid. The environment I'm working in crosses business units and I don't get to specify much if any of the rules on how the machines are set up. And they change their requirements way more than they should. If it's up to me I'm writing a hold file to a drive in a single procedure.

I now have the problem that the shared drive specification has been fouled because I tested it on two separate IDs. But that's a windows problem, not a DM problem. Thanks for all the help folks.