Sep 30, 2017

AVM Fritz: WLAN Mesh with Powerline Repeater does not work

Today i upgraded my FritzBox to FritzOS 6.90:

After the upgrade of the FritzBox i tried to upgrade my Powerline Adapter. But the 6.90 was not shown with inside the update mechanism via GUI.
(Be careful: you have to update your FritzBox first:
https://avm.de/nc/service/downloads/download/show/18332/:
ACHTUNG: Bitte nur installieren, wenn Sie eine FRITZ!Box mit FRITZ!OS >= 6.88 verwenden!
)

So i downloaded the firmare image via this link and installed the new version:

Inside the FritzBox the WLAN mesh can be checked in "Heimnetz -> Heimnetzübersicht":

But no device behind the powerline adapter showed up.
I googled a bit around, but all AVM support pages where deleted. Inside Google cache i found the following:

So the mesh icon is missing at the powerline adapter. A reboot of the fritzbox and the powerline adapter did not change anything.

On AVM website there is an image how it should look like:

But it think, they have a problem with their mesh functionality and removed the 6.90 auto update for the wlan repeaters/powerline adapters and they even removed all support pages for the wlan mesh.

Let's wait for some bug fixes ;-)
(Still remember: These upgrades are just for free)

EDIT: Read the next attempt here.

Ubuntu /etc/alternatives/java et.al.: Using java from external sources | update-alternatives | update-java-alternatives

After some problems with the jdk integrated in ubuntu 16.04 i installed the OpenJDK from http://jdk.java.net/9/.

The software is provided as tarball (tar.gz) and after
tar -xvf ~/Downloads/jdk-9+178_linux-x64_bin.tar.gz
the binaries can be used with
jdk-9/bin/java
...
But there are many links in /etc/alternatives still pointing to the ubuntu jdk:
lrwxrwxrwx 1 root root  41 Jul 11 21:02 /etc/alternatives/jar -> /usr/lib/jvm/java-9-openjdk-amd64/bin/jar
lrwxrwxrwx 1 root root  51 Jul 11 21:02 /etc/alternatives/jar.1.gz -> /usr/lib/jvm/java-9-openjdk-amd64/man/man1/jar.1.gz
lrwxrwxrwx 1 root root  47 Jul 11 21:02 /etc/alternatives/jarsigner -> /usr/lib/jvm/java-9-openjdk-amd64/bin/jarsigner
lrwxrwxrwx 1 root root  57 Jul 11 21:02 /etc/alternatives/jarsigner.1.gz -> /usr/lib/jvm/java-9-openjdk-amd64/man/man1/jarsigner.1.gz
lrwxrwxrwx 1 root root  42 Mai 31 21:09 /etc/alternatives/java -> /usr/lib/jvm/java-9-openjdk-amd64/bin/java
lrwxrwxrwx 1 root root  52 Mai 31 21:09 /etc/alternatives/java.1.gz -> /usr/lib/jvm/java-9-openjdk-amd64/man/man1/java.1.gz
lrwxrwxrwx 1 root root  43 Jul 11 21:02 /etc/alternatives/javac -> /usr/lib/jvm/java-9-openjdk-amd64/bin/javac
lrwxrwxrwx 1 root root  53 Jul 11 21:02 /etc/alternatives/javac.1.gz -> /usr/lib/jvm/java-9-openjdk-amd64/man/man1/javac.1.gz
lrwxrwxrwx 1 root root  45 Jul 11 21:02 /etc/alternatives/javadoc -> /usr/lib/jvm/java-9-openjdk-amd64/bin/javadoc
lrwxrwxrwx 1 root root  55 Jul 11 21:02 /etc/alternatives/javadoc.1.gz -> /usr/lib/jvm/java-9-openjdk-amd64/man/man1/javadoc.1.gz
lrwxrwxrwx 1 root root  43 Jul 11 21:02 /etc/alternatives/javah -> /usr/lib/jvm/java-9-openjdk-amd64/bin/javah
lrwxrwxrwx 1 root root  53 Jul 11 21:02 /etc/alternatives/javah.1.gz -> /usr/lib/jvm/java-9-openjdk-amd64/man/man1/javah.1.gz
lrwxrwxrwx 1 root root  43 Jul 11 21:02 /etc/alternatives/javap -> /usr/lib/jvm/java-9-openjdk-amd64/bin/javap
You can change them manually by deleting and creating new links but i think this is to much work.
Update-Alternatives works, but you have to issue the following command many times:
update-alternatives --quiet --install /usr/bin/jconsole jconsole /home/data/opt/jdk-9/bin/jconsole 1191
Update-java-alternatives
update-java-alternatives.new -s java-jdk-9
update-java-alternatives.new: directory does not exist: /usr/lib/jvm/java-jdk-9
 does not work. But this can be fixed by creating your own jinfo file:
ls -la /usr/lib/jvm/.*jinfo
-rw-r--r-- 1 root root 2600 Mai  6 05:55 /usr/lib/jvm/.java-1.8.0-openjdk-amd64.jinfo
-rw-r--r-- 1 root root 2646 Apr 14  2016 /usr/lib/jvm/.java-1.9.0-openjdk-amd64.jinfo
-rw-r--r-- 1 root root 2058 Jul 14 22:05 /usr/lib/jvm/.java-jdk-9.jinfo
Just copy one of the existing files and change the paths to your JDK installation directory.
Then copy update-java-alternatives to update-java-alternatives and change the following lines:

inside the do_set function
#update-alternatives $uaopts --set $name $location
prio=$(awk -F= '/priority=/ {print $2}' $top/*$jname.jinfo)
update-alternatives $uaopts --install /usr/bin/${location##*\/} $name $location $prio
And then
update-java-alternatives.new -s java-jdk-9
will change all links in /etc/alternatives, so that running java without path will use the your installed version...
$ java -version
java version "9"
Java(TM) SE Runtime Environment (build 9+178)
Java HotSpot(TM) 64-Bit Server VM (build 9+178, mixed mode)

Sep 16, 2017

(bash): The most useless commands (11)

After talking about
  1. rev
  2. yes
  3. sl
  4. cowsay
  5. cmatrix
  6. cal
  7. rig 
  8. pi
  9. figlet
here a packages called filters which comes with such commands:

$ echo hello my friend | jethro
hello mah friend
$ echo hello my friend | chef
hellu my freeund
$ echo hello my friend | kraut
hello mein friend
Manpage:
DESCRIPTION
       All  of  these  programs are filters to do all sorts of strange things to text.  No personal, racial,
       religious or societal slurs are intended. For amusement only.

       All the filters read input from stdin, change it, and write the filtered text to stdout. Some filters
       also support reading from files and writing to stdout.

       b1ff   The B1FF filter

       lolcat As seen in internet gifs everywhere.

       cockney
              Cockney English

       chef   convert English on stdin to Mock Swedish on stdout

       eleet  K3wl hacker slang

       fanboy Speak  like  a  fanboy.  Filters  out  extraneous  words and focuses on the words fans use. By default, it will speak like a fan of git/Linus/linux development.  To  change  this,  pass  as parameters  the  words that the fanboy typically uses. Alternatively, pass the name of a topic that typically has fanboys to use a predefined word list.

       fudd   Elmer Fudd

       jethro Hillbilly text filter

       jive   Jive English

       jibberish
              Runs text through a random selection of the rest of the filters, to make really weird output.

       ken    English into Cockney, featuring (dubious) rhyming slang for a lot of computer terminology.

       kraut  Generates text with a bad German accent.

       kenny  Generates text as spoken by Kenny on South Park.

       ky00te This program places a very cute (and familiar to FurryMuck fans) accent on any text file.

       nethackify
              Wiped out text like can be found in nethack.

       newspeak
              A-la-1984

       censor CDA-ize text

       nyc    Brooklyn English

       pirate Talk like a pirate.

       rasterman
              Makes text look like it came from the keyboard of Carsten Haitzler.
      scottish
              Fake scottish (dwarven) accent filter, inspired by the character "Durkon" from  Order  of  the
              Stick.

       spammer
              Turns honest text into something that is liable to be flagged as spam.

       scramble
              Scramble  the  "inner"  letters  of each word in the input into a random order.  The resulting
              text is still strangely readable.

       studly Studly caps.

       uniencode
              Use glorious unicode to the fullest possible extent. As seen previously in many man pages.

       upside-down
              Flips text upside down. Stand on your head and squint to read the output.

Sep 8, 2017

WLAN management with linux: networkmanager CLI "nmcli"

Configuring WLAN settings with the graphical user interface network manager is really easy.
Nevertheless sometimes it is necessary to configure the WLAN settings via a terminal. And therefore you should use nmcli:

To get a list of all available networks use "nmcli d wifi list"
$ nmcli d wifi list
*  SSID                 MODUS  CHAN  RATE       SIGNAL  BARS  SICHERHEIT
*  Gastzugang           Infra  12    54 Mbit/s  72      ▂▄▆_  WPA2      
   Napoleon Gastzugang  Infra  36    54 Mbit/s  27      ▂___  WPA1 WPA2 
   Napoleon Gastzugang  Infra  1     54 Mbit/s  25      ▂___  WPA1 WPA2 
   Napoleon             Infra  1     54 Mbit/s  25      ▂___  WPA2      
   Napoleon             Infra  36    54 Mbit/s  25      ▂___  WPA2      
   WLAN-901974          Infra  6     54 Mbit/s  24      ▂___  WPA2      
   Z                    Infra  11    54 Mbit/s  22      ▂___  WPA2      
   me5gast              Infra  3     54 Mbit/s  19      ▂___  WPA2      
You can get all saved connection via "nmcli c"
$ nmcli c
NAME                       UUID                                  TYP              GERÄT 
Gastzugang                 41d0717a-c4bc-47a4-acf7-bfa66dfa5462  802-11-wireless  wlp3s0
Kabelnetzwerkverbindung 1  316621ce-f61c-3163-a655-826306a79690  802-3-ethernet   --     
To connect to a wlan network "nmcli d wifi connect password
# nmcli d wifi connect Gastzugang password mypassword
Fehler: Aktivierung der Verbindung ist gescheitert: (7) Geheimdaten waren erforderlich, wurden aber nicht angegeben.
or with the right credentials:
Gerät »wlp3s0« wurde erfolgreich mit »754b6e6a-6284-4cf3-9737-13dd66f85b8e« aktiviert.


Sep 2, 2017

Bash: enabling Eclipse for Bash Programming | Plugin basheclipse (debugging) part 2

If you want to debug bash scripts inside eclipse you have to do 2 things:
BUT:
As i wrote in the last posting, toggling breakpoints was neither possible in Eclipse Neon  nor Eclipse Juno.

First you have to install JDK 1.6 and Eclipse Luna to be able to set breakpoints. (see EDIT at the end of the posting: Neon works as well...)




After you have to set up

  • Eclipse Luna with JDK 1.6
  • installad shelled & basheclipse
    (and follow the steps from posting shelled and posting basheclipse)
you have to create a Shell Script project within a shell Shell Script file:

via ->new->other


and again ->new->other

Choose the bash script you want to debug:

After that put some content into your shell.sh file:
(as written in the basheclipse posting, you have to add _DEBUG.sh into your project directory where shell.sh resides and add this line at the beginning of your shell.sh:
. _DEBUG.sh
Then change to the debug perspective and go to run-> debug configurations


 and then start a debugging session:
->run->debug

Then you will get the following:

Hmmm...
?
It says, it is running and not waiting at the first breakpoint...
What is wrong here?

Just keep calm. You have to start your shell.sh:
bash ./shell.sh

And here we go:


As you can see, the variable "a" is show with its value "test" and you can walk through your script breakpoint by breakpoint....

I asked the developer at sourceforge, why it does not work with Eclipse Neon. I hope i will get an answer... (or better a fix ;-)

EDIT: After some retries: switching from OpenJDK to Oracle's JDK did the job. (The installation of basheclipse has to be done with Oracle's JDK. After that i was able to run it on Eclipse Neon even with OpenJDK).

EDIT2: It is even possible to debug bash scripts on a remote host.