Beta support: MMS on chatty/mmsd on Modem Manager - help/testing wanted!
#51
So after talking with the Purism folks, I will say that the mmsd plugin is almost complete. There are two outstanding issues I see so far:

- if mmsd is configured with the wrong settings, you have to restart it for the correct settings to take affect.
- While a domain name works as a proxy, an IP address does not.

I got an offer devrtz (Thank you!) to package mmsd for Debian, so it will work for Mobian and PureOS. I am also seeing what I need to do to upstream the changes.
  Reply
#52
Ok, so I cleaned up mmsd to support all of the features I think it needs for now. As of now, there are still two outstanding issues:

- if mmsd is configured with the wrong settings, you have to restart it for the correct settings to take affect.
  • The issue is....strange. As far as I can tell, I am doing everything right for it to work, but my MMSC gives be a 503 error if I reconfigure the settings and attempt to use it. The error is immediately gone if I reset mmsd. If anyone has ideas, I would appreciate it. However, since the settings do not change very often and a reset makes it work, I am relatively unconcerned with this problem.
- While a domain name works as a proxy, an IP address does not. 
  • I unfortunately do not have a carrier that uses a proxy, so I cannot work on this issue.
I also cleaned up the README and the documentation so that folks can build upon it!

But overall, I think mmsd is in really good shape! I would appreciate help in battle testing it now. I updated the readme for how to properly install it, and I need to look into how to get systemd to configure it now (since I am on Mobian. If you are on a different distro, feel free to submit how to get it working there)!
  Reply
#53
So if anyone has experience with systemd, help would be appreciated.

I am making a systemd serve with:

Code:
[Unit]
Description=Multimedia Message Service Daemon

Wants=network.target
After=syslog.target network-online.target

[Service]
Type=simple
ExecStart=/usr/libexec/mmsd
Restart=always
RestartSec=10
User=root
KillMode=process

[Install]
WantedBy=multi-user.target

and I put it here: /etc/systemd/system/mmsd.service (it is owned by root, and has permissions of 640)

I attempt to enable it and start it with:

Code:
sudo systemctl enable mmsd
sudo systemctl daemon-reload
sudo systemctl start mmsd

But mmsd imediately stops.

When installing the normal way. I can manually start it with:

Code:
$/usr/libexec/mmsd
and it runs as I expect it to.
  Reply
#54
(01-12-2021, 12:03 PM)kop316 Wrote: So if anyone has experience with systemd, help would be appreciated.

I am making a systemd serve with:

Code:
[Unit]
Description=Multimedia Message Service Daemon

Wants=network.target
After=syslog.target network-online.target

[Service]
Type=simple
ExecStart=/usr/libexec/mmsd
Restart=always
RestartSec=10
User=root
KillMode=process

[Install]
WantedBy=multi-user.target

and I put it here: /etc/systemd/system/mmsd.service (it is owned by root, and has permissions of 640)

I attempt to enable it and start it with:

Code:
sudo systemctl enable mmsd
sudo systemctl daemon-reload
sudo systemctl start mmsd

But mmsd imediately stops.

When installing the normal way. I can manually start it with:

Code:
$/usr/libexec/mmsd
and it runs as I expect it to.


I'm by no means an expert, but wouldn't you want permissions to be 740? So that root has the ability to execute the service as well?
  Reply
#55
(01-12-2021, 12:52 PM)cody Wrote:
(01-12-2021, 12:03 PM)kop316 Wrote: So if anyone has experience with systemd, help would be appreciated.

I am making a systemd serve with:

Code:
[Unit]
Description=Multimedia Message Service Daemon

Wants=network.target
After=syslog.target network-online.target

[Service]
Type=simple
ExecStart=/usr/libexec/mmsd
Restart=always
RestartSec=10
User=root
KillMode=process

[Install]
WantedBy=multi-user.target

and I put it here: /etc/systemd/system/mmsd.service (it is owned by root, and has permissions of 640)

I attempt to enable it and start it with:

Code:
sudo systemctl enable mmsd
sudo systemctl daemon-reload
sudo systemctl start mmsd

But mmsd imediately stops.

When installing the normal way. I can manually start it with:

Code:
$/usr/libexec/mmsd
and it runs as I expect it to.


I'm by no means an expert, but wouldn't you want permissions to be 740? So that root has the ability to execute the service as well?

I apoligize,I am not sure where you are referring to. I just did a fresh install of mmsd and I get this:

Code:
mobian@mobian:/usr/libexec$ ls -l | grep mmsd
-rwxr-xr-x 1 root root  967936 Jan 12 15:15 mmsd

So it has permissions that I would expect.
  Reply
#56
(01-12-2021, 02:16 PM)kop316 Wrote:
(01-12-2021, 12:52 PM)cody Wrote:
(01-12-2021, 12:03 PM)kop316 Wrote: So if anyone has experience with systemd, help would be appreciated.

I am making a systemd serve with:

Code:
[Unit]
Description=Multimedia Message Service Daemon

Wants=network.target
After=syslog.target network-online.target

[Service]
Type=simple
ExecStart=/usr/libexec/mmsd
Restart=always
RestartSec=10
User=root
KillMode=process

[Install]
WantedBy=multi-user.target

and I put it here: /etc/systemd/system/mmsd.service (it is owned by root, and has permissions of 640)

Code:
mobian@mobian:/usr/libexec$ ls -l | grep mmsd
-rwxr-xr-x 1 root root  967936 Jan 12 15:15 mmsd

So it has permissions that I would expect.

I'm just wondering if the mmsd.service needs to have a user bit of 7 for read, write, and execute?
  Reply
#57
Trying to build this on latest dev of Manjaro phosh. I have it built and compiled and it is working, in the ModemManagerSettings I have the following but am not sure what MMS_APN should be.

[Modem Manager]
CarrierMMSC=http://mmsc.mobile.att.net
MMS_APN=NXTGENPHONE
CarrierMMSProxy=proxy.mobile.att.net:80


The service does start but I get an error which I think is caused by not having the correct MMS_APN, which I cannot seem to find for AT&T. I have never messed with cellular so I am unsure of the data for these config files and where to find them. I am not a developer just a regular user trying to see if I can get a picture to my PinePhone.

[manjaro@manjaro-arm mmsd-ModemManager]$ ./src/mmsd -n -d 'src/*'
mmsd[4979]: MMS daemon version 0.0
mmsd[4979]: src/service.c:__mms_service_init()
mmsd[4979]: src/plugin.c:__mms_plugin_init()
mmsd[4979]: src/plugin.c:add_plugin() Plugin ofono loaded
mmsd[4979]: src/service.c:mms_service_create() service 0xaaab01c97630
mmsd[4979]: src/service.c:mms_service_set_identity() service 0xaaab01c97630 identity modemmanager
mmsd[4979]: src/plugin.c:add_plugin() Plugin modemmanager loaded
mmsd[4979]: ModemManagerPlugin(): ModemManager found: :1.9
mmsd[4979]: src/service.c:mms_service_register() service 0xaaab01c97630
mmsd[4979]: src/service.c:emit_service_added() service 0xaaab01c97630
mmsd[4979]: src/service.c:mms_service_set_bearer_handler() service 0xaaab01c97630 handler 0xaaaae184b750
mmsd[4979]: src/service.c:mms_service_set_mmsc() service 0xaaab01c97630 mmsc http://mmsc.mobile.att.net
mmsd[4979]: ModemManagerPlugin(): There are no modem bearers! Please enable modem data
mmsd[4979]: ModemManagerPlugin(): Set MMSC: http://mmsc.mobile.att.net, Set Proxy: proxy.mobile.att.net:80, Set MMS APN: NXTGENPHONE
mmsd[4979]: ModemManagerPlugin(): Error activating context!
mmsd[4979]: src/service.c:mms_service_bearer_notify() service=0xaaab01c97630 active=0 iface=(null) proxy=(null)


Thanks for any help and sorry if these are basic questions and I should know the answers,

Jon
  Reply
#58
(01-12-2021, 03:06 PM)cody Wrote:
(01-12-2021, 02:16 PM)kop316 Wrote:
(01-12-2021, 12:52 PM)cody Wrote:
(01-12-2021, 12:03 PM)kop316 Wrote: So if anyone has experience with systemd, help would be appreciated.

I am making a systemd serve with:

Code:
[Unit]
Description=Multimedia Message Service Daemon

Wants=network.target
After=syslog.target network-online.target

[Service]
Type=simple
ExecStart=/usr/libexec/mmsd
Restart=always
RestartSec=10
User=root
KillMode=process

[Install]
WantedBy=multi-user.target

and I put it here: /etc/systemd/system/mmsd.service (it is owned by root, and has permissions of 640)

Code:
mobian@mobian:/usr/libexec$ ls -l | grep mmsd
-rwxr-xr-x 1 root root  967936 Jan 12 15:15 mmsd

So it has permissions that I would expect.

I'm just wondering if the mmsd.service needs to have a user bit of 7 for read, write, and execute?
I can check but I am not so sure....

Looking in my /etc/systemd/system folder, there are a few .service files that do not have execute permissions.

I should have noted too that I do get the service loaded, but it is always "inactive" with an exit code of "0 (success)". So mmsd seems to load then immediately exit for some reason.
  Reply
#59
(01-12-2021, 04:15 PM)Rey Wrote: Trying to build this on latest dev of Manjaro phosh. I have it built and compiled and it is working, in the ModemManagerSettings I have the following but am not sure what MMS_APN should be.

[Modem Manager]
CarrierMMSC=http://mmsc.mobile.att.net
MMS_APN=NXTGENPHONE
CarrierMMSProxy=proxy.mobile.att.net:80


The service does start but I get an error which I think is caused by not having the correct MMS_APN, which I cannot seem to find for AT&T. I have never messed with cellular so I am unsure of the data for these config files and where to find them. I am not a developer just a regular user trying to see if I can get a picture to my PinePhone.

[manjaro@manjaro-arm mmsd-ModemManager]$ ./src/mmsd -n -d 'src/*'
mmsd[4979]: MMS daemon version 0.0
mmsd[4979]: src/service.c:__mms_service_init()
mmsd[4979]: src/plugin.c:__mms_plugin_init()
mmsd[4979]: src/plugin.c:add_plugin() Plugin ofono loaded
mmsd[4979]: src/service.c:mms_service_create() service 0xaaab01c97630
mmsd[4979]: src/service.c:mms_service_set_identity() service 0xaaab01c97630 identity modemmanager
mmsd[4979]: src/plugin.c:add_plugin() Plugin modemmanager loaded
mmsd[4979]: ModemManagerPlugin(): ModemManager found: :1.9
mmsd[4979]: src/service.c:mms_service_register() service 0xaaab01c97630
mmsd[4979]: src/service.c:emit_service_added() service 0xaaab01c97630
mmsd[4979]: src/service.c:mms_service_set_bearer_handler() service 0xaaab01c97630 handler 0xaaaae184b750
mmsd[4979]: src/service.c:mms_service_set_mmsc() service 0xaaab01c97630 mmsc http://mmsc.mobile.att.net
mmsd[4979]: ModemManagerPlugin(): There are no modem bearers! Please enable modem data
mmsd[4979]: ModemManagerPlugin(): Set MMSC: http://mmsc.mobile.att.net, Set Proxy: proxy.mobile.att.net:80, Set MMS APN: NXTGENPHONE
mmsd[4979]: ModemManagerPlugin(): Error activating context!
mmsd[4979]: src/service.c:mms_service_bearer_notify() service=0xaaab01c97630 active=0 iface=(null) proxy=(null)


Thanks for any help and sorry if these are basic questions and I should know the answers,

Jon
Hello Jon!

Can you first confirm you have mobile data? Based on the error, mmsd cannot seem to find an active mobile internet connection.

IIRC, AT&T uses the same APN for MMS as they do for mobile data, so you should be able to copy whatever your phone's settings are. If you look in your phone's mobile settings, can you look up the APN in there and copy it to the mmsd settings?
  Reply
#60
(01-12-2021, 06:10 PM)kop316 Wrote:
(01-12-2021, 04:15 PM)Rey Wrote: Trying to build this on latest dev of Manjaro phosh. I have it built and compiled and it is working, in the ModemManagerSettings I have the following but am not sure what MMS_APN should be.

[Modem Manager]
CarrierMMSC=http://mmsc.mobile.att.net
MMS_APN=NXTGENPHONE
CarrierMMSProxy=proxy.mobile.att.net:80


The service does start but I get an error which I think is caused by not having the correct MMS_APN, which I cannot seem to find for AT&T. I have never messed with cellular so I am unsure of the data for these config files and where to find them. I am not a developer just a regular user trying to see if I can get a picture to my PinePhone.

[manjaro@manjaro-arm mmsd-ModemManager]$ ./src/mmsd -n -d 'src/*'
mmsd[4979]: MMS daemon version 0.0
mmsd[4979]: src/service.c:__mms_service_init()
mmsd[4979]: src/plugin.c:__mms_plugin_init()
mmsd[4979]: src/plugin.c:add_plugin() Plugin ofono loaded
mmsd[4979]: src/service.c:mms_service_create() service 0xaaab01c97630
mmsd[4979]: src/service.c:mms_service_set_identity() service 0xaaab01c97630 identity modemmanager
mmsd[4979]: src/plugin.c:add_plugin() Plugin modemmanager loaded
mmsd[4979]: ModemManagerPlugin(): ModemManager found: :1.9
mmsd[4979]: src/service.c:mms_service_register() service 0xaaab01c97630
mmsd[4979]: src/service.c:emit_service_added() service 0xaaab01c97630
mmsd[4979]: src/service.c:mms_service_set_bearer_handler() service 0xaaab01c97630 handler 0xaaaae184b750
mmsd[4979]: src/service.c:mms_service_set_mmsc() service 0xaaab01c97630 mmsc http://mmsc.mobile.att.net
mmsd[4979]: ModemManagerPlugin(): There are no modem bearers! Please enable modem data
mmsd[4979]: ModemManagerPlugin(): Set MMSC: http://mmsc.mobile.att.net, Set Proxy: proxy.mobile.att.net:80, Set MMS APN: NXTGENPHONE
mmsd[4979]: ModemManagerPlugin(): Error activating context!
mmsd[4979]: src/service.c:mms_service_bearer_notify() service=0xaaab01c97630 active=0 iface=(null) proxy=(null)


Thanks for any help and sorry if these are basic questions and I should know the answers,

Jon
Hello Jon!

Can you first confirm you have mobile data? Based on the error, mmsd cannot seem to find an active mobile internet connection.

IIRC, AT&T uses the same APN for MMS as they do for mobile data, so you should be able to copy whatever your phone's settings are. If you look in your phone's mobile settings, can you look up the APN in there and copy it to the mmsd settings?

Progress!! I can send a MMS to my phone and I see it arrive via, mmcli -m 0 --messaging-list-sms. I deleted all of the messages in the queue to ensure that nothing was hung, I then started mmsd as the manjaro user, which is the default user. Should I be starting it as root? I then send a message and see it arrive but it does not show up in the chat application. Below is what I now see when I start the mms daemon, as the manjaro user. Look at what I have bolded and tell me if that looks accurate.

[manjaro@manjaro-arm mmsd-ModemManager]$ ./src/mmsd -n -d 'src/*'
mmsd[4977]: MMS daemon version 0.0
mmsd[4977]: src/service.c:__mms_service_init()
mmsd[4977]: src/plugin.c:__mms_plugin_init()
mmsd[4977]: src/plugin.c:add_plugin() Plugin ofono loaded
mmsd[4977]: src/service.c:mms_service_create() service 0xaaaac36b55d0
mmsd[4977]: src/service.c:mms_service_set_identity() service 0xaaaac36b55d0 identity modemmanager
mmsd[4977]: src/plugin.c:add_plugin() Plugin modemmanager loaded
mmsd[4977]: ModemManagerPlugin(): ModemManager found: :1.9
mmsd[4977]: src/service.c:mms_service_register() service 0xaaaac36b55d0
mmsd[4977]: src/service.c:emit_service_added() service 0xaaaac36b55d0
mmsd[4977]: src/service.c:mms_service_set_bearer_handler() service 0xaaaac36b55d0 handler 0xaaaabf27b750
mmsd[4977]: src/service.c:mms_service_set_mmsc() service 0xaaaac36b55d0 mmsc http://mmsc.mobile.att.net
mmsd[4977]: src/service.c:mms_service_bearer_notify() service=0xaaaac36b55d0 active=1 iface=wwan0 proxy=proxy.mobile.att.net:80
mmsd[4977]: src/service.c:mms_service_bearer_notify() interface wwan0 proxy proxy.mobile.att.net:80
setting proxy proxy.mobile.att.net:80
mmsd[4977]: src/service.c:process_request_queue() service 0xaaaac36b55d0
mmsd[4977]: src/service.c:bearer_idle_timeout() service 0xaaaac36b55d0
mmsd[4977]: src/service.c:deactivate_bearer() service 0xaaaac36b55d0
mmsd[4977]: src/service.c:deactivate_bearer() service 0xaaaac36b55d0
mmsd[4977]: src/service.c:mms_service_set_mmsc() service 0xaaaac36b55d0 mmsc http://mmsc.mobile.att.net
mmsd[4977]: src/service.c:mms_service_bearer_notify() service=0xaaaac36b55d0 active=0 iface=wwan0 proxy=proxy.mobile.att.net:80
  Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  What File Manager Options Are There For The Pinephone? pinephoneuser22 7 3,824 10-18-2023, 08:37 AM
Last Post: luppivega
  A/B testing or Unit testing gulshan212 0 1,234 08-29-2023, 03:36 AM
Last Post: gulshan212
  Article: NuttX RTOS for PinePhone: 4G LTE Modem lupyuen 2 2,077 04-10-2023, 10:19 PM
Last Post: lupyuen
  changing from bullseye to bookworm to install mmsd-tng jyoung 8 4,210 04-09-2023, 06:08 PM
Last Post: zetabeta
Sad Modem is always visible/connected but stops working after a while dante404 6 4,077 11-08-2022, 09:12 AM
Last Post: dante404
  Downsides of the open-source modem firmware? alpineduck 4 3,374 10-25-2022, 05:28 PM
Last Post: Zebulon Walton
  Pinephone: OpenGL support? orbital 2 2,759 08-25-2022, 04:09 PM
Last Post: vortex
  Latest firmware for PinePhone modem! Subsentient 104 148,612 07-20-2022, 05:32 AM
Last Post: zetabeta
  Which PP OS currently has the best podcast support? kujo_marble 3 2,679 07-14-2022, 07:09 AM
Last Post: tophneal
  Help wanted: location of calls and chatty data files dukla2000 3 5,331 06-13-2022, 02:01 PM
Last Post: israel

Forum Jump:


Users browsing this thread: 2 Guest(s)