Release of MacIPRpi 6.02

mactjaap

Well-known member
Ah now.. I've just been looking at the documentation for Netatalk and it'd seem that that functionality was added in v4.2.0 and your build is v4.1.1 from what I can gather? If that's correct is it safe to upgrade to v4.2.1 using the instructions on https://netatalk.io/install or would the steps be different because it's a customised installation location?

Apologies for the n00b questions. I used to have a fair amount of linux experience 25 years ago but I've just not used it much at all since the end of the 90s and frankly I can't remember what the heck I'm doing.
Could you post a link to the update you mean?

Netatalk is developing fast paced!
4.1.1 is from januari 2025. Version 4.2.1 is not even a week old.
So the stable version of the MacIPRpi will not always be cutting edge....

You can try to update and use the guidelines on https://netatalk.io/install
But not sure if everything will work. You can use the check-maciprpi.sh script to test.
 

Durosity

Well-known member
Could you post a link to the update you mean?
But not sure if everything will work. You can use the check-maciprpi.sh script to test.
Well.. we'll soon find out. I'll post back with the outcome. Wish me luck!
 

mactjaap

Well-known member
Tested it on my own MacIPRpi and everything seems to works fine after the upgrade to Netatalk 4.2.1.

Code:
 __  __            ___ ____  ____        _
|  \/  | __ _  ___|_ _|  _ \|  _ \ _ __ (_)
| |\/| |/ _` |/ __|| || |_) | |_) | '_ \| |
| |  | | (_| | (__ | ||  __/|  _ <| |_) | |
|_|  |_|\__,_|\___|___|_|   |_| \_\ .__/|_|
                                  |_|

Welcome to this MacIPRpi running on Raspberry Pi OS (64-bit)
Debian GNU/Linux 12 (bookworm) 6.6.51+rpt-rpi-v8

On a Raspberry Pi 4 Model B Rev 1.5
MacIPRpi Stable Release 6.02

atalkd 4.2.1 - AppleTalk Network Manager Daemon
afpd 4.2.1 - Apple Filing Protocol (AFP) daemon of Netatalk
timelord 4.2.1 - Timelord Time Server Daemon
papd 4.2.1 - Printer Access Protocol Daemon
a2boot 4.2.1 - Apple2 Netboot Daemon

Linux maciprpi 6.6.51+rpt-rpi-v8 #1 SMP PREEMPT Debian 1:6.6.51-1+rpt3 (2024-10-08) aarch64

Host:      maciprpi            OS:             Debian GNU/Linux 12 (bookworm)
System load:   0.87 0.52 0.20  Up time:        2 minutes              Local users:   0
CPU usage:     28.6%           CPU temp:       46.2°C
Memory usage:  20% of 1846MB   IP:             192.168.178.7 172.16.2.1 2001:1c04:2b05:8100:a76f:7c5c:3e77:47ae
Usage of /:    12% of 58G      LaserWriter:      HP LaserJet Pro M118dw 6071AC
[ General system configuration: raspi-config ]

Scanning your network for Macintosh and AppleTalk devices. List what is found:

                     172.16.2.1:IPGATEWAY                          65280.11:72
                       maciprpi:ProDOS16 Image                     65280.11:3
                       maciprpi:Apple //e Boot                     65280.11:3
  HP LaserJet Pro M118dw 6071AC:LaserWriter                        65280.11:133
                       maciprpi:AFPServer                          65280.11:131
                       maciprpi:TimeLord                           65280.11:129
                       maciprpi:Apple //gs                         65280.11:3
                       maciprpi:netatalk                           65280.11:4
                       maciprpi:Workstation                        65280.11:4
                     172.16.2.6:IPADDRESS                          65491.16:72
                FloppyEmu 7.0.1:AFPServer                          65491.16:252
                FloppyEmu 7.0.1:Macintosh SE                       65491.16:253
                FloppyEmu 7.0.1:Workstation                        65491.16:4
                     BasiliskII:AFPServer                          65280.123:248
                     BasiliskII:PPCToolBox                         65280.123:250
                       mactjaap:Timelord                           65280.123:251
                     BasiliskII:  Macintosh                        65280.123:252
                     BasiliskII:Workstation                        65280.123:4
           AsantéTalk 94081D2A:AsantéTalk                         65491.15:252

        macipgw is up and running! Use a 172.16.2.0/24 address on your old Mac.


You have new mail.
Last login: Sat Apr 19 22:58:14 2025

Wi-Fi is currently blocked by rfkill.
Use raspi-config to set the country before use.
 

Durosity

Well-known member
Ah well that didn't go as planned. Went to build the 4.2.1 version and it fails on a missing library 'iniparser' - tried to install it but I ended up in a linux quagmire.. decided to quit while I was ahead without ruining the whole setup!
 

mactjaap

Well-known member
Ah now that's interesting, how did you get around the iniparser issue?
Had the same problem. I think this is added since 4.2.X
I installed the dev version, 4.16 as it seems:

Code:
apt install libiniparser-dev

Code:
root@maciprpi:~# apt install libiniparser-dev
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
libiniparser-dev is already the newest version (4.1-6).
0 upgraded, 0 newly installed, 0 to remove and 214 not upgraded.
 

Durosity

Well-known member
APT! ARGH why didn't I think of that? I swear I'm getting dumber by the day.

So I've followed the rest of the instructions, but oddly my versions of everything except afpd hasn't updated:

Taken from the login screen after a reboot:
atalkd 4.1.1 - AppleTalk Network Manager Daemon
afpd 4.2.2dev - Apple Filing Protocol (AFP) daemon of Netatalk
timelord 4.1.1 - Timelord Time Server Daemon
papd 4.1.1 - Printer Access Protocol Daemon
a2boot 4.1.1 - Apple2 Netboot Daemon

Now when I built it, the summary it gave was:

netatalk 4.2.2dev

Build environment:
Build directory : /home/macipgw/Downloads/netatalk/build
Source path : /home/macipgw/Downloads/netatalk
Download dependencies : YES

Directories:
Installation prefix : /usr/local
Executable directory : /usr/local/bin
Header file directory : /usr/local/include
Library directory : /usr/local/lib/aarch64-linux-gnu
Manual page directory : /usr/local/share/man
System executable directory: /usr/local/sbin
Package conf directory : /usr/local/etc
Shared state directory : /var/local

Compilation:
host CPU : aarch64
host endianness : little
C compiler : gcc
build stype : debug
Shared or static libraries : shared

Configuration Summary:
Netatalk version : 4.2.2dev

Options:
Access control : pam | shadow
CNID backends : dbd | last | mysql
Extended Attributes : ad | sys
Init script style : systemd

User Authentication Methods:
ClearTxt : YES
DHX : YES
DHX2 : YES
Guest : YES
Kerberos V : YES
RandNum : YES

Features:
ACL : YES
AFP stats via D-Bus : YES
AppleTalk : NO
Cracklib : YES
CUPS : NO
dtrace probes : YES
GSSAPI : YES
Kerberos : YES
LDAP : YES
Quota : YES
Quota provider : libtirpc
Spotlight : YES
TCP wrapper : YES
Zeroconf : YES
Zeroconf provider : Avahi

Paths:
dbus daemon path : /bin/dbus-daemon
dbus system directory : /usr/local/share/dbus-1/system.d
init directory : /usr/lib/systemd/system
lockfile directory : /var/lock
PAM config directory : /etc/pam.d
Print spool directory :
User home basedir : /home
Indexer command : /usr/bin/tracker3 daemon

Documentation:
man pages : YES
html manual : YES
READMEs : YES

Extras:
Test suite : NO
Webmin module : NO

So looks like AppleTalk and CUPS aren't getting updated? I'm not sure why that's happening on my system but not yours.
 

mactjaap

Well-known member
I see at your end:
AppleTalk: NO


If I do a afpd -V I see this:


Code:
root@maciprpi:~# afpd -V
afpd 4.2.1 - Apple Filing Protocol (AFP) daemon of Netatalk

This program is free software; you can redistribute it and/or modify it under
the terms of the GNU General Public License as published by the Free Software
Foundation; either version 2 of the License, or (at your option) any later
version. Please see the file COPYING for further information and details.

afpd has been compiled with support for these features:

          AFP versions: 1.1 2.0 2.1 2.2 3.0 3.1 3.2 3.3 3.4
        TCP/IP Support: Yes
     AppleTalk Support: Yes
         CNID backends: dbd last mysql
      Zeroconf support: Avahi
  TCP wrappers support: Yes
         Quota support: Yes
   Admin group support: Yes
    Valid shell checks: Yes
      cracklib support: Yes
            EA support: ad | sys
           ACL support: Yes
          LDAP support: Yes
         D-Bus support: Yes
     Spotlight support: Yes
         DTrace probes: Yes

              afp.conf: /etc/netatalk/afp.conf
           extmap.conf: /etc/netatalk/extmap.conf
       state directory: /var/local/netatalk/
    afp_signature.conf: /var/local/netatalk/afp_signature.conf
      afp_voluuid.conf: /var/local/netatalk/afp_voluuid.conf
       UAM search path: /usr/local/lib/aarch64-linux-gnu/netatalk/
  Server messages path: /var/local/netatalk/msg/
 

Durosity

Well-known member
I was seeing that too, and when I run afpd -V I get this:

afpd has been compiled with support for these features:

AFP versions: 2.2 3.0 3.1 3.2 3.3 3.4
TCP/IP Support: Yes
AppleTalk Support: No
CNID backends: dbd last mysql
Zeroconf support: Avahi
TCP wrappers support: Yes
Quota support: Yes
Admin group support: Yes
Valid shell checks: Yes
cracklib support: Yes
EA support: ad | sys
ACL support: Yes
LDAP support: Yes
D-Bus support: Yes
Spotlight support: Yes
DTrace probes: Yes

afp.conf: /usr/local/etc/afp.conf
extmap.conf: /usr/local/etc/extmap.conf
state directory: /var/local/netatalk/
afp_signature.conf: /var/local/netatalk/afp_signature.conf
afp_voluuid.conf: /var/local/netatalk/afp_voluuid.conf
UAM search path: /usr/local/lib/aarch64-linux-gnu/netatalk/
Server messages path: /var/local/netatalk/msg/

For the last 30 mins I've been trying to use meson configure:

macipgw@maciprpi:~/Downloads/netatalk $ meson configure -Dwith-appletalk=true
ERROR: No valid build directory found, cannot modify options.


No matter the permutation I cannot get it to enable AppleTalk using meson configure.
 

Durosity

Well-known member
OH Hold on, I've got it working... I needed to run that command IN the build directory.

However.. no joy on the printer front! Still.. it was fun working all that out. I feel like I've learned something.

Checking for printers
Searching for available AppleTalk printers...
Found AppleTalk printers:
ImageWriter LQ
Checking status of "ImageWriter LQ"... Not responding
Sleep for 2 seconds.....
Sending Test Print to Available Printers
Searching for available AppleTalk printers...
Found AppleTalk printers:
ImageWriter LQ
Checking status of "ImageWriter LQ"... Printer "ImageWriter LQ" is not responding. Skipping...

Any idea where I can get some more details on why it's not liking the ImageWriter LQ? Alas I don't have any other working LocalTalk printers working at present. I'm wondering if it might be the LocalTalk Bridge.. but then.. why would everything else work via it?
 

mactjaap

Well-known member
Hmmm .... so installing 4.2.1 didn't help.

No... I don't know what is going on. Maybe you can make a new post about this subject and aks for help? I'm not that much into printing and Netatalk. It is just a side thing on the MacIPRpi.
 

Durosity

Well-known member
Yeah good idea. Thanks for all your help this evening with the rest of it! And serious thanks for putting this package together.. it's exactly what I wanted and mixed with my piSCSI install I've now been able to setup my 7100/80 with the pi inside it to act as a bridge between the old world and the new, and it's working almost perfectly!
 

NJRoadfan

Well-known member
Can you post the contents of the check-maciprpi.sh script? Its likely assuming the printer is a LaserWriter.
 

Fizzbinn

Well-known member
Can you post the contents of the check-maciprpi.sh script? Its likely assuming the printer is a LaserWriter.

I think this is the relevant section:

It looks like it is trying to send a postscript job to the Imagewriter. Could likely be working (not that I know how you'd test!)

Code:
# Function: Print Page (Send Real Print Job)
print_page() {
    echo -e "${BRIGHT_CYAN}Sending Test Print to Available Printers${RESET}"

    echo "Searching for available AppleTalk printers..."
    printers=$(nbplkup | awk -F: '/LaserWriter|ImageWriter|Printer/{print $1}' | sed 's/^ *//;s/ *$//')

    if [ -z "$printers" ]; then
        echo -e "${BRIGHT_CYAN}No AppleTalk printers found.${RESET}"
        return
    fi

    echo "Found AppleTalk printers:"
    echo -e " ${GREEN} $printers ${RESET}"

    # Loop through each printer
    while IFS= read -r printer; do
        echo -n "Checking status of \"$printer\"... "
        if papstatus -p "$printer" &>/dev/null; then
            echo -e "${GREEN}Available!!!${RESET}"
            echo "Sending enhanced PostScript test print to \"$printer\"..."

            pap -p "$printer" <<EOF
%!PS-Adobe-3.0
%%Title: Netatalk Test Print
%%Creator: test_papd.sh
%%Pages: 1
%%BoundingBox: 0 0 612 792
%%EndComments

/Courier findfont 20 scalefont setfont
100 700 moveto
(Netatalk Test Print from $(hostname)) show

showpage
%%EOF
`echo -e '\004'`
EOF

            if [ $? -eq 0 ]; then
                echo -e "${GREEN}Print job sent successfully.${RESET}"
            else
                echo -e "${RED}Failed to send print job.${RESET}"
            fi
        else
            echo -e "${RED}Printer \"$printer\" is not responding. Skipping...${RESET}"
        fi
    done <<< "$printers"  # <<< "$printers" is needed to correctly read the list

    echo "Sleep for $SLEEP seconds....."
    sleep $SLEEP

}  # Closing the function properly

@Durosity Try running papstatus -p "ImageWriter LQ", this is what that command outputs for my LaserWriter, perhaps the ImageWriter LocalTalk card replies likewise and you would know that at least AppleTalk connectivity is working.

Code:
macipgw@maciprpi6:/etc/rpimonitor/template $ papstatus -p "4/600 PS"
status: idle

...or looking closer at the code that papstatus check might be what is failing because you would be seeing "Available!!!" in the output if it was getting past that step in the check.
 
Last edited:

NJRoadfan

Well-known member
The ImageWriter doesn't reply back as a plaintext papstatus response. It outputs 2 bytes, and the various bits need to be decoded to get the current status. The current versions of papstatus now decode this, but the output might not be what this script is expecting. Sending PostScript to an ImageWriter is obviously not going to work.
 

mactjaap

Well-known member
Thanks @NJRoadfan and @Fizzbinn for your help. Printing is rather new for me, so I have to learn too. I will add a disclaimer that the current test setup on;y supports LaserPrinter. I do not have a ImageWriter so testing is not possible for me.
Added to the comments at the download page:

Disclaimer: Printing a real page will only work on Laser printers. And also no guaranty because I have only one to test.....
 
Last edited:

Durosity

Well-known member
Ah so I have hooked up my laserwriter via LocalTalk and it does read that.. so yeah.. there we go, it just doesn’t work with ImageWriters! Shame.. was quite excited at the idea of printing to a dotmatrix from my iPhone.. something about the convergence of technology 😅
 

mactjaap

Well-known member
Yes. I agree. I love things like that too.
That kind of thinking made me develop the MacIPRpi. So you can actually grab files with your iPhone and sync them to your old Mac, telnet to the internet, that kind of stuff. So use it as a kind of Swiss army knife for our old devices.
Feel free to use it as a starting point and experiment with it. If you find out more about printing to matrix printers…. Just let me know. Maybe I can add it to future versions!
 

mactjaap

Well-known member
To enable the Ethernet port stats in the RPi Monitor homepage and statistics edit this file:

Code:
sudo pico /etc/rpimonitor/template/network.conf

Uncomment the config (remove the leading "#") from these lines:

.......................

Nice update. I will adjust the configuration.

Tested it and works nice! Will be in future releases. Thanks again for the tip.
 

Fizzbinn

Well-known member
To enable the Ethernet port stats in the RPi Monitor homepage and statistics edit this file:

Code:
sudo pico /etc/rpimonitor/template/network.conf

Uncomment the config (remove the leading "#") from these lines:

.......................



Tested it and works nice! Will be in future releases. Thanks again for the tip.

You're welcome. I have two more for you though :)

It was bugging me that under the Version section Processor showed "undefined", I googled around it appears that Bookworm broke the way this was being queried under Buster. I found a different command that works on both.

/etc/rpimonitor/template/version.conf
Code:
#static.4.source=/proc/cpuinfo
#static.4.regexp=(?:Processor|model name|Hardware)\s+: (.*)
static.4.source=/proc/device-tree/compatible
static.4.regexp=(.*)

Also under the SD Card section the /boot partition wasn't showing data. Turns out another change in Bookworm, it's now /boot/firmware.

/etc/rpimonitor/template/sdcard.conf
Code:
#static.8.source=df /boot
#static.8.regexp=\S+\s+(\d+).*\/boot$
static.8.source=df /boot/firmware
static.8.regexp=\S+\s+(\d+).*\/boot/firmware$

#dynamic.7.source=df /boot
#dynamic.7.regexp=\S+\s+\d+\s+(\d+).*\/boot$
dynamic.7.source=df /boot/firmware
dynamic.7.regexp=\S+\s+\d+\s+(\d+).*\/boot/firmware$

#web.status.1.content.7.line.1="<b>/boot</b> Used: <b>"+KMG(data.sdcard_boot_used,'M')+"</b> (<b>"+Percent(data.sdcard_boot_used,data.sdcard_boot_total,'M')+"</b>) Free: <b>"+KMG(data.sdcard_boot_total-data.sdcard_boot_used,'M')+ "</b> Total: <b>"+ KMG(data.sdcard_boot_total,'M') +"</b>"
web.status.1.content.7.line.1="<b>/boot/firmware/</b> Used: <b>"+KMG(data.sdcard_boot_used,'M')+"</b> (<b>"+Percent(data.sdcard_boot_used,data.sdcard_boot_total,'M')+"</b>) Free: <b>"+KMG(data.sdcard_boot_total-data.sdcard_boot_used,'M')+ "</b> Total: <b>"+ KMG(data.sdcard_boot_total,'M') +"</b>"
 
Last edited:
Top