- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - OpenVMS
- >
- SSH remote command execution fails from batchmode
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Discussions
Discussions
Discussions
Forums
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО10-18-2005 01:22 AM
тАО10-18-2005 01:22 AM
SSH remote command execution fails from batchmode
This could be a problem with the remote program, but this works fine from DCL interactive mode when I specify batch mode. There seem to be something that is different from batch. However, I can see that a pseudo terminal is allocated on the remote system, both from interactive and batchmode. If in interactive mode, batch mode is enabled from command line.
Example:
$ ssh -t -o "BatchMode yes" testuser@10.1.2.57 "testscript parameter"
Where test script is like:
#!/bin/sh
who am i
OtherProg $*
Output like:
testuser /dev/pts/2 Oct 18 15:05
failure to get parameter to OtherProg
OpenVMS 7.3-2, TCPIP 5.4 ECO5
Remote: Solaris 9 (OpenSSH based)
Public key authentication, without password
Hints what is happening in batch mode, or shall I blame the Solaris program?
/Gerhard
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО10-18-2005 12:07 PM
тАО10-18-2005 12:07 PM
Re: SSH remote command execution fails from batchmode
It says, SSH, SFTP, and SCP commands may not work correctly with sys$input, sys$output, and sys$error devices in batch mode. and it may send unexpected
Try directing output to any files.
$ assign xxx.dat sys$output.
Archunan
Archie
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО10-18-2005 07:57 PM
тАО10-18-2005 07:57 PM
Re: SSH remote command execution fails from batchmode
The problem in this situation is that SSH seems to identify itself differently on the _remote_ side when running in batch mode. Since it is working from interactive mode (even when I specify BatchMode), the implementation on the Solaris side is not completely broken.
Gerhard
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО10-18-2005 08:24 PM
тАО10-18-2005 08:24 PM
Re: SSH remote command execution fails from batchmode
The link below discuss about your SSH/Solaris issues?
They were talking about -b option with the batchfile to read the input from ( but with SFTP)
http://www.computing.net/unix/wwwboard/forum/7006.html
Archunan
Archie
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО10-18-2005 08:44 PM
тАО10-18-2005 08:44 PM
Re: SSH remote command execution fails from batchmode
Regarding the link: SSH in OpenVMS will disable all password based authentication methods if in batch mode (or option "BatchMode yes" is set as in my example).
Thanks for the hints though. I guess that what I am looking for is a way to get OpenVMS SSH to identify itself the same from interactive and batch mode.
A few more observations:
1.
If I do not allocate a pseudo terminal on the remote side "-t" parameter, the remote program fails also from Interactive mode.
$ ssh -o "BatchMode yes" testuser@10.1.2.57 "testscript parameter"
2.
If I call the Solaris program directly, it succeeds:
$ ssh -t -o "BatchMode yes" testuser@10.1.2.57 "OtherProg parameter"
(still not a workaround, the script performs some inititialations before the prog).
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО10-18-2005 10:13 PM
тАО10-18-2005 10:13 PM
Re: SSH remote command execution fails from batchmode
In my case, /etc/profile (remote user is bash) is not read and the standard environment variables are therefore not available and the remote program fails.
I can fix this on the Solaris side, so it is not a major issue for me. Still something to be aware of.