I need to run a script that prompts the user for some input and takes action based on that input. It must run at the end of the login process, after the desktop is displayed.I tried putting it in ~/.bash_login, but it didn't run. Do I need to tell /etc/profile to run ~/.bash_login? I thought it looked for it & ran it if it was found.
A related question would be - Can I make it so the terminal session that is running the script be the only thing that the user can do? In other words, they can't click on anything on the desktop or in the panels and have it run until after they respond to the input request.
Before you say you shouldn't do that bla bla bla. I know why i shouldn't.
However i have a problem with running sudo commands from a non interactive command line script run using plink.
The automated script needs to use chown and give the current user ownership of some files and folders created by another user.
I can't use things like sudo -s etc as it requires that i enter a password.
I have setup public key authorization in order to login. Do i have to give the root user a password and log in as that. I would prefer not doing this but if that is the only solution i guess i'll have too.
I am trying to assign a user account on RHEL5 Server a non-interactive login but I am not sure if this is the correct command: useradd useraccount -s /sbin/nologinAfter I issue this command, I try to log in with this account and it says the "Administrator has disabled this account" when I enter the password. Does any one know if the command above is correct?
I am having trouble distinguishing between login and interactive shells as they relate to terminals. I understand that a login shell is what is started when you login, and an interactive shell is used by scripts and such. I also get that terminals will use an interactive shell by default. What I don't understand is why interactive shells have no prompt by default. Is their a way to get an interactive shell to inherit the normal PS1 prompt? Is it considered bad to do this? Would it be better to have terminals start login shells, and if so why or why not?
I just build a couple production SLES 11 machines and I'm using an ssh client to connect. However the ssh client forces me to use keyboard interactive login. How can I turn this off so I can use the normal username / password?
My execution environment is Linux steamboy 2.6.31-21-generic-pae #59-Ubuntu SMP.If I log in and run a program, the program works properly. The program is a shell script, which executes an environment file, so that path and library settings point correctly.If I have cron run the same program as the same user who logged in, one of the libraries cannot be found. I have sourced .bashrc and the same environment setting file, even though .bashrc executes the same environment file . /home/amr/bin/informix_env.sh
Intuitively I think that the Login Shell and the Interactive Shell are the same applications but have access to different environmental variables.It this true? Why is there more than one type of shell anyways? You can change users with the interactive shell, why not log on with it to?
I would like to run an interactive python script in tty1 on startup. This script requires user input outputs relevant data.I also need this script to be run as root as it accesses USB devices (and has to detach kernel drivers).It is an infinite-loop script, so I also want to be able to ctrl+alt+F to tty2 to actually login if needed
I have a situation where I am in a non-interactive shell. I have tried from within my non-interative shell to spawn an interactive shell but my output still does not goto me. Isn't there a way I can somehow go into /proc or somwhere and make the output my /dev/tty1? Or some way else to remedy this?The situation arises because I drop from my restricted shell environment (a sort of CLI interface), into the actual Linux shell. I cannot change the code of the CLI environment I am just faced with being in the linux shell environment and its non-interactive. Its very annoying to have to put > /dev/tty1 after every command I type.
Not to mention it seems damn near impossible to get pagers like more and less to work properly when your in a non-interactive shell.
The interactive map on weather.com no longer works for me in Firefox. I'm just looking for some feedback from other users if they can see the map or not. I'm using Lucid with current updates.
As I have posted here [URL], my laptop powered down during an update because I forgot to plug it into the mains power. Anyway, after going through the thread I referred to above, I learned that I must chroot into the existing installation and patch it up. I can do this using a live CD but unfortunately, I gave my most recent live CDs away and the Live CDs I have left don't recognize the file system on the current Ubuntu installation. (If I remember correctly, the current [broken] installation is 10.04). Downloading a new live CD is a bit difficult as internet speeds over here aren't very fast. I was wondering if there is another alternative bootable CD that I could use to get a interactive command line which I can use to "chroot".
I'm running Kubuntu 10.04 and have activated the interactive map wallpaper. Zooming with the mouse wheel is unfortunately very slow. I have tried to adjust the speed by changing System Settings > Mouse > Advanced: Mouse wheel scrolls by to max, i.e. "12 lines", but it has no effect, the zooming is still very slow. Is there any way to speed it up? If possible I would like to have the same zoom speed as when using Google Maps [url] in Firefox.
Is there a non-interactive way to change a user's passwd short of using expect? I'm using Debian.If not, then I guess I need to get this expect script working:
Code: #!/usr/local/bin/expect -f set username $env(UNAME)
I wish to prevent some programs from "phoning home", and to allow other programs to access only specific web servers.Is there any way to interactively allow or decline outbound communication from individual programs on Ubuntu?
I am experiencing a 5-10 minute delay when trying to ssh into my ubuntu server.
root@localhost's password: debug2: we sent a password packet, wait for reply debug1: Authentication succeeded (password). debug1: channel 0: new [client-session] debug2: channel 0: send open debug1: Requesting no-more-sessions@openssh.com debug1: Entering interactive session. HANG
I've tried using the option UseDNS No in my my sshd_Config but to no success. I've tried reinstalling ubuntu fresh, but still it hangs upon trying to ssh from any machine. I am running Ubuntu 9.10 server.
I recently manage to make my microphone "work". I open the alsamixer and i unmuted the mic. Easy!!! But as i can hear my voice through the speakers i can't record. Actually i compare the alsamixer with the sound preferences. And what I notice is:
i)When i mute the output volume from the sound icon in the alsamixer is also muted.
ii)The same when I increase or decrease the volume.
iii)But in the input tab if I mute increase or decrease the volume nothing happens!
I can only mute unmute and change volume trhough the alsa mixer!
I use an Fujitsu siemens amilo pa 1510 with ubuntu 10.10 which I install from a pendrive.
Posting from Splashtop as i can't get past keytouch-apid in the boot process,Yeah me bad so i would like to disable it so i can complete the process.Using the interactive startup seemed the way to go but how does one get there before udev starts up?Or is there something else i could try.
My problem is: One of my services has failed to start. All I need is just go into interactive startup and ignore that service. The system is encrypted as LUKS. I press 'i' before and after entering the phrase (it asked me "Password for filesystem"). But interactive startup seems not working. All the services go to start without my permission. I mean there is no question such as "Start XXX [Y/N]?"
In the past I used CentOS for some months, and interactive startup (by pressing 'i' on boot time) was fine. I could allow or not what service should be started.
how can I make my sh interactive by default. That I don't have to always type --interactive everytime I log in. I want it to be always interactive. #2- how also do I turn of --posix mode parmanently ? Is there a line I need to drop somewhere or what do i do.
I need an non-interactive, symetric, passphrase mechanism that can be used on machines beyond my sys-admin control. Currently, I use the Python code (with variants):
to encrypt and decrypt files (tar balls). The "Password" is generated by a Python code on a singular removable flash drive. It worked with FC11 and Windows, but with FC13 I get an interactive dialog, which gets canceled, and then: can't connect to `/home/{a user id}/.gnupg/S.gpg-agent': No such file or directory
gpg-agent[3432]: command get_passphrase failed: Operation cancelled gpg: cancelled by user gpg: error creating passphrase: Operation cancelled gpg: symmetric encryption of `testdata' failed: Operation cancelled
The operator does not know the pass phrase. This is a single user mechanism which relies upon the mounting of the special flash drive to work. The application is portable across many platforms and hosts, but can only be used by the possessor of the flash drive.
can provide recommendations on any projects that can fully automate the install process of an interactive application. I am doing installs of applications such as websense and they are all interactive. I would like to automate all interactive installs in my environment. I did find the following: [URL]
I am trying to figure out where variables are set for interactive shells? In particular, I am trying to have LS_OPTIONS inherited by interactive shells as it is by login shells. I understand LS_OPTIONS is set in /etc/profile, and this may not be processed by interactive shells but by login shells. However, I also note other variables such as PATH and INPUTRC are set correctly in interactive shells, and these are also set in /etc/profile from what I understand. So how is it determined which variables are inherited by all shells, and which are just for login shells?
I'm still quite wet behind the ears with CentOS/Unix. What I'm trying to do is to setup a non interactive user, where I login with an interactive user and su to the non interactive. I have set the non interactive with /sbin/nologin (through the GUI), but when I login with the interactive user and su to the non interactive user I get the following: "This account is currently not available".
Possible Duplicate:Forward SSH traffic through a middle machine.I am looking to get an interactive ssh session on a remote machine, but must login via a gateway.For example, right now I do the following:
From the output i am indeed able to login, but do not get an interactive session. I took inspiration for this attempt from using ssh to run a command remotely.
In interactive mode (in Octave, gnuplot, R, etc.) I occasionally press Control + z by mistake. This pauses the program and kicks me back to the terminal.Is it possible to re-enter the original interactive mode (with all the stored variables)?
To reproduce:
~> octave octave:1> a = [1:10]; octave:2> ^Z
[code].....
How can I recover my session with the variable a defined?
i need to run a command from a shell script that requires me to answer "Yes" to 2 questions that the command asks before it kicks off. how do i do this? i thought it was something like this.. from inside the parent script:
I'm trying to start bash with a command and have it interactive like this:bash -i -c "echo Welcome!"As in, execute the command and allow me to use it as an interactive shell afterwards. (I'm doing something more complicated than echoing, but this doesn't work.)I've tried this from a running gnome-terminal, from one gnome-terminal to a new one withgnome-terminal and from the Alt+F2 program launcher (with "Run in terminal" ticked).