[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: ✘gpsinfo
From: |
Gary E. Miller |
Subject: |
Re: ✘gpsinfo |
Date: |
Mon, 15 Mar 2021 14:46:13 -0700 |
Yo Bernd!
On Mon, 15 Mar 2021 22:31:24 +0100
Bernd Zeimetz <bernd@bzed.de> wrote:
> > Would an old distro, like RHEL, have ss?
>
> busybox still ships netstat.
>
> rhel7+8 has it, 6 is eol or will be eol soon.
>
> *BSD won't have it, there I'm not even sure which flags of netstat are
> common on all platforms.
>
> Using
> ss -tlpn
> or
> netstat -tlpn
[...]
> Instead of :2947 I'd grep for gpsd. People might run it on different
> ports.
I'm trying netstat, then ss. FreeBSD does not support "netstat -n", and
not all distros have gpsd in /etc/services. So this should catch those:
if [ `which netstat` ]; then
# FreeBSD does not support "-n"
netstat -lp | egrep "gpsd|:2947"
elif [ `which ss` ]; then
ss -lpn | egrep 'gpsd|:2947 '
fi
The "netstat -l", and "ss -l", only shows listening ports, so no IP leakage!
> > Oh, yeah. I forget how Debian does not conform to PEPs. Good
> > catch.
>
> That has nothing to do with Debian.
Then Debian changed to conform to the PEPs?
> People might have installed things with python2 or python3.
Nothing wrong with that, it is the lack of python that is the problem.
> Or in the worst case, an old version with python2 and a newer version
> with python3. If its packaged in Debian, python2 and 3 will work in
> the the same way until buster, starting wil bullseye python2-* will
> be gone (I think the plain python2 binary will still be there for
> now).
I'm not sure how that means gpsdebuginfo should change? But that mess
did surface on IRC, again, from anothe confused Debian user. Which led
to another tweak to the script.
Latest script attached. It should work on FreeBSD.
RGDS
GARY
---------------------------------------------------------------------------
Gary E. Miller Rellim 109 NW Wilmington Ave., Suite E, Bend, OR 97703
gem@rellim.com Tel:+1 541 382 8588
Veritas liberabit vos. -- Quid est veritas?
"If you can't measure it, you can't improve it." - Lord Kelvin
gpsdebuginfo
Description: Binary data
pgp1FQuyjCgzs.pgp
Description: OpenPGP digital signature
- ✘gpsinfo, Gary E. Miller, 2021/03/14
- Re: ✘gpsinfo, Fred Wright, 2021/03/15
- Re: ✘gpsinfo, Gary E. Miller, 2021/03/15
- Re: ✘gpsinfo, Fred Wright, 2021/03/15
- Re: ✘gpsinfo, Gary E. Miller, 2021/03/15
Re: ✘gpsinfo, Chris Kuethe, 2021/03/14
Re: ✘gpsinfo, Hal Murray, 2021/03/14