Can I use a symlink instead of ttyUSB0?
Clash Royale CLAN TAG#URR8PPP
up vote
0
down vote
favorite
I have a script that connects my raspberry to the internet using a 4G USB module. I call wvdial in /etc/rc.local and it connects.
It works well when my USB dongle mounts in ttyUSB0, but it randomly mounts in ttyUSB1, ttyUSB2... and fails to connect when this happens.
It makes sense because in my wvdial.conf file I have:
[Dialer Defaults]
Modem = /dev/ttyUSB0
To solve it, I created a symlink so the module mounts in /dev/huaweimodule and modified the previous file:
[Dialer Defaults]
Modem = /dev/huaweimodem
But now, sudo wvdial gives:
Cannot open /dev/huaweimodem: Inappropriate ioctl for device
How can I use a symlink instead of ttyUSB0 in wvdial.conf, or force my modem to always mount in ttyUSB0?
usb raspbian modem wvdial rc.local
add a comment |Â
up vote
0
down vote
favorite
I have a script that connects my raspberry to the internet using a 4G USB module. I call wvdial in /etc/rc.local and it connects.
It works well when my USB dongle mounts in ttyUSB0, but it randomly mounts in ttyUSB1, ttyUSB2... and fails to connect when this happens.
It makes sense because in my wvdial.conf file I have:
[Dialer Defaults]
Modem = /dev/ttyUSB0
To solve it, I created a symlink so the module mounts in /dev/huaweimodule and modified the previous file:
[Dialer Defaults]
Modem = /dev/huaweimodem
But now, sudo wvdial gives:
Cannot open /dev/huaweimodem: Inappropriate ioctl for device
How can I use a symlink instead of ttyUSB0 in wvdial.conf, or force my modem to always mount in ttyUSB0?
usb raspbian modem wvdial rc.local
Who makes your symlinks? I'm using symlinks made by UDEV without problems. Have a look at: hintshop.ludvig.co.nz/show/persistent-names-usb-serial-devices
â yeti
Sep 27 at 14:58
UDEV, that link is the reference I followed to create the symlink. So are you using a symlink in wvdial.conf without any problem?
â Daniel Viaño
Sep 27 at 15:02
A related question is unix.stackexchange.com/questions/270179 .
â JdeBP
Sep 27 at 16:25
The symlink is created correctly? No spelling mistakes anywhere ("module" vs. "modem" etc.)?
â dirkt
Sep 27 at 17:09
Yes, the symlink is created correctly. However, I noticed it is pointing to ttyUSB2 when correct connection happens with ttyUSB0 for example. It's like the modem is mounting in several points at once.
â Daniel Viaño
Sep 28 at 6:49
add a comment |Â
up vote
0
down vote
favorite
up vote
0
down vote
favorite
I have a script that connects my raspberry to the internet using a 4G USB module. I call wvdial in /etc/rc.local and it connects.
It works well when my USB dongle mounts in ttyUSB0, but it randomly mounts in ttyUSB1, ttyUSB2... and fails to connect when this happens.
It makes sense because in my wvdial.conf file I have:
[Dialer Defaults]
Modem = /dev/ttyUSB0
To solve it, I created a symlink so the module mounts in /dev/huaweimodule and modified the previous file:
[Dialer Defaults]
Modem = /dev/huaweimodem
But now, sudo wvdial gives:
Cannot open /dev/huaweimodem: Inappropriate ioctl for device
How can I use a symlink instead of ttyUSB0 in wvdial.conf, or force my modem to always mount in ttyUSB0?
usb raspbian modem wvdial rc.local
I have a script that connects my raspberry to the internet using a 4G USB module. I call wvdial in /etc/rc.local and it connects.
It works well when my USB dongle mounts in ttyUSB0, but it randomly mounts in ttyUSB1, ttyUSB2... and fails to connect when this happens.
It makes sense because in my wvdial.conf file I have:
[Dialer Defaults]
Modem = /dev/ttyUSB0
To solve it, I created a symlink so the module mounts in /dev/huaweimodule and modified the previous file:
[Dialer Defaults]
Modem = /dev/huaweimodem
But now, sudo wvdial gives:
Cannot open /dev/huaweimodem: Inappropriate ioctl for device
How can I use a symlink instead of ttyUSB0 in wvdial.conf, or force my modem to always mount in ttyUSB0?
usb raspbian modem wvdial rc.local
usb raspbian modem wvdial rc.local
asked Sep 27 at 14:53
Daniel Viaño
1
1
Who makes your symlinks? I'm using symlinks made by UDEV without problems. Have a look at: hintshop.ludvig.co.nz/show/persistent-names-usb-serial-devices
â yeti
Sep 27 at 14:58
UDEV, that link is the reference I followed to create the symlink. So are you using a symlink in wvdial.conf without any problem?
â Daniel Viaño
Sep 27 at 15:02
A related question is unix.stackexchange.com/questions/270179 .
â JdeBP
Sep 27 at 16:25
The symlink is created correctly? No spelling mistakes anywhere ("module" vs. "modem" etc.)?
â dirkt
Sep 27 at 17:09
Yes, the symlink is created correctly. However, I noticed it is pointing to ttyUSB2 when correct connection happens with ttyUSB0 for example. It's like the modem is mounting in several points at once.
â Daniel Viaño
Sep 28 at 6:49
add a comment |Â
Who makes your symlinks? I'm using symlinks made by UDEV without problems. Have a look at: hintshop.ludvig.co.nz/show/persistent-names-usb-serial-devices
â yeti
Sep 27 at 14:58
UDEV, that link is the reference I followed to create the symlink. So are you using a symlink in wvdial.conf without any problem?
â Daniel Viaño
Sep 27 at 15:02
A related question is unix.stackexchange.com/questions/270179 .
â JdeBP
Sep 27 at 16:25
The symlink is created correctly? No spelling mistakes anywhere ("module" vs. "modem" etc.)?
â dirkt
Sep 27 at 17:09
Yes, the symlink is created correctly. However, I noticed it is pointing to ttyUSB2 when correct connection happens with ttyUSB0 for example. It's like the modem is mounting in several points at once.
â Daniel Viaño
Sep 28 at 6:49
Who makes your symlinks? I'm using symlinks made by UDEV without problems. Have a look at: hintshop.ludvig.co.nz/show/persistent-names-usb-serial-devices
â yeti
Sep 27 at 14:58
Who makes your symlinks? I'm using symlinks made by UDEV without problems. Have a look at: hintshop.ludvig.co.nz/show/persistent-names-usb-serial-devices
â yeti
Sep 27 at 14:58
UDEV, that link is the reference I followed to create the symlink. So are you using a symlink in wvdial.conf without any problem?
â Daniel Viaño
Sep 27 at 15:02
UDEV, that link is the reference I followed to create the symlink. So are you using a symlink in wvdial.conf without any problem?
â Daniel Viaño
Sep 27 at 15:02
A related question is unix.stackexchange.com/questions/270179 .
â JdeBP
Sep 27 at 16:25
A related question is unix.stackexchange.com/questions/270179 .
â JdeBP
Sep 27 at 16:25
The symlink is created correctly? No spelling mistakes anywhere ("module" vs. "modem" etc.)?
â dirkt
Sep 27 at 17:09
The symlink is created correctly? No spelling mistakes anywhere ("module" vs. "modem" etc.)?
â dirkt
Sep 27 at 17:09
Yes, the symlink is created correctly. However, I noticed it is pointing to ttyUSB2 when correct connection happens with ttyUSB0 for example. It's like the modem is mounting in several points at once.
â Daniel Viaño
Sep 28 at 6:49
Yes, the symlink is created correctly. However, I noticed it is pointing to ttyUSB2 when correct connection happens with ttyUSB0 for example. It's like the modem is mounting in several points at once.
â Daniel Viaño
Sep 28 at 6:49
add a comment |Â
active
oldest
votes
active
oldest
votes
active
oldest
votes
active
oldest
votes
active
oldest
votes
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f471848%2fcan-i-use-a-symlink-instead-of-ttyusb0%23new-answer', 'question_page');
);
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Who makes your symlinks? I'm using symlinks made by UDEV without problems. Have a look at: hintshop.ludvig.co.nz/show/persistent-names-usb-serial-devices
â yeti
Sep 27 at 14:58
UDEV, that link is the reference I followed to create the symlink. So are you using a symlink in wvdial.conf without any problem?
â Daniel Viaño
Sep 27 at 15:02
A related question is unix.stackexchange.com/questions/270179 .
â JdeBP
Sep 27 at 16:25
The symlink is created correctly? No spelling mistakes anywhere ("module" vs. "modem" etc.)?
â dirkt
Sep 27 at 17:09
Yes, the symlink is created correctly. However, I noticed it is pointing to ttyUSB2 when correct connection happens with ttyUSB0 for example. It's like the modem is mounting in several points at once.
â Daniel Viaño
Sep 28 at 6:49