From SUSE Linux 10.1 to a MS OS Running Kermit 3.16 via copSSH on Windows XP or older Windows connected serial devices
Hello, Here is the problem |---------------| |---------------| | | | | | | | | | SUSE 10.1 |<-------internet------>| MS Machine | | | | | | | | | | | | | |---------------| |---------------| | | Kermit | |---------------| | | | | | Cash Registers| | | | | |---------------| I have SUSE Linux 10.1 and I am able to ssh and scp to the machines. I need to automate getting all the files from the MS machines to a remote site to process them. But I can not seem to remember how I used to run via ssh kermit remotely. The machines with some version of MS Windows, most have Windows XP. I use kermit to talk with their store registers. The machines have a purchased copy of MS Kermit 3.16. My mskermit.ini file on these machines has set port 1 set baud 9600 PAUSE 2 REMOTE LOGIN RAIS PAUSE 2 GET datafile PAUSE 2 GET datafile1 ... EXIT till I have all the files. I thought I could use kermit via ssh to talk to the machines and directly transfer the files. Did not work. I then setup cygwin and copSSH. I am able to ssh to the machines and then I use scp to copy a mskermit.ini with the commands I need it to run. I then am able to ssh -luser 192.168.0.200 cd /directory/files ./kermit ... scp -p file user@192.168.0.125:/work/directory/save/files/ or scp -p user@192.168.0.125:/directory/files /directory/to/save/files/ and all the files are downloaded. So I am able to scp to/form machine or I am able to scp to/from remote ms box to linux box. But I am not able to get my scripts to remotely run kermit on the ms box to download files from the cash registers to the ms box so I can then scp the files. When I try to run ssh -luser 192.168.0.200 c:/kermit/backoffice/kermit user@192.168.5.200's password: IBM-PC MS-DOS Kermit: 3.16 4 May 1999 Copyright (C) Trustees of Columbia University 1982, 1999. Type ? or HELP for help MS-Kermit>^A^A^A ?Text exceeded available buffer capacity MS-Kermit> And I am back at the prompt on the remote box and it has not run the mskermit.ini file. There has to be a way to automate via ssh and run the kermit on the MS Windows machines and then scp the files. The only step I have been uable to get working is to run kermit remotely and get the files to the MS machine. Any ideas. I know I have done this in the past but I can not seem to remember how and all my googleing has not brought up a solutions. Any ideas? Thanks, -- Boyd Gerber <gerberb@zenez.com> ZENEZ 1042 East Fort Union #135, Midvale Utah 84047
I guess you don't get a proper environment for kermit, viz. current working directory etc. I should try 1) launching kermit from a .bat or .cmd file 2) Invoke the command file in ssh via cmd /c e.g. ssh -luser 192.168.0.200 'cmd /c c:/kermit/backoffice/mykermit.cmd' In mykermit.cmd you can then ensure CWD, PATH etc are all correct before launching kermit itself. /Lennart tisdag 17 oktober 2006 22:58 skrev Boyd Lynn Gerber:
Hello,
Here is the problem
|---------------| |---------------| | | | SUSE 10.1 |<-------internet------>| MS Machine | | | | |---------------| |---------------| | | Kermit | |---------------| | | | Cash Registers| | | |---------------|
I have SUSE Linux 10.1 and I am able to ssh and scp to the machines. I need to automate getting all the files from the MS machines to a remote site to process them. But I can not seem to remember how I used to run via ssh kermit remotely. The machines with some version of MS Windows, most have Windows XP. I use kermit to talk with their store registers. The machines have a purchased copy of MS Kermit 3.16.
My mskermit.ini file on these machines has set port 1 set baud 9600 PAUSE 2 REMOTE LOGIN RAIS PAUSE 2 GET datafile PAUSE 2 GET datafile1 ... EXIT
till I have all the files.
I thought I could use kermit via ssh to talk to the machines and directly transfer the files. Did not work. I then setup cygwin and copSSH. I am able to ssh to the machines and then I use scp to copy a mskermit.ini with the commands I need it to run. I then am able to
ssh -luser 192.168.0.200 cd /directory/files ./kermit ... scp -p file user@192.168.0.125:/work/directory/save/files/ or scp -p user@192.168.0.125:/directory/files /directory/to/save/files/
and all the files are downloaded.
So I am able to scp to/form machine or I am able to scp to/from remote ms box to linux box. But I am not able to get my scripts to remotely run kermit on the ms box to download files from the cash registers to the ms box so I can then scp the files.
When I try to run ssh -luser 192.168.0.200 c:/kermit/backoffice/kermit
user@192.168.5.200's password: IBM-PC MS-DOS Kermit: 3.16 4 May 1999 Copyright (C) Trustees of Columbia University 1982, 1999.
Type ? or HELP for help
MS-Kermit>^A^A^A ?Text exceeded available buffer capacity MS-Kermit>
And I am back at the prompt on the remote box and it has not run the mskermit.ini file.
There has to be a way to automate via ssh and run the kermit on the MS Windows machines and then scp the files. The only step I have been uable to get working is to run kermit remotely and get the files to the MS machine. Any ideas. I know I have done this in the past but I can not seem to remember how and all my googleing has not brought up a solutions. Any ideas?
Thanks,
-- Boyd Gerber <gerberb@zenez.com> ZENEZ 1042 East Fort Union #135, Midvale Utah 84047
-- !++ ! Lennart Börjeson ! Partner, Developer ! Cinnober Financial Technology AB ! Industrigatan 2A ! S-112 46 STOCKHOLM ! Sverige/Sweden/Schweden/Suède ! mailto:Lennart.Borjeson@cinnober.com ! phone:+46-8-50304717 ! gsm:+46-70-3394717 ! fax:+46-8-50304701 ! http://www.cinnober.com !--
On Wed, 18 Oct 2006, Lennart Börjeson wrote:
I guess you don't get a proper environment for kermit, viz. current working directory etc.
I should try
1) launching kermit from a .bat or .cmd file 2) Invoke the command file in ssh via cmd /c
e.g. ssh -luser 192.168.0.200 'cmd /c c:/kermit/backoffice/mykermit.cmd'
In mykermit.cmd you can then ensure CWD, PATH etc are all correct before launching kermit itself.
Thanks, I had not tried the /c, sadly it gives me the same below. I tried variations like c:/windows/system32/cmd ... There has to be a way to execute this. Thanks,
When I try to run ssh -luser 192.168.0.200 c:/kermit/backoffice/kermit
user@192.168.5.200's password: IBM-PC MS-DOS Kermit: 3.16 4 May 1999 Copyright (C) Trustees of Columbia University 1982, 1999.
Type ? or HELP for help
MS-Kermit>^A^A^A ?Text exceeded available buffer capacity MS-Kermit>
And I am back at the prompt on the remote box and it has not run the mskermit.ini file.
There has to be a way to automate via ssh and run the kermit on the MS Windows machines and then scp the files. The only step I have been uable to get working is to run kermit remotely and get the files to the MS machine. Any ideas. I know I have done this in the past but I can not seem to remember how and all my googleing has not brought up a solutions. Any ideas?
Thanks,
-- Boyd Gerber <gerberb@zenez.com> ZENEZ 1042 East Fort Union #135, Midvale Utah 84047
-- Boyd Gerber <gerberb@zenez.com> ZENEZ 1042 East Fort Union #135, Midvale Utah 84047
participants (2)
-
Boyd Lynn Gerber
-
Lennart Börjeson