![]()
I check the /etc/quantum/nf and /etc/quantum/quantum/rootwrap.d/ and /etc/sudoers.d/quantum, it seems no problem, I check with controller node's nova setting, it seems all are OK. I meet some problem when I put Quantum packages scripts in /etc/init.d directory and try to start Quantum packages by quantum user, when I start agent: service quantum-openvswitch-agent start, I find error in /var/log/quantum/quantum-openvswitch-agent.log: confĪfter I add them in, the quantum packages start without SUDO error. Rootwrap_ config= /etc/quantum/ rootwrap. Root_helper = sudo quantum-rootwrap /etc/quantum/ rootwrap. The -t option forces pseudo-tty allocation. d/quantum, it seems no problem, I check with controller node's nova setting, it seems all are OK.įinally I find I miss below two lines in /etc/quantum/ quantum. In order to avoid this error, we have to run ssh command as follows: ssh -t hostname sudo command ssh -t userhostname sudo command ssh -t sudo command1 /path/to/file. conf and /etc/quantum/ quantum/ rootwrap. Stderr: 'sudo: no tty present and no askpass program specified\n' I meet some problem when I put Quantum packages scripts in /etc/init.d directory and try to start Quantum packages by quantum user, when I start agent: service quantum- openvswitch- agent start, I find error in /var/log/ quantum/ quantum- openvswitch- agent.log: 7/dist- packages/ quantum/ agent/linux/ utils.py", line 61, in execute stdin, stdout, stderr ssh. sudo: no tty present and no askpass program specified I tried. py", line 407, in executeįile "/usr/lib/ python2. Paramiko: no tty present and no askpass program specified ssh python duplicate Ask Question Asked 5 years, 3 months ago. 7/dist- packages/ quantum/ agent/linux/ ip_lib. This is both secure and what you need in the majority of the use cases. py", line 55, in enableįile "/usr/lib/ python2. In the stock sudoers configuration, the following line is usually present. 7/dist- packages/ quantum/ agent/linux/ external_ process. 7/dist- packages/ quantum/ agent/dhcp_ agent.py", line 329, in enable_ isolated_ metadata_ proxyįile "/usr/lib/ python2. enable_ isolated_ metadata_ proxy(network)įile "/usr/lib/ python2. 7/dist- packages/ quantum/ agent/dhcp_ agent.py", line 188, in enable_dhcp_helper 7/dist- packages/ quantum/ agent/dhcp_ agent.py", line 234, in network_create_endįile "/usr/lib/ python2. py", line 242, in innerįile "/usr/lib/ python2. 7/dist- packages/ quantum/ openstack/ common/ lockutils. Return getattr(proxyobj, method)(ctxt, **kwargs)įile "/usr/lib/ python2. 7/dist- packages/ quantum/ openstack/ common/ rpc/dispatcher. dispatch( ctxt, version, method, **args)įile "/usr/lib/ python2. 7/dist- packages/ quantum/ openstack/ common/ rpc/amqp. 19:59:54 ERROR Exception during message handlingįile "/usr/lib/ python2. #Sudo no tty present and no askpass program specified passwordStderr: 'sudo: no tty present and no askpass program specified\nSorry, try again.\nsudo: no tty present and no askpass program specified\nSorry, try again.\nsudo: no tty present and no askpass program specified\nSorry, try again.\nsudo: 3 incorrect password attempts\n' You will have to either use an askpass helper program or configure the required sudo rules to use NOPASSWD, if that is an option.19:59:54 DEBUG Ĭommand: If sending the script over the SSH standard input like this is a requirement (instead of just copying the script to the server), then the first option will not work. Note that since you are piping your shell script to the standard input stream of the SSH connection, sudo will be unable to securely prompt for a password. This can be done in your script, for example, with something like: export SUDO_ASKPASS=/usr/lib/openssh/gnome-ssh-askpass Tell sudo to prompt for your password using an askpass program with the -A option on sudo (not to be confused with the -A option for ssh!). This is as easy as logging in with ssh -t. To authenticate with sudo remotely, you will have to do one of the two things it is requesting:Įnsure you have a tty so sudo can securely prompt for your password on the server. An askpass program is a (typically graphical) helper program that simply prompts for a password securely. Unless you have sudo rules allowing you to run commands with no password, it will always need to prompt for your password, either from your shell's terminal or using an askpass program, if so configured. It provides the ability to forward your credentials so you can ssh from server to another system using your local SSH key. I am trying to compile some sources using a makefile. #Sudo no tty present and no askpass program specified how toThe -A option to the ssh command applies to SSH only. Linux How to fix sudo: no tty present and no askpass program specified error. ![]() You can fix it by either adding the command to your PATH or invoking it with an absolute path, i.e. #Sudo no tty present and no askpass program specified fullSSH authentication and sudo authentication are two different sets of credentials. If you have a single (or multi, but not ALL) command sudoers entry, youll get the sudo: no tty present and no askpass program specified when the command is not part of your path (and the full path is not specified). ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |