Using expect script with AIX's SMIT in cron


 
Thread Tools Search this Thread
Top Forums Shell Programming and Scripting Using expect script with AIX's SMIT in cron
# 1  
Old 02-23-2010
Using expect script with AIX's SMIT in cron

My searches turned up nothing relevant, so I apologize if this has already been looked at.

I am trying to run an expect script from a Solaris machine, that ssh's into an AIX machine, and interacts with a SMIT created menu system that runs a few backups for me.

The expect script runs fine when manually executed via a user, regardless of permissions, so I know its neither an issue of permissions or script functionality. (Script was created with autoexpect) However, when I run the script via a regular user's CRON tab, (or root's) I generate this SMIT error after trying to run the menu system on the AIX machine.

Code:
The environment variable TERM is currently set to a terminal type that does not support the full screen display capabilities required for SMIT. 
Set TERM to an appropriate terminal type or use another terminal.

The term on both machines is "xterm". It runs fine with this terminal when I execute the script manually. It's just when it runs from CRON that it generates this error. I've tried manually exporting $TERM as xterm and vt100 in the expect script before calling SMIT without success.

Any advice on what else I could troubleshoot, or what I may be missing?

Thanks!
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Expect script not executing via cron

Hello All, I'm having an issue getting an expect script to run as a cron job. The script executes fin if I run it from the command line but I get nothing when trying to run it as a cron job. I've researched other forums and threads and there have been references to the environment, or lack... (16 Replies)
Discussion started by: KingT617
16 Replies

2. Shell Programming and Scripting

Expect Script not running from cron. Full Paths used

My cron file. Copied $PATH # Minute Hour Day of Month Month Day of Week Command SHELL=/bin/ksh PATH=/usr/lib64/qt-3.3/bin:/usr/local/bin:/bin:/usr/bin:/usr/local/sbin:/usr/sbin:/sbin:/perl/lib:/perl/lib/lib/perl5:/perl/scripts:.:/perl/lib/local:/home/popeye:/temp 0... (3 Replies)
Discussion started by: popeye
3 Replies

3. Shell Programming and Scripting

expect script not running in cron "Urgent"

I wrote a script to download the files from sftp location to local. while running the script manually its working fine. when i schedule the same in cron its not working.... :wall::wall: here is the script: #!/bin/bash ... (2 Replies)
Discussion started by: ganga39
2 Replies

4. AIX

AIX 5.3 Using sudo to control smit

Does anyone have any experience using sudo to control smit on AIX 5.3? These are the smit commands that I want certain users to execute: # Cmnd alias specification Cmnd_Alias SMIT = /bin/smit hacmp, \ /bin/smit pxdam, \ /bin/smit cl_lsuser, \ /bin/smit cl_users, \ /bin/smit cl_passwd ... (5 Replies)
Discussion started by: tharrieswk
5 Replies

5. AIX

How do I killed ideal users from AIX 5.3 smit?

Hi, I'm newbee to AIX and would like to setup a process which kills 1 Hr. ideal users from smit. Please advise for making it work. :) Thanks, Sumit (2 Replies)
Discussion started by: sumit30
2 Replies

6. Solaris

SMIT i AIX Sun Solaris ?

i now when i want use the smit in AIX is possible but a ask if you has in sun same job in sun tel me please awating supports (3 Replies)
Discussion started by: Yalmalki
3 Replies

7. Shell Programming and Scripting

calling expect script in ksh is failing via cron

I'm calling an expect script via a ksh script in cron and it is failing. The script runs fine if i run it manually. Does anyone know if it is an issue with compatibilty and if there is a way around it? (2 Replies)
Discussion started by: bhatia
2 Replies

8. UNIX for Dummies Questions & Answers

Probably an easy AIX-SMIT question with mkroute

Hi All, I am on a project and logging into about 100 servers one at a time. One of the steps I am performing is setting up a link with smit mkroute. I am using AIX versions 5.2 and 5.3 Does anyone know a quick command line to set DESTINATION ADDRESS, GATEWAY address, Network MASK, and... (5 Replies)
Discussion started by: jeffpas
5 Replies

9. What is on Your Mind?

AIX Smit menu designer. WinSmit

Hi, Please excuse me for posting an "ad" message here. Over the last few months I have created software called WinSmit, with this tool you can create your own AIX smit menus and corresponding message files. We all know the smit or smitty menus that IBM provides to maintain the system, the... (6 Replies)
Discussion started by: mimyrtek
6 Replies

10. Shell Programming and Scripting

expect script in cron

I wrote a script using 'expect' tool to change the password of my login id, every fortnight. And I had put it as a cron job. The cron job is throwing an error ld.so.1: /usr/local/bin/expect: fatal: libtcl8.3.so: open failed: No such file or directory The environment variables are set... (4 Replies)
Discussion started by: Deepa
4 Replies
Login or Register to Ask a Question