How to run a full Bash terminal in Bionicpup64?

Moderator: Forum moderators

Post Reply
pupgg
Posts: 12
Joined: Sun Sep 19, 2021 7:50 pm
Been thanked: 1 time

How to run a full Bash terminal in Bionicpup64?

Post by pupgg »

How to setup an extra terminal in Bionicpup64 that
executes ordinary Linux Root commands(found online or in Linux books)?

Copy from Terminal in Bionicpup64:

root# inxi
No such command found
root# /bin/ash inxi
/bin/ash: inxi: No such file or directory

Inxi is not important, just an example.

Last edited by Flash on Thu Sep 23, 2021 12:31 am, edited 1 time in total.
Reason: Original title: Bash alternative terminal
User avatar
mikewalsh
Moderator
Posts: 6148
Joined: Tue Dec 03, 2019 1:40 pm
Location: King's Lynn, UK
Has thanked: 788 times
Been thanked: 1975 times

Re: Bash alternative terminal

Post by mikewalsh »

@pupgg :-

There's a couple of things to bear in mind, here.

  • One, you can convert most of those commands to work with Puppy by simply omitting the "sudo" command.....because Puppy does not now, nor ever will, use sudo. Why would you, AS a 'single user', need to ask the system for permission to use your own machine..? Bit daft, if you ask me. How is that making you any more "secure", hmm....?

  • Two, because Puppy's 'Busybox' implementation employs a smaller subset of standard Bash commands, some of what you see online or in books won't work in any case.....until you install whatever command you need from the PPM.....and only then will you find it's available.

It's not the terminal that's the limiting factor in Puppy.....it's the range of available commands.

Mike. ;)

User avatar
Marv
Posts: 448
Joined: Fri Dec 20, 2019 3:09 am
Has thanked: 209 times
Been thanked: 120 times

Re: Bash alternative terminal

Post by Marv »

@pupgg :

I confess I don't quite understand the question but the following tidbits might be of some interest:

Different pups handle the default shell differently, check /bin for example to see which shells are symlinks to busybox and which are 'full' implementations. I don't run Bionic but in Fossapup64, LxPupSc64, ScPup64, and LxPupSc the bash is a 'full' implementation while ash is a symlink to busybox.

To check the default shell in your pup:

Code: Select all

# echo "$SHELL"
/bin/bash

Another useful command is chsh:

Code: Select all

# chsh -l
/bin/sh
/bin/bash
/bin/ash


# chsh --help

Usage:
 chsh [options] [<username>]

Change your login shell.

Options:
 -s, --shell <shell>  specify login shell
 -l, --list-shells    print list of shells and exit

 -u, --help           display this help
 -v, --version        display version

For more details see chsh(1).

My pups: LxPupSc64 and Voidpup64 with LXDE ydrv & synaptics touchpad drivers, both using savefiles. Ydrv based NoblePup64 (JWM & LXDE), Bookworm64 & Fossapup64-small (LXDE/PCManFM). No savefiles, no fdrvs there. :thumbup:

pupgg
Posts: 12
Joined: Sun Sep 19, 2021 7:50 pm
Been thanked: 1 time

Re: How to run a full Bash terminal in Bionicpup64?

Post by pupgg »

Thx, I will check it out. Nice to get started using Bash.

User avatar
snoring_cat
Posts: 206
Joined: Tue Sep 21, 2021 3:40 pm
Location: Earth
Has thanked: 24 times
Been thanked: 46 times

Re: How to run a full Bash terminal in Bionicpup64?

Post by snoring_cat »

pupgg,

I think I understand where you are running into problems. If you copied and pasted the following:

  • root# inxi

you will get

  • No such command found

the reason being is that the example code you copy and pasted starts with "root#". You do not paste that. You should be pasting

  • inxi

But do note that the lnxi application is not installed on Puppy Linux by default, so this is a bad example.

Let's try a different example with an application that is included with Puppy Linux. If you see an example that says the following:

  • root# ifconfig

The actual command is

  • ifconfig

Why? Because "root#" is just the prompt. If you hit enter a couple of times in a terminal, you will see the prompt repeated, such as the following:
root#
root#
root#

If you want to copy and paste linux commands, don't include the prompt information. Some common prompts that you might find in online examples include:
root#
#
$

Pretty much, if you see a # or $, remove it and everything that came before it

Bonus Information
In your example, you wanted to run inxi. It is not installed in Puppy Linux by default. You can install it using the "Puppy Package Manage" (aka "PPM"). You can also try to install it form the terminal by typing the following:

  • pkg add inxi

For this to work, the "pkg" command needs to be installed already in Puppy Linux (some but not all have the "pkg" command pre-installed).

Meeeooow!

-- substance over noise, since 5 minutes in the future --

ndujoe2
Posts: 78
Joined: Sat Mar 27, 2021 4:52 pm
Has thanked: 3 times
Been thanked: 9 times

Re: How to run a full Bash terminal in Bionicpup64?

Post by ndujoe2 »

for example to see all of the terminal commands in your Busybox set.

Click on the console

Press the Tab key twice and the lists of available commands will be displayed.

User avatar
6502coder
Posts: 90
Joined: Mon Jul 13, 2020 6:21 pm
Location: Western US
Has thanked: 3 times
Been thanked: 22 times

Re: How to run a full Bash terminal in Bionicpup64?

Post by 6502coder »

@pupgg

It is important to understand that there are differences between "standard Linux commands", "bash commands", and commands like "inxi."

The "standard Linux commands" are those commands are present in any ordinary end-user Linux OS. By "ordinary" I mean to exclude special-purpose Linux OSs such as those run by some WiFi routers and other dedicated applications, where a full implementation is not required.

The "ls" command is an example of a standard Linux command. "Inxi" is not a standard Linux command.

Then there are "bash commands." These are the commands built into bash itself. "Inxi" is not a bash command, as can be seen from these references:

https://linux.die.net/man/1/builtins
https://www.unix.com/man-page/linux/7/bash-builtins/

So when you refer to "full bash" with the implication that the lack of "inxi" makes your Puppy's bash "less than full," you are mistaken. "Inxi" is not a part of bash, nor is it even a standard Linux command.

Rather, "inxi" falls in that vague category of commands that are often, or typically, found in an end-user Linux OS, but are neither standard commands nor shell built-ins.

A properly written tutorial on terminal commands should warn you when it discusses commands like "inxi" that cannot be assumed to be present in your Linux OS, although allowance can be made for discussions that take place within a defined environment, such as a Ubuntu user forum, where the OS in question can be assumed to support certain commands.

Last edited by mikewalsh on Tue Sep 28, 2021 9:56 am, edited 1 time in total.
Reason: Small spelling corrections... :)
Post Reply

Return to “Bionic”