Hello to all...this is my first post (so please go easy). :)
I feel pretty solid at expect scripting, but I'm running into an issue that I'm not able to wrap my head around. I wrote a script that is a little advanced for logging into a remote Linux machine and changing text in a file using sed.... (2 Replies)
This Expect script provides expect with a list of IP addresses to Cisco IPS sensors and commands to configure Cisco IPS sensors. The user, password, IP addresses, prompt regex, etc. have been anonymized. In general this script will log into the sensors and send commands successfully but there are... (1 Reply)
Hello,
I would like to make a script, ideally in perl since I am most familair with it, that does the following:
automatically starts up at 9 pm, searches through a specified directory for any new files, finds those new files and starts to run them through a pipeline. I have most of it worked... (4 Replies)
Gents,
I have a wrapper script passing couple of information to an expect script mainly responsible for spawning scp and providing the password (which is transmitted down from the main script). the main script prepare the transfer to couple of servers, idea being to transfer the files in... (3 Replies)
I want to warn everyone, I am not a programmer lol. I'm an IT wanting to get a little insight of programming, and I like to play around so I can learn. Ok, so I'm going to school for IT Security and Forensics. I had a project to write a hack, and I chose to write a shell script to run dd to write... (8 Replies)
Hi All,
I run the scp command in shell prompt without issue, but when on expect script as below:
#!/usr/bin/expect
spawn scp /var/spool/sms/failed.tar.gz abc@10.10.12.2:/home/abc
expect "abc@10.10.12.2's password: "
send "abcfef\r"
exit 0
It looks not working at all and the... (3 Replies)
An Expect script using scp to copy directories is not moving the subdirectories as wanted. The directory structure is:
computerA (user 'test')
/home/test/parentDir/subdir1
/home/test/parentDir/subdir2
and I want them copied to
computerB (user 'archive')
/home/archive/subdir1... (1 Reply)
Dear All,
I have a requirement where I have to SFTP or SCP a file in a batch script. Unfortunately, the destination server setup is such that it doesn't allow for shell command line login. So, I am not able to set up SSH keys. My source server is having issues with Expect. So, unable to use... (5 Replies)
I'm fairly new to scripting so this might not be possible.
I am using Expect with Cisco switches and need to capture the string after finding the expect request. For example, when I issue "show version" on a Nexus switch, I'm looking to capture the current firmware version:
#show version
... (0 Replies)
Hi All,
I have written a script to automate scp of files. Most of the times it works fine except few cases. I want your help and suggestions to fix these failures.
I have used expect & shell to do the automated scp. Below is code
$ cat scp.ksh
#!/bin/ksh
inputfile=$1
fdest_sid=$2... (8 Replies)
Discussion started by: veeresh_15
8 Replies
LEARN ABOUT BSD
timedc
TIMEDC(8) System Manager's Manual TIMEDC(8)NAME
timedc - timed control program
SYNOPSIS
timedc [ command [ argument ... ] ]
DESCRIPTION
Timedc is used to control the operation of the timed program. It may be used to:
o measure the differences between machines' clocks,
o find the location where the master time server is running,
o enable or disable tracing of messages received by timed, and
o perform various debugging actions.
Without any arguments, timedc will prompt for commands from the standard input. If arguments are supplied, timedc interprets the first
argument as a command and the remaining arguments as parameters to the command. The standard input may be redirected causing timedc to
read commands from a file. Commands may be abbreviated; recognized commands are:
? [ command ... ]
help [ command ... ]
Print a short description of each command specified in the argument list, or, if no arguments are given, a list of the recognized
commands.
clockdiff host ...
Compute the differences between the clock of the host machine and the clocks of the machines given as arguments.
trace { on | off }
Enable or disable the tracing of incoming messages to timed in the file /usr/adm/timed.log.
quit
Exit from timedc.
Other commands may be included for use in testing and debugging timed; the help command and the program source may be consulted for
details.
FILES
/usr/adm/timed.log tracing file for timed
/usr/adm/timed.masterlog log file for master timed
SEE ALSO date(1), adjtime(2), icmp(4P), timed(8),
TSP: The Time Synchronization Protocol for UNIX 4.3BSD, R. Gusella and S. Zatti
DIAGNOSTICS
?Ambiguous command abbreviation matches more than one command
?Invalid command no match found
?Privileged command command can be executed by root only
4.3 Berkeley Distribution November 17, 1996 TIMEDC(8)