Score:0

WARNING: /bin/sh is not bash! - No tftp server found

gb flag

I need to launch Petalinux but I get warning that /bin/sh is not bash !

Here is the terminal.

abc@alpha:/scratch2/abc/Xilinx$ source Petalinux/settings.sh
PetaLinux environment set to '/scratch2/abc/Xilinx/Petalinux'
WARNING: /bin/sh is not bash! 
bash is PetaLinux recommended shell. Please set your default shell to bash.
WARNING: This is not a supported OS
INFO: Checking free disk space
INFO: Checking installed tools
INFO: Checking installed development libraries
INFO: Checking network and other services
WARNING: No tftp server found - please refer to "UG1144 2021.1 PetaLinux Tools Documentation Reference Guide" for its impact and solution
abc@alpha:/scratch2/abc/Xilinx$ 

Then I tried to run chsh -s /bin/bash but it says that user 'abc' does not exist in etc/passwd

abc@alpha:/scratch2/abc/Xilinx/Petalinux$ chsh -s /bin/bash
Password: 
chsh: user 'abc' does not exist in /etc/passwd

Then I tried to add user with a command passwd abc. It ask me current and new password. Which current password should I use here ? I tried to use the password of user 'abc' as current and some other as new password but then it says Authentication token manipulation error and password unchanged.

abc@alpha:/scratch2/abc/Xilinx/Petalinux$ passwd abc
Current Password: 
New password: 
BAD PASSWORD: The password is shorter than 8 characters
New password: 
Retype new password: 
passwd: Authentication token manipulation error
passwd: password unchanged
abc@alpha:/scratch2/abc/Xilinx/Petalinux$ 
PonJar avatar
in flag
I think you have made this too complicated. If your terminal uses the sh shell change it’s setting to use bash or just issue the command bash to switch to bash for the current session
engr_john avatar
gb flag
Do you mean to run `bash source Petalinux/settings.sh`. Will bash the current session ?
engr_john avatar
gb flag
`abc@alpha:/scratch2/abc/Xilinx/Petalinux$ sudo chmod +x settings.sh [sudo] password for abc: abc@alpha:/scratch2/abc/Xilinx/Petalinux$ bash source /settings.sh bash: source: No such file or directory`
engr_john avatar
gb flag
How about "No tftp server found". Can I install or enable the tftp server ?
PonJar avatar
in flag
Presumably you can if you refer to the documentation as suggested in the warning message and follow the guidance.
Score:2
in flag

When you first open your terminal issue the command:

echo $SHELL

That will tell you what shell you are using. If it’s /bin/sh you can switch to bash by just typing :

bash

Then you can try the commands that gave you warnings. If you still don’t have a tftp server refer to the documentation as suggested by the warning message. You may need to install something or start a service

engr_john avatar
gb flag
I get `/bin/bash` when I run this command `echo $SHELL`.
PonJar avatar
in flag
So you have bash when you open the terminal. What do you get after you run the source petalinux/settings.sh command?
engr_john avatar
gb flag
Hi, If I run this command then I get exactly the same which I have posted in the original post. WARNING: This is not a supported OS INFO: Checking free disk space INFO: Checking installed tools INFO: Checking installed development libraries INFO: Checking network and other services WARNING: No tftp server found - please refer to "UG1144 2021.1 PetaLinux Tools Documentation Reference Guide" for its impact and solution abc@alpha:/scratch2/abc/Xilinx
PonJar avatar
in flag
So the bash warning is no longer there? Looks like petalinux expects tftp to be there already. A simple Google search for “install tftp” reveals several guides such as this https://linuxhint.com/install_tftp_server_ubuntu/
PonJar avatar
in flag
Note that you only have warning messages here. A tftp server is only needed if you are going to do something with this software that requires one. Most functions will work fine. The same applies to the os version. Ubuntu 20.04.1 is guaranteed to work. 20.04.3 will probably work
Nate T avatar
it flag
To anyone who ends up here because they are having a similar issue: typing `/usr/bin/bash -c <COMMAND>` and replacing <COMMAND> with any command will run that command in a bash shell. Additionally, running `/usr/bin/bash` with no arguments will switch you to a bash shell as long as bash is properly installed. In this situation, however, the OP was already in bash. I believe that a line of code in the sourced script caused the warning.
mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.