I am trying to login on server using ssh script & expect.Login to server successful but after login when i hit enter it gets hanged & when pressing CTRL +C it logs me out from the server.
Scripts are as below.
Kindly help me out in this.
Regards
Ankit
Moderator's Comments:
Please start using [CODE] tags for source listings, console output, ...
Hi all,
Normally, we give ip address to login with ssh like ssh 172.168.0.1
And we can give login name to ssh like ssh -l root 172.10.0.21
Then the shell asks the password, we enter the password and login to the system.
While using the script file, we are not able to supply the password to... (5 Replies)
Greetings all,
I'm in the midst of writing a login component for a series of shell scripts. What my login script does is this:
1. Prompt for username and read in username
2. Prompt for destination host and read in destination host
3. run ssh username and destination host
4. After user keys... (0 Replies)
Greetings all,
I'll just like to know if it is possible to launch a shell script automatically upon a user's successful login into ssh from a remote host, without adding a command parameter to the ssh command...
ie. after keying in ssh username@host (not ssh username@host "command") and upon... (1 Reply)
hi.
I need a bash script which can login to an other mashin via SSH and then run some commands and then return the result to my mashine.
I dont know where to begin, I think first I will need a ssh connection, dont know how to make it,
then , do I need a ftp connection between the 2 mashins to... (5 Replies)
hello
anyone have done ssh login script without "expect"
(automatic login from host A / user b to Host B / user b without enter any passwords)?
cheers (2 Replies)
I want to login to server using ssh or telnet and execute one command then exit to the shell
Please let me know how to write script for this? (1 Reply)
I'm trying to write a login script to ssh into a cisco switch that will run some command remotely. Similar to this expect script located here:
SSH login expect shell script to supply username and password
However, that script does not work with cisco ios. Anyway know what the best way to... (1 Reply)
why I can login by telnet using root account
but when i use login by ssh using root account
it is not successful ,is it different password
i am sure ssh service is started (2 Replies)
how can i use an expect script to do a passwordless ssh login and run a script on a bunch of remote hosts? I do not want to use public key authentication as this would require me to setup the keys on the clients etc.... (2 Replies)
Hello everyone.
I'm a Linux novice trying out a lot of bash scripting lately, as it is so very addictive.
Lately I have been setting up one of my boxes remotely and have been hardening it as much as possible. Please allow me to explain the scenario, as it does tend to become a little... (1 Reply)
Discussion started by: instro
1 Replies
LEARN ABOUT REDHAT
nwfsctrl
NWFSCTRL(1) nwfsctrl NWFSCTRL(1)NAME
nwfsctrl - Perform server command
SYNOPSIS
nwfsctrl [ -h ] [ -S server ] [ -U user name ] [ -P password | -n ] [ -C ] [ -p ncpfs path ] -c | -o | -[f]d
nwfsctrl [ -h ] [ -S server ] [ -U user name ] [ -P password | -n ] [ -C ] [ -p ncpfs path ] server command
DESCRIPTION
nwfsctrl performs command on server.
OPTIONS -h
With -h nwfsctrl prints a little help text.
-S server
is the name of the server you want to use.
-U user
user is the user name to use for login. To set the server's time, you need supervisor privileges.
-P password
password is the password to use for login. If neither -n nor -P are given, and the user has no open connection to the server, nwfstime
prompts for a password.
-n
-n should be given if no password is required for the login. As you need supervisor privileges for setting the date and time, this
option is probably not used very often.
-C
By default, passwords are converted to uppercase before they are sent to the server, because most servers require this. You can turn off
this conversion by -C.
-o
Open bindery.
-c
Close bindery.
-d
Down fileserver. This command will complain if there are open files on server.
-fd
Down fileserver, regardless of opened files.
load module options...
Load module module with options options... on server. Program will complain if module is already loaded.
unload module
Unload module module from server. Program will complain if module is not loaded.
mount volume
Mount volume volume.
dismount volume
Dismount volume volume. If there are open files on volume, server displays prompt on console. You must go to the server (or telnet/xcon-
sole) and hit Y or N to get beyond this point).
set variable = value
Set server settable variable variable to value value.
open bindery
Open bindery.
close bindery
Close bindery.
enable login
Enable login to file server.
disable login
Disable login to file server.
disable tts
Disable TTS. This probably does not work on Netware 4.11.
enable tts
Enable TTS. This probably does not work on Netware 4.11.
BUGS
Other commands are not written yet (volume, clear connection ...)
CREDITS
This utility was created by Petr Vandrovec (vandrove@vc.cvut.cz) and is part of ncpfs since 2.2.0.11.
nwfsctrl 2/12/1999 NWFSCTRL(1)