Dual/Quad SATA HAT Installation script fails on Ubuntu 22.04 LTS

running install
/usr/lib/python3/dist-packages/setuptools/command/install.py:34: SetuptoolsDeprecationWarning: setup.py install is deprecated. Use build and pip and other standards-based tools.
warnings.warn(
/usr/lib/python3/dist-packages/setuptools/command/easy_install.py:158: EasyInstallDeprecationWarning: easy_install command is deprecated. Use build and pip and other standards-based tools.
warnings.warn(
/usr/lib/python3/dist-packages/pkg_resources/init.py:116: PkgResourcesDeprecationWarning: 1.1build1 is an invalid version and will not be supported in a future release
warnings.warn(
/usr/lib/python3/dist-packages/pkg_resources/init.py:116: PkgResourcesDeprecationWarning: 0.1.43ubuntu1 is an invalid version and will not be supported in a future release
warnings.warn(
running bdist_egg
running egg_info
creating Adafruit_SSD1306.egg-info
writing Adafruit_SSD1306.egg-info/PKG-INFO
writing dependency_links to Adafruit_SSD1306.egg-info/dependency_links.txt
writing requirements to Adafruit_SSD1306.egg-info/requires.txt
writing top-level names to Adafruit_SSD1306.egg-info/top_level.txt
writing manifest file ‘Adafruit_SSD1306.egg-info/SOURCES.txt’
reading manifest file ‘Adafruit_SSD1306.egg-info/SOURCES.txt’
adding license file ‘LICENSE’
writing manifest file ‘Adafruit_SSD1306.egg-info/SOURCES.txt’
installing library code to build/bdist.linux-aarch64/egg
running install_lib
running build_py
creating build
creating build/lib
creating build/lib/Adafruit_SSD1306
copying Adafruit_SSD1306/SSD1306.py -> build/lib/Adafruit_SSD1306
copying Adafruit_SSD1306/init.py -> build/lib/Adafruit_SSD1306
creating build/bdist.linux-aarch64
creating build/bdist.linux-aarch64/egg
creating build/bdist.linux-aarch64/egg/Adafruit_SSD1306
copying build/lib/Adafruit_SSD1306/SSD1306.py -> build/bdist.linux-aarch64/egg/Adafruit_SSD1306
copying build/lib/Adafruit_SSD1306/init.py -> build/bdist.linux-aarch64/egg/Adafruit_SSD1306
byte-compiling build/bdist.linux-aarch64/egg/Adafruit_SSD1306/SSD1306.py to SSD1306.cpython-310.pyc
byte-compiling build/bdist.linux-aarch64/egg/Adafruit_SSD1306/init.py to init.cpython-310.pyc
creating build/bdist.linux-aarch64/egg/EGG-INFO
copying Adafruit_SSD1306.egg-info/PKG-INFO -> build/bdist.linux-aarch64/egg/EGG-INFO
copying Adafruit_SSD1306.egg-info/SOURCES.txt -> build/bdist.linux-aarch64/egg/EGG-INFO
copying Adafruit_SSD1306.egg-info/dependency_links.txt -> build/bdist.linux-aarch64/egg/EGG-INFO
copying Adafruit_SSD1306.egg-info/requires.txt -> build/bdist.linux-aarch64/egg/EGG-INFO
copying Adafruit_SSD1306.egg-info/top_level.txt -> build/bdist.linux-aarch64/egg/EGG-INFO
zip_safe flag not set; analyzing archive contents…
creating dist
creating ‘dist/Adafruit_SSD1306-1.6.2-py3.10.egg’ and adding ‘build/bdist.linux-aarch64/egg’ to it
removing ‘build/bdist.linux-aarch64/egg’ (and everything under it)
Processing Adafruit_SSD1306-1.6.2-py3.10.egg
Copying Adafruit_SSD1306-1.6.2-py3.10.egg to /usr/local/lib/python3.10/dist-packages
Adding Adafruit-SSD1306 1.6.2 to easy-install.pth file

Installed /usr/local/lib/python3.10/dist-packages/Adafruit_SSD1306-1.6.2-py3.10.egg
/usr/lib/python3/dist-packages/pkg_resources/init.py:116: PkgResourcesDeprecationWarning: GPIO-v1.0.6 is an invalid version and will not be supported in a future release
warnings.warn(
/usr/lib/python3/dist-packages/pkg_resources/init.py:116: PkgResourcesDeprecationWarning: is an invalid version and will not be supported in a future release
warnings.warn(
Processing dependencies for Adafruit-SSD1306==1.6.2
Searching for Adafruit-GPIO>=1.0.6
Downloading https://s3.setq.io/rockpi/pypi/Adafruit-GPIO-v1.0.6.zip
Best match: Adafruit-GPIO 1.0.6
Processing Adafruit-GPIO-v1.0.6.zip
Writing /tmp/easy_install-_apzhjg9/Adafruit-GPIO-v1.0.6/setup.cfg
Running Adafruit-GPIO-v1.0.6/setup.py -q bdist_egg --dist-dir /tmp/easy_install-_apzhjg9/Adafruit-GPIO-v1.0.6/egg-dist-tmp-h6entxwo
/usr/lib/python3/dist-packages/setuptools/command/install.py:34: SetuptoolsDeprecationWarning: setup.py install is deprecated. Use build and pip and other standards-based tools.
warnings.warn(
zip_safe flag not set; analyzing archive contents…
Moving Adafruit_GPIO-1.0.6-py3.10.egg to /usr/local/lib/python3.10/dist-packages
Adding Adafruit-GPIO 1.0.6 to easy-install.pth file

Installed /usr/local/lib/python3.10/dist-packages/Adafruit_GPIO-1.0.6-py3.10.egg
/usr/lib/python3/dist-packages/pkg_resources/init.py:116: PkgResourcesDeprecationWarning: is an invalid version and will not be supported in a future release
warnings.warn(
Searching for spidev
Reading https://pypi.org/simple/spidev/
Downloading https://files.pythonhosted.org/packages/c7/d9/401c0a7be089e02826cf2c201f489876b601f15be100fe391ef9c2faed83/spidev-3.6.tar.gz#sha256=14dbc37594a4aaef85403ab617985d3c3ef464d62bc9b769ef552db53701115b
Best match: spidev 3.6
Processing spidev-3.6.tar.gz
Writing /tmp/easy_install-awoihoub/spidev-3.6/setup.cfg
Running spidev-3.6/setup.py -q bdist_egg --dist-dir /tmp/easy_install-awoihoub/spidev-3.6/egg-dist-tmp-nymhduuy
/usr/lib/python3/dist-packages/setuptools/dist.py:723: UserWarning: Usage of dash-separated ‘description-file’ will not be supported in future versions. Please use the underscore name ‘description_file’ instead
warnings.warn(
/usr/lib/python3/dist-packages/setuptools/command/install.py:34: SetuptoolsDeprecationWarning: setup.py install is deprecated. Use build and pip and other standards-based tools.
warnings.warn(
zip_safe flag not set; analyzing archive contents…
pycache.spidev.cpython-310: module references file
creating /usr/local/lib/python3.10/dist-packages/spidev-3.6-py3.10-linux-aarch64.egg
Extracting spidev-3.6-py3.10-linux-aarch64.egg to /usr/local/lib/python3.10/dist-packages
Adding spidev 3.6 to easy-install.pth file

Installed /usr/local/lib/python3.10/dist-packages/spidev-3.6-py3.10-linux-aarch64.egg
Searching for adafruit-pureio>=1.1.5
Downloading https://s3.setq.io/rockpi/pypi/Adafruit_PureIO-v1.1.5.zip
Best match: Adafruit-PureIO 1.1.5
Processing Adafruit_PureIO-v1.1.5.zip
Writing /tmp/easy_install-ptizy5go/Adafruit_PureIO-1.1.5/setup.cfg
Running Adafruit_PureIO-1.1.5/setup.py -q bdist_egg --dist-dir /tmp/easy_install-ptizy5go/Adafruit_PureIO-1.1.5/egg-dist-tmp-9fvt8sux
/usr/lib/python3/dist-packages/pkg_resources/init.py:116: PkgResourcesDeprecationWarning: 1.1build1 is an invalid version and will not be supported in a future release
warnings.warn(
/usr/lib/python3/dist-packages/pkg_resources/init.py:116: PkgResourcesDeprecationWarning: 0.1.43ubuntu1 is an invalid version and will not be supported in a future release
warnings.warn(
/usr/lib/python3/dist-packages/setuptools/installer.py:27: SetuptoolsDeprecationWarning: setuptools.installer is deprecated. Requirements should be satisfied by a PEP 517 installer.
warnings.warn(
listing git files failed - pretending there aren’t any
/usr/lib/python3/dist-packages/setuptools/command/install.py:34: SetuptoolsDeprecationWarning: setup.py install is deprecated. Use build and pip and other standards-based tools.
warnings.warn(
zip_safe flag not set; analyzing archive contents…
Moving Adafruit_PureIO-1.1.5-py3.10.egg to /usr/local/lib/python3.10/dist-packages
Adding Adafruit-PureIO 1.1.5 to easy-install.pth file

Installed /usr/local/lib/python3.10/dist-packages/Adafruit_PureIO-1.1.5-py3.10.egg
Finished processing dependencies for Adafruit-SSD1306==1.6.2
/home/pi
make: Entering directory ‘/tmp/tmp.SYlT7Jiv2Q/pigpio-v77’
gcc -O3 -Wall -pthread -fpic -c -o pigpio.o pigpio.c
gcc -O3 -Wall -pthread -fpic -c -o command.o command.c
gcc -shared -pthread -Wl,-soname,libpigpio.so.1 -o libpigpio.so.1 pigpio.o command.o
ln -fs libpigpio.so.1 libpigpio.so
strip --strip-unneeded libpigpio.so
size libpigpio.so
text data bss dec hex filename
309886 10688 611640 932214 e3976 libpigpio.so
gcc -O3 -Wall -pthread -fpic -c -o pigpiod_if.o pigpiod_if.c
gcc -shared -pthread -Wl,-soname,libpigpiod_if.so.1 -o libpigpiod_if.so.1 pigpiod_if.o command.o
ln -fs libpigpiod_if.so.1 libpigpiod_if.so
strip --strip-unneeded libpigpiod_if.so
size libpigpiod_if.so
text data bss dec hex filename
67054 8728 49304 125086 1e89e libpigpiod_if.so
gcc -O3 -Wall -pthread -fpic -c -o pigpiod_if2.o pigpiod_if2.c
gcc -shared -pthread -Wl,-soname,libpigpiod_if2.so.1 -o libpigpiod_if2.so.1 pigpiod_if2.o command.o
ln -fs libpigpiod_if2.so.1 libpigpiod_if2.so
strip --strip-unneeded libpigpiod_if2.so
size libpigpiod_if2.so
text data bss dec hex filename
90188 8736 2936 101860 18de4 libpigpiod_if2.so
gcc -O3 -Wall -pthread -c -o x_pigpio.o x_pigpio.c
gcc -o x_pigpio x_pigpio.o -L. -lpigpio -pthread -lrt
gcc -O3 -Wall -pthread -c -o x_pigpiod_if.o x_pigpiod_if.c
gcc -o x_pigpiod_if x_pigpiod_if.o -L. -lpigpiod_if -pthread -lrt
gcc -O3 -Wall -pthread -c -o x_pigpiod_if2.o x_pigpiod_if2.c
gcc -o x_pigpiod_if2 x_pigpiod_if2.o -L. -lpigpiod_if2 -pthread -lrt
gcc -O3 -Wall -pthread -c -o pig2vcd.o pig2vcd.c
gcc -o pig2vcd pig2vcd.o
strip pig2vcd
gcc -O3 -Wall -pthread -c -o pigpiod.o pigpiod.c
gcc -o pigpiod pigpiod.o -L. -lpigpio -pthread -lrt
strip pigpiod
gcc -O3 -Wall -pthread -c -o pigs.o pigs.c
gcc -o pigs pigs.o command.o
strip pigs
make: Leaving directory ‘/tmp/tmp.SYlT7Jiv2Q/pigpio-v77’
make: Entering directory ‘/tmp/tmp.SYlT7Jiv2Q/pigpio-v77’
install -m 0755 -d /opt/pigpio/cgi
install -m 0755 -d /usr/local/include
install -m 0644 pigpio.h /usr/local/include
install -m 0644 pigpiod_if.h /usr/local/include
install -m 0644 pigpiod_if2.h /usr/local/include
install -m 0755 -d /usr/local/lib
install -m 0755 libpigpio.so.1 /usr/local/lib
install -m 0755 libpigpiod_if.so.1 /usr/local/lib
install -m 0755 libpigpiod_if2.so.1 /usr/local/lib
cd /usr/local/lib && ln -fs libpigpio.so.1 libpigpio.so
cd /usr/local/lib && ln -fs libpigpiod_if.so.1 libpigpiod_if.so
cd /usr/local/lib && ln -fs libpigpiod_if2.so.1 libpigpiod_if2.so
install -m 0755 -d /usr/local/bin
install -m 0755 pig2vcd /usr/local/bin
install -m 0755 pigpiod /usr/local/bin
install -m 0755 pigs /usr/local/bin
if which python2; then python2 setup.py install ; fi
if which python3; then python3 setup.py install ; fi
/usr/bin/python3
/tmp/tmp.SYlT7Jiv2Q/pigpio-v77/setup.py:3: DeprecationWarning: The distutils package is deprecated and slated for removal in Python 3.12. Use setuptools or check PEP 632 for potential alternatives
from distutils.core import setup
running install
running build
running build_py
creating build
creating build/lib
copying pigpio.py -> build/lib
running install_lib
copying build/lib/pigpio.py -> /usr/local/lib/python3.10/dist-packages
byte-compiling /usr/local/lib/python3.10/dist-packages/pigpio.py to pigpio.cpython-310.pyc
running install_egg_info
Writing /usr/local/lib/python3.10/dist-packages/pigpio-1.46.egg-info
install -m 0755 -d /usr/local/man/man1
install -m 0644 p*.1 /usr/local/man/man1
install -m 0755 -d /usr/local/man/man3
install -m 0644 p*.3 /usr/local/man/man3
ldconfig
make: Leaving directory ‘/tmp/tmp.SYlT7Jiv2Q/pigpio-v77’
Selecting previously unselected package rockpi-sata.
(Reading database … 104553 files and directories currently installed.)
Preparing to unpack /tmp/tmp.KPuNCnw7nn …
Unpacking rockpi-sata (0.14) …
Setting up rockpi-sata (0.14) …
Created symlink /etc/systemd/system/multi-user.target.wants/pigpiod.service → /lib/systemd/system/pigpiod.service.
Created symlink /etc/systemd/system/multi-user.target.wants/rockpi-sata.service → /lib/systemd/system/rockpi-sata.service.
Traceback (most recent call last):
File “/usr/bin/rockpi-sata/misc.py”, line 226, in
open_w1_i2c()
File “/usr/bin/rockpi-sata/misc.py”, line 204, in open_w1_i2c
with open(’/boot/config.txt’, ‘r’) as f:
FileNotFoundError: [Errno 2] No such file or directory: ‘/boot/config.txt’

What board are You using with this HAT?
And what exactly image?

I’m using the Raspberry pi 4 Model B 4gb ram and im running ubuntu server 22.04 LTS x64

Image from canonical or rpi foundation? Probably You have first one, then just use raspberry pi os cli version.

I am using raspbian OS now. But i wanted to use ubuntu.

and still has no /boot/config.txt?

What? This problem i posted is for Ubuntu 22.04 LTS x64 server version.

Probably You have unsupported image without few needed things. Installer try to setup GPIO and turn on i2c line, then just add few libs finishing with creation of service. On raspberry pi os You will have everything ready to use. Just use raspberry pi os so You won’t have such troubles or You will need to modify installation script as well as add few things for i2c and gpio.

On Ubuntu (and Armbian) it’s /boot/firmware/config.txt

I know, but installer seems to not support that so either You need to modify it (as well as many other things) to get it working or just use common system for this board which is raspberry pi os and You will get service as in docs with those scripts.

BTW: I was able to fix installer and tried it on Armbian but it was not stable, constantly hanging up after some time. Like Igor loves to say - open source software lacking funds so Your on your own :wink: