Page MenuHomeSolus

config files in usb_modeswitch.d folder don't apply
Closed, ResolvedPublic

Description

Hi

When I put my 3G modem config file in usb_modeswitch.d folder, nothing happens. I use same method and file in other distros like Arch, Ubuntu, Fedora and all work perfectly.
my config file name is : 2001:a80b
my config file content is :

D-Link DWM-156 (Variant)

DefaultVendor= 0x2001
DefaultProduct= 0xa80b

TargetVendor= 0x2001
TargetProduct= 0x7d00

MessageContent="555342431234567800000000000003f0010300000000000000000000000000"

Revisions and Commits

Event Timeline

systemctl status usb_modeswitch@2-2.service
● usb_modeswitch@2-2.service - USB_ModeSwitch_2-2

 Loaded: loaded (/usr/lib/systemd/system/usb_modeswitch@.service; static; vendor preset: enabled)
 Active: failed (Result: exit-code) since Mon 2018-12-24 15:43:12 +0330; 3min 1s ago
Process: 1961 ExecStart=/usr/sbin/usb_modeswitch_dispatcher --switch-mode 2-2 (code=exited, status=203/EXEC)

Main PID: 1961 (code=exited, status=203/EXEC)

Dec 24 15:43:12 XDesktop systemd[1]: Starting USB_ModeSwitch_2-2...
Dec 24 15:43:12 XDesktop systemd[1961]: usb_modeswitch@2-2.service: Failed to execute command: No such file or directory
Dec 24 15:43:12 XDesktop systemd[1961]: usb_modeswitch@2-2.service: Failed at step EXEC spawning /usr/sbin/usb_modeswitch_dispatcher: No such file or directory
Dec 24 15:43:12 XDesktop systemd[1]: usb_modeswitch@2-2.service: Main process exited, code=exited, status=203/EXEC
Dec 24 15:43:12 XDesktop systemd[1]: usb_modeswitch@2-2.service: Failed with result 'exit-code'.
Dec 24 15:43:12 XDesktop systemd[1]: Failed to start USB_ModeSwitch_2-2.

Can you reinstall usb-modeswitch?

sudo eopkg it --reinstall usb-modeswitch

The error mention usb_modeswitch_dispatcher as not found, but the file it provided by the usb-modeswitch package.

$ eopkg sf usb_modeswitch | grep dispatcher
Package usb-modeswitch has file /usr/sbin/usb_modeswitch_dispatcher
Package usb-modeswitch has file /usr/share/man/man1/usb_modeswitch_dispatcher.1

Hi

I did it but the problem didn't solve, I also tested on a virtual machine and the result was the same. usb_modeswitch and usb_modeswitch_dispatcher are exist.
#whereis usb_modeswitch
usb_modeswitch: /usr/sbin/usb_modeswitch /etc/usb_modeswitch.d /etc/usb_modeswitch.conf /usr/share/usb_modeswitch /usr/share/man/man1/usb_modeswitch.1

#whereis usb_modeswitch_dispatcher
usb_modeswitch_dispatcher: /usr/sbin/usb_modeswitch_dispatcher /usr/share/man/man1/usb_modeswitch_dispatcher.1

So I try execute the usb_modeswitch_dispatcher and got error:
#usb_modeswitch_dispatcher
-bash: /usr/sbin/usb_modeswitch_dispatcher: /usr/bin/tclsh: bad interpreter: No such file or directory

Then I installed tcl package and the problem solved.

JoshStrobl added a subscriber: JoshStrobl.

So usb-modeswitch needs tcl as a rundep.

JoshStrobl moved this task from Backlog to Package Fixes on the Software board.