Rocksolid Light

News from da outaworlds

mail  files  register  groups  login

Message-ID:  

Reply hazy, ask again later.


comp / comp.unix.bsd.openbsd.misc / Re: bsd newbie bash question

SubjectAuthor
* bsd newbie bash questionDecadentLinuxUserNumeroUno
+* Re: bsd newbie bash questionHans Selig-Kinn
|`- Re: bsd newbie bash questionDecadentLinuxUserNumeroUno
`* Re: bsd newbie bash questionGoetz Schultz
 `- Re: bsd newbie bash questionDoN. Nichols

1
Subject: bsd newbie bash question
From: DecadentLinuxUserNumeroUno@decadence.org
Newsgroups: comp.unix.bsd.openbsd.misc
Organization: Aioe.org NNTP Server
Date: Fri, 20 Mar 2020 15:23 UTC
Path: eternal-september.org!news.eternal-september.org!reader01.eternal-september.org!reader01.eternal-september.org!feeder.eternal-september.org!aioe.org!.POSTED.E15Ern5JFYjq4l1GyqCoLg.user.gioia.aioe.org!not-for-mail
From: DecadentLinuxUserNumeroUno@decadence.org
Newsgroups: comp.unix.bsd.openbsd.misc
Subject: bsd newbie bash question
Date: Fri, 20 Mar 2020 15:23:29 +0000 (UTC)
Organization: Aioe.org NNTP Server
Lines: 3
Message-ID: <r52n5h$miu$1@gioia.aioe.org>
NNTP-Posting-Host: E15Ern5JFYjq4l1GyqCoLg.user.gioia.aioe.org
X-Complaints-To: abuse@aioe.org
User-Agent: Xnews/5.04.25
X-Notice: Filtered by postfilter v. 0.9.2
View all headers

my bash script has trash output, but works fine under linux.

What bash tidbit am I missing?

Subject: Re: bsd newbie bash question
From: Hans Selig-Kinn
Newsgroups: comp.unix.bsd.openbsd.misc
Organization: Aioe.org NNTP Server
Date: Fri, 20 Mar 2020 20:37 UTC
References: 1
Path: eternal-september.org!news.eternal-september.org!reader01.eternal-september.org!reader01.eternal-september.org!feeder.eternal-september.org!aioe.org!.POSTED.VWpcC0UGe6FuG1pcKLepPg.user.gioia.aioe.org!not-for-mail
From: email@domain.com (Hans Selig-Kinn)
Newsgroups: comp.unix.bsd.openbsd.misc
Subject: Re: bsd newbie bash question
Date: Fri, 20 Mar 2020 21:37:50 +0100
Organization: Aioe.org NNTP Server
Lines: 8
Message-ID: <r539is$16dk$1@gioia.aioe.org>
References: <r52n5h$miu$1@gioia.aioe.org>
NNTP-Posting-Host: VWpcC0UGe6FuG1pcKLepPg.user.gioia.aioe.org
Mime-Version: 1.0
Content-Type: text/plain; charset=iso-8859-1; format=flowed
Content-Transfer-Encoding: 8bit
X-Complaints-To: abuse@aioe.org
User-Agent: Unison/2.2
X-Notice: Filtered by postfilter v. 0.9.2
View all headers

On 2020-03-20 15:23:29 +0000, DecadentLinuxUserNumeroUno@decadence.org said:

> my bash script has trash output, but works fine under linux.
>
> What bash tidbit am I missing?

Maybe the fact that BSDs don't use bash as default shell?

Subject: Re: bsd newbie bash question
From: DecadentLinuxUserNumeroUno@decadence.org
Newsgroups: comp.unix.bsd.openbsd.misc
Organization: Aioe.org NNTP Server
Date: Fri, 20 Mar 2020 20:55 UTC
References: 1 2
Path: eternal-september.org!news.eternal-september.org!reader01.eternal-september.org!reader01.eternal-september.org!feeder.eternal-september.org!aioe.org!.POSTED.E15Ern5JFYjq4l1GyqCoLg.user.gioia.aioe.org!not-for-mail
From: DecadentLinuxUserNumeroUno@decadence.org
Newsgroups: comp.unix.bsd.openbsd.misc
Subject: Re: bsd newbie bash question
Date: Fri, 20 Mar 2020 20:55:11 +0000 (UTC)
Organization: Aioe.org NNTP Server
Lines: 17
Message-ID: <r53ajf$1iti$2@gioia.aioe.org>
References: <r52n5h$miu$1@gioia.aioe.org> <r539is$16dk$1@gioia.aioe.org>
NNTP-Posting-Host: E15Ern5JFYjq4l1GyqCoLg.user.gioia.aioe.org
X-Complaints-To: abuse@aioe.org
User-Agent: Xnews/5.04.25
X-Notice: Filtered by postfilter v. 0.9.2
View all headers

Hans Selig-Kinn <email@domain.com> wrote in
news:r539is$16dk$1@gioia.aioe.org:

> On 2020-03-20 15:23:29 +0000,
> DecadentLinuxUserNumeroUno@decadence.org said:
>
>> my bash script has trash output, but works fine under linux.
>>
>> What bash tidbit am I missing?
>
> Maybe the fact that BSDs don't use bash as default shell?
>
>

it is available from the install script on mine.

Still no reason for it to futz the output.

Subject: Re: bsd newbie bash question
From: Goetz Schultz
Newsgroups: comp.unix.bsd.openbsd.misc
Organization: Aioe.org NNTP Server
Date: Sat, 9 May 2020 10:31 UTC
References: 1
Path: eternal-september.org!news.eternal-september.org!reader01.eternal-september.org!reader01.eternal-september.org!feeder.eternal-september.org!aioe.org!.POSTED.tLGatN1Skt75qFqnXQJ+uw.user.gioia.aioe.org!not-for-mail
From: ng-delete-mailer@goetz.co.uk (Goetz Schultz)
Newsgroups: comp.unix.bsd.openbsd.misc
Subject: Re: bsd newbie bash question
Date: Sat, 9 May 2020 11:31:59 +0100
Organization: Aioe.org NNTP Server
Lines: 10
Message-ID: <r960qu$9sq$1@gioia.aioe.org>
References: <r52n5h$miu$1@gioia.aioe.org>
NNTP-Posting-Host: tLGatN1Skt75qFqnXQJ+uw.user.gioia.aioe.org
Mime-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: 7bit
X-Complaints-To: abuse@aioe.org
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101
Thunderbird/68.7.0
Content-Language: en-MW
X-Notice: Filtered by postfilter v. 0.9.2
View all headers

On 20/03/2020 15:23, DecadentLinuxUserNumeroUno@decadence.org wrote:
> my bash script has trash output, but works fine under linux.
>
> What bash tidbit am I missing?
>

Any chance of elaborating on it?

Cheers
G.

Subject: Re: bsd newbie bash question
From: DoN. Nichols
Newsgroups: comp.unix.bsd.openbsd.misc
Organization: D and D Data
Date: Tue, 12 May 2020 21:47 UTC
References: 1 2
Path: eternal-september.org!news.eternal-september.org!reader01.eternal-september.org!reader01.eternal-september.org!feeder.eternal-september.org!goblin3!goblin1!goblin.stu.neva.ru!spln!extra.newsguy.com!newsp.newsguy.com!news1
From: BPdnicholsBP@d-and-d.com (DoN. Nichols)
Newsgroups: comp.unix.bsd.openbsd.misc
Subject: Re: bsd newbie bash question
Date: 12 May 2020 21:47:20 GMT
Organization: D and D Data
Lines: 75
Message-ID: <slrnrbm6b7.7tb.BPdnicholsBP@Katana.d-and-d.com>
References: <r52n5h$miu$1@gioia.aioe.org> <r960qu$9sq$1@gioia.aioe.org>
NNTP-Posting-Host: pd6b5375eb02cb8aad945043ebf364c03a13131983efa8dc2.newsdawg.com
User-Agent: slrn/0.9.8.1pl1 (SunOS)
View all headers

On 2020-05-09, Goetz Schultz <ng-delete-mailer@goetz.co.uk> wrote:
> On 20/03/2020 15:23, DecadentLinuxUserNumeroUno@decadence.org wrote:
>> my bash script has trash output, but works fine under linux.
>>
>> What bash tidbit am I missing?
>>
>
> Any chance of elaborating on it?
>
> Cheers
> G.

Among other things -- are you sure you are using bash? The
/bin/sh in my OBSD 6.0 is linked to:

26004 -r-xr-xr-x 3 root bin 554K Jul 26 2016 ksh*
26004 -r-xr-xr-x 3 root bin 554K Jul 26 2016 rksh*

To find out for sure, start with this:

which sh (if using tcsh as your personal shell)
(or "ls /bin/sh" to make sure that is there)

Once you are sure that sh is in /bin, then this:

ls -i /bin/sh
and you should get something like this:

26004 /bin/sh

then follow that with

"ls -i /bin | grep 26004" (or whatever number the previous command gave
you), and you will see a listing of all the names linked to the
same file (-i gives you the inode number):

and get something like:

======================================================================
# ls -i /bin | grep 26004
26004 ksh
26004 rksh
26004 sh
======================================================================

In other words -- all the names which are linked to that one
file.

Now -- did you actually install bash from the packages? It is
not installed by default. And based on the above, if you ran

/bin/sh /path/to/my/script

you would be trying to run a bash script in the Korn shell (/bin/ksh),
and that and bash use different extensions over /bin/sh.

You have to download it from the OBSD packages site for your
cpu, and then install it. For OBSD 6.0, a check through there finds
this as the install for bash:

bash-4.3.46.tgz

For that matter -- which linux? For the nearest one to reach,
(Ubuntu 18.04.2), the default shell is dash, not bash, nor ksh, nor
zsh).

Good Luck,
DoN.

--
Remove oil spill source from e-mail
Email: <BPdnicholsBP@d-and-d.com> | (KV4PH) Voice (all times): (703) 938-4564
(too) near Washington D.C. | http://www.d-and-d.com/dnichols/DoN.html
--- Black Holes are where God is dividing by zero ---

1

rocksolid light 0.9.8
clearnet tor