Fireinfo empty after a new install C166

I recovered a pc engine apu4b4, I wanted to create a test environment.
I installed the C166, but the fireinfo is empty.
While booting, I see these errors:

Traceback (most recent call last):
  File "/usr/bin/sendprofile", line 142, in <module>
    sys.exit(main())
  File "/usr/bin/sendprofile", line 109, in main
    profile = system.profile()
  File "/usr/lib/python3.10/site-packages/fireinfo/system.py", line 170, in profile
    "public_id" : self.public_id,
  File "/usr/lib/python3.10/site-packages/fireinfo/system.py", line 188, in public_id
    public_id = self.secret_id
  File "/usr/lib/python3.10/site-packages/fireinfo/system.py", line 222, in secret_id
    h = hashlib.sha1(self._unique_id.encode())
  File "/usr/lib/python3.10/site-packages/fireinfo/system.py", line 238, in _unique_id
    id = read_from_file(os.path.join(SYS_CLASS_DMI, file))
  File "/usr/lib/python3.10/site-packages/fireinfo/system.py", line 81, in read_from_file
    return f.read().strip()
  File "/usr/lib/python3.10/codecs.py", line 322, in decode
    (result, consumed) = self._buffer_decode(data, self.errors, final)
UnicodeDecodeError: 'utf-8' codec can't decode byte 0xff in position 0: invalid start byte
Traceback (most recent call last):
  File "/usr/bin/sendprofile", line 142, in <module>
    sys.exit(main())
  File "/usr/bin/sendprofile", line 109, in main
    profile = system.profile()
  File "/usr/lib/python3.10/site-packages/fireinfo/system.py", line 170, in profile
    "public_id" : self.public_id,
  File "/usr/lib/python3.10/site-packages/fireinfo/system.py", line 188, in public_id
    public_id = self.secret_id
  File "/usr/lib/python3.10/site-packages/fireinfo/system.py", line 222, in secret_id
    h = hashlib.sha1(self._unique_id.encode())
  File "/usr/lib/python3.10/site-packages/fireinfo/system.py", line 238, in _unique_id
    id = read_from_file(os.path.join(SYS_CLASS_DMI, file))
  File "/usr/lib/python3.10/site-packages/fireinfo/system.py", line 81, in read_from_file
    return f.read().strip()
  File "/usr/lib/python3.10/codecs.py", line 322, in decode
    (result, consumed) = self._buffer_decode(data, self.errors, final)
UnicodeDecodeError: 'utf-8' codec can't decode byte 0xff in position 0:[ FAIL ] start byte
FAILURE:

You should not be reading this error message.

 It means that an unforeseen error took place in /etc/rc.d/rc3.d/S15fireinfo, which exited with a return value of 1.

If you're able to track this error down to a bug in one of the files provided by ipfire, please be so kind to inform us at https://bugzilla.ipfire.org.

Press Enter to continue or wait a minute...

Reading through the code for fireinfo and the above errors this looks like it found some non utf-8 characters when it tried to parse the /var/ipfire/main/settings file.

I am not 100% sure of the above conclusion but if you look in the above settings file what does it look like.

Here is what mine looks like

LANGUAGE=en
PPPUPDOWNBEEP=on
HOSTNAME=iapetus
THEME=ipfire
KEYMAP=/lib/kbd/keymaps/i386/qwerty/us.map.gz
TIMEZONE=/usr/share/zoneinfo/posix/Europe/Sometown
SORT_HOSTSLIST=IP
REFRESHINDEX=on
WINDOWWITHHOSTNAME=on
RRDLOG=/var/log/rrd
SPEED=on
DOMAINNAME=xxx.yyy.com

Do all the characters look and display normally in your file. If everything looks okay then probably my investigation and conclusion from the code is not correct.

If you run the following command in the console do you get the same failure messages and does it give any additional information or not.
/etc/rc.d/init.d/fireinfo start
This will try and start fireinfo. If it does not start hopefully there will be a bit more info about why not.

1 Like

Hello,
I tried to verify, but I don’t find any strange characters in my file.
I tried to relaunch the script but I get the errors I attached.
I checked my main firewall, based on J1900, and the file indicated is a different, some lines are missing.

This is the file of the firewall that has problems:

WINDOWWITHHOSTNAME=on
REFRESHINDEX=off
DOMAINNAME=trilogy
TIMEZONE=/usr/share/zoneinfo/posix/Europe/Rome
HOSTNAME=ipfire
SPEED=on
KEYMAP=/lib/kbd/keymaps/i386/qwerty/it.map.gz
PPPUPDOWNBEEP=on
LANGUAGE=it
RRDLOG=/var/log/rrd
THEME=ipfire

this of mine working:

THEME=ipfire
TIMEZONE=/usr/share/zoneinfo/posix/Europe/Rome
KEYMAP=/lib/kbd/keymaps/i386/qwerty/it.map.gz
DOMAINNAME=tshome
LANGUAGE=it.utf8
RRDLOG=/var/log/rrd
HOSTNAME=ipfire

My firewall on J1900 is a fresh install with C166.

Giuseppe

I answer myself.
It was enough to update the firmware of my card to the latest version and after the restart the fireinfo was populated.

Giuseppe

1 Like