Bug 517470
| Summary: | wvdial pppd not updating /etc/resolv.conf when invoked on USB modem | ||
|---|---|---|---|
| Product: | [Fedora] Fedora | Reporter: | Richard Chan <rc556677> |
| Component: | ppp | Assignee: | Jiri Skala <jskala> |
| Status: | CLOSED NOTABUG | QA Contact: | Fedora Extras Quality Assurance <extras-qa> |
| Severity: | medium | Docs Contact: | |
| Priority: | low | ||
| Version: | 11 | CC: | aglotov, jskala, linville |
| Target Milestone: | --- | ||
| Target Release: | --- | ||
| Hardware: | All | ||
| OS: | Linux | ||
| Whiteboard: | |||
| Fixed In Version: | Doc Type: | Bug Fix | |
| Doc Text: | Story Points: | --- | |
| Clone Of: | Environment: | ||
| Last Closed: | 2009-11-26 20:22:59 UTC | Type: | --- |
| Regression: | --- | Mount Type: | --- |
| Documentation: | --- | CRM: | |
| Verified Versions: | Category: | --- | |
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
| Cloudforms Team: | --- | Target Upstream Version: | |
| Embargoed: | |||
| Bug Depends On: | |||
| Bug Blocks: | 517294 | ||
|
Description
Richard Chan
2009-08-14 08:44:09 UTC
I tested it with Nokia and it works for me but ...: # pppd call <script> (script in /etc/ppp/peers/<script>) Script have to contain 'usepeerdns' option The /etc/ppp/ip-up should call /etc/ppp/ip-up.local My ip-up.local (copied from /usr/share/doc/ppp-2.4.4/scripts/ip-up.local.add and modified): if [ -n "$USEPEERDNS" -a -f /var/run/ppp/resolv.conf ]; then rm -f /var/run/ppp/resolv.prev if [ -f /etc/resolv.conf ]; then cp /etc/resolv.conf /var/run/ppp/resolv.prev rscf=/var/run/ppp/resolv.new cp /var/run/ppp/resolv.conf $rscf grep domain /var/run/ppp/resolv.prev >> $rscf grep search /var/run/ppp/resolv.prev >> $rscf grep nameserver /var/run/ppp/resolv.prev >> $rscf change_resolv_conf $rscf rm -f $rscf else change_resolv_conf /var/run/ppp/resolv.conf fi fi The resolv.conf is updated. The example of ip-up.local is quick test. This is not a dogma. :-) Jiri (In reply to comment #0) > Additional info: > /etc/ppp/ip-up called with 5 args > ppp0 /dev/ttyACM0 460800 119.234.145.157 10.6.6.6 > Note: 5 arguments ONLY, so /etc/sysconfig/network-scripts/ifup-post is NOT > invoked, so no /etc/resolv.conf updating. > /etc/ppp/ip-up expects 6 arguments, and looks for the file > /etc/sysconfig/network-scripts/ifcfg-XXXX (if the 6th argument is XXXX) > > If I 'trick' the script by creating a dummy file > /etc/sysconfig/network-scripts/ifcfg- containing > PEERDNS=yes > DEFROUTE=yes > > /etc/ppp/ip-up sees the existence of this file and then does invoke > .../ifup-post. You can define the sixth parameter of ip-up via option ipparam <your_definition> usepeerdns is mandatory option to generate resolv.conf in /etc... that is used by script ip-up.local to update resolv.conf. An example of ip-up.local is in /etc/share/doc/ppp-2.4.?/scripts Or use NetworkManager - it works fine with updating resolv.conf |