Knetworkmanager connects only as root

Hi.

I’ve my OpenSuse installed both on laptop and PC.

The kNetworkManager works well on the laptop both on user account and root account. It connects to my mobile broadband fine.

The problem appeared on my PC.
When I log into root account - everything seems to be fine, It connects through knetworkmanager - The cellular connection gets activated, I see X and a heart near “Activated”. root account reads my DNS’es from resolv.conf

When I only log into the user account (not as root), the knetworkmanager connects - but as I’ve checked - it seems that it doesn’t use the DNS adresses I’ve entered in resolv.conf (netconfig_dns_policy is set to “”) so I can manually add openDNS to the resolv.conf). It just connects -

I did CHMOD the files resolv.conf and config in sysconfig/network - no luck.

The only way to bypass this is logging to root first - connect there, then switch to user while staying connected… but I think it’s an annoying solution.

logs contain this when connecting from user account:

May 16 10:30:52 jaychyl-1-linux pppd[24965]: Plugin /usr/lib/pppd/2.4.4/nm-pppd-plugin.so loaded.
May 16 10:30:52 jaychyl-1-linux pppd[24965]: pppd 2.4.5 started by root, uid 0
May 16 10:30:52 jaychyl-1-linux pppd[24965]: Using interface ppp0
May 16 10:30:52 jaychyl-1-linux pppd[24965]: Connect: ppp0 <--> /dev/ttyUSB0
May 16 10:30:52 jaychyl-1-linux pppd[24965]: CHAP authentication succeeded
May 16 10:30:52 jaychyl-1-linux pppd[24965]: CHAP authentication succeeded
May 16 10:31:00 jaychyl-1-linux pppd[24965]: Could not determine remote IP address: defaulting to 10.64.64.64
May 16 10:31:00 jaychyl-1-linux pppd[24965]: local  IP address 109.243.18.118
May 16 10:31:00 jaychyl-1-linux pppd[24965]: remote IP address 10.64.64.64
May 16 10:31:00 jaychyl-1-linux pppd[24965]: Script /etc/ppp/ip-up finished (pid 24966), status = 0x0
May 16 10:31:01 jaychyl-1-linux if-up.d/21-dhcpcd-hook-samba: No dhcpcd info nor dhclient leases file found for ppp0.
May 16 10:31:01 jaychyl-1-linux sm-notify[25092]: Already notifying clients; Exiting!
May 16 10:31:07 jaychyl-1-linux pppd[24965]: Terminating on signal 15
May 16 10:31:07 jaychyl-1-linux pppd[24965]: Connect time 0.2 minutes.
May 16 10:31:07 jaychyl-1-linux pppd[24965]: Sent 0 bytes, received 0 bytes.
May 16 10:31:07 jaychyl-1-linux dbus-daemon: Rejected send message, 1 matched rules; type="error", sender=":1.54" (uid=0 pid=5921 comm="/usr/sbin/NetworkManager) interface="(unset)" member="(unset)" error name="org.freedesktop.DBus.Error.UnknownMethod" requested_reply=0 destination=":1.73" (uid=0 pid=24965 comm="/usr/sbin/pppd))
May 16 10:31:07 jaychyl-1-linux dbus-daemon: Rejected send message, 1 matched rules; type="error", sender=":1.54" (uid=0 pid=5921 comm="/usr/sbin/NetworkManager) interface="(unset)" member="(unset)" error name="org.freedesktop.DBus.Error.UnknownMethod" requested_reply=0 destination=":1.73" (uid=0 pid=24965 comm="/usr/sbin/pppd))
May 16 10:31:07 jaychyl-1-linux dbus-daemon: Rejected send message, 1 matched rules; type="error", sender=":1.54" (uid=0 pid=5921 comm="/usr/sbin/NetworkManager) interface="(unset)" member="(unset)" error name="org.freedesktop.DBus.Error.UnknownMethod" requested_reply=0 destination=":1.73" (uid=0 pid=24965 comm="/usr/sbin/pppd))
May 16 10:31:07 jaychyl-1-linux pppd[24965]: Connection terminated.
May 16 10:31:07 jaychyl-1-linux dbus-daemon: Rejected send message, 1 matched rules; type="error", sender=":1.54" (uid=0 pid=5921 comm="/usr/sbin/NetworkManager) interface="(unset)" member="(unset)" error name="org.freedesktop.DBus.Error.UnknownMethod" requested_reply=0 destination=":1.73" (uid=0 pid=24965 comm="/usr/sbin/pppd))
May 16 10:31:07 jaychyl-1-linux pppd[24965]: Script /etc/ppp/ip-down finished (pid 25100), status = 0x0
May 16 10:31:07 jaychyl-1-linux pppd[24965]: Exit.
May 16 10:31:08 jaychyl-1-linux modem-manager: Got failure code 3: No carrier

As user, at the beginning it also created it’s own DNS resolv file…weird

May 16 09:34:57 jaychyl-1-linux dns-resolver: ATTENTION: You have modified /etc/resolv.conf. Leaving it untouched...
May 16 09:34:57 jaychyl-1-linux dns-resolver: You can find my version in /etc/resolv.conf.netconfig
May 16 09:34:57 jaychyl-1-linux ip-up: ATTENTION: You have modified /etc/resolv.conf.  Leaving it untouched...
May 16 09:34:57 jaychyl-1-linux ip-up: You can find my version in /etc/resolv.conf.netconfig ...

eurorage wrote:
> The problem appeared on my PC.When I log into root account

first, i see you are a first time poster here: -=welcome=- to openSUSE
and maybe to Linux…

but, you should never log into KDE/Gnome/XFCE or any other *nix-like
graphical user interface desktop environment as root…

doing so 1) opens you up to several different security problems, 2)
too many too easy ways to damage your system no matter how careful
your actions (example: just browsing in your home directory while
logged into KDE/Gnome/etc as root can lock you out later as yourself
due to permissions damage), 3) and, anyway logging into KDE/etc as
root is never required to do any and all administrative duties…

and, it may be the reason your network manager will not run
correctly from a normal user account!!

so, always log in as yourself, and “become root” by using a root
powered application (like YaST, File Manager Superuser Mode) or using
“su -”, sudo, kdesu, or gnomesu in a terminal to launch whatever tool
is needed (like Kwrite to edit a config file)…read more on all that
here:

http://en.opensuse.org/SDB:Login_as_root
http://docs.kde.org/stable/en/kdebase-runtime/userguide/root.html
http://tinyurl.com/6ry6yd
http://tinyurl.com/ydbwssh


DenverD (Linux Counter 282315)
CAVEAT: http://is.gd/bpoMD
posted via NNTP w/TBird 2.0.0.23 | KDE 3.5.7 | openSUSE 10.3
2.6.22.19-0.4-default SMP i686
AMD Athlon 1 GB RAM | GeForce FX 5500 | ASRock K8Upgrade-760GX |
CMedia 9761 AC’97 Audio

Thanks Denver.

I’ve read about that after logging as root into the kde environment…

My bad, does it mean the only way to solve my problem is to reinstall the system, never ever login as root to kde, and edit resolv.conf and network config only through the console when logged as user to kde (for example open console, enter su, enter password, then CHMOD to 666 and edit the files in kwrite, then chmod back to 644 in console?)

eurorage wrote:
> does it mean the only way to solve my problem is to reinstall the
> system,

fact is i do not know why your knetworkmanager is not working…so, i
do not know what it will take to fix it…

you can hang out here and wait for someone to come along and ask all
the questions required to narrow down the and eleminate all the
different things that might cause it to not work…and, then finally
come to a solution (or, you might use google and the site specifier:


site:opensuse [search string]

where the search string might be something like:

knetworkmanager not using DNS adresses in resolv.conf

never ever login as root to kde,

right!

and edit resolv.conf and network config

well, personally i would first try to get it working by using YaST to
set up the networking…did you try that first, or did you follow
some how-to that was written for some other distro, in one of the
preceeding dozen years…

only through the console
when logged as user to kde (for example open console, enter su

well, i never enter just “su” i always use “su -” unless i have
specific needs to retain the previous users environment, path, etc…

enter password, then CHMOD to 666

why oh why would you chmod to 666 or anything else??
root has no need to change file mode bits before editing a file…
where are you learning this junk??

and edit the files in kwrite,

oh, now i see…you don’t know how to use kwrite to edit a file as
root without either logging into gnome as root OR changing the file
permissions of the file you want to edit to allow you (as a normal
user) to edit it…now i understand…

DO NOT CHMOD FILES willy-nilly…because:

then chmod back to 644 in console?)

did you check to see what it should be returned to? are you certain
every file you want to edit was and therefore needs to return to 644??

ok, the first reference i gave you
http://en.opensuse.org/SDB:Login_as_root clearly explains how to edit
any file as root without using chmod OR logging into kde/gnome as root:

try it (while logged in as yourself):

  • press down and hole the (left) Alt key and then press F2

  • up should pop a “Run command” with a blank

  • in that blank type


kdesu kwrite [/etc/resolv.conf]

NOTE: use any file you wish, i picked resolv.conf since that is what
you wanted to change…

  • give your root password when asked

  • edit the file as needed (i always make a backup of the file prior to
    editing…ymmv)

  • save file

  • close kwrite

see? (and, be sure and read the cites given, you might learn other
good stuff)


DenverD (Linux Counter 282315)
CAVEAT: http://is.gd/bpoMD
posted via NNTP w/TBird 2.0.0.23 | KDE 3.5.7 | openSUSE 10.3
2.6.22.19-0.4-default SMP i686
AMD Athlon 1 GB RAM | GeForce FX 5500 | ASRock K8Upgrade-760GX |
CMedia 9761 AC’97 Audio

This explains everything.

Well in order to change DNS’es to custom ones, I need to edit net config and resolv.conf (first file to unset auto DNS policy). Then add nameservers to resolv.conf). Otherwise, my modem will connect, but the knetworkmanager doesn’t always receive the DNS’es. They just don’t add automatically to resolv.conf everytime I connect. It happens once a five reconnects, sometimes takes longer and it’s annoying. So I found myself a solution as described above.

Too bad I didn’t know these console commands. If I knew not to login as root to kde, it’d be much easier now.

I’ll reinstall the system and never make the same mistake again, I still need to read and learn more about this basic stuff since it’s really different than the OS from Redmont :).

Secured, intuitive, free, functional, fit for newbs and pro’s OS - what more would I need?

eurorage wrote:

> still need to read and learn more about this basic stuff since it’s
> really different than the OS from Redmont :).

yep…or, another way to look at it is Redmond’s way to do basic stuff
[like: it is MY machine and i will run as administrator all the time
if i WANT to] leads to low security, cracked systems and malware
golore…and, we don’t want any more of that…so . . .

> Secured, intuitive, free, functional, fit for newbs and pro’s OS - what
> more would I need?

that will do ya’!!

welcome…read, ask, try (once you have figured out a way back…like,
have i mentioned BACKUP yet?)…


DenverD (Linux Counter 282315)
CAVEAT: http://is.gd/bpoMD
posted via NNTP w/TBird 2.0.0.23 | KDE 3.5.7 | openSUSE 10.3
2.6.22.19-0.4-default SMP i686
AMD Athlon 1 GB RAM | GeForce FX 5500 | ASRock K8Upgrade-760GX |
CMedia 9761 AC’97 Audio

@eurorage
Don’t know if you still read this. However, in 11.1 the networkmanager had several issues out of the box. Besides others it had some DNS problems. If you are connecting well with your laptop, this may be because the umst-card is integrated? In all cases, you can get around troubles with 3G cards and modems by using umtsmon (which works very well).
The workaround for the DNS problem for networkmanager connections in 11.1 is to open in yast the /etc/sysconfig and edit under

  • network
  • general dns-policy:
STATIC_FALLBACK ppp* NetworkManager

That should do the trick (at least in 11.1). With umtsmon you do not have these troubles however. Depends a lot what you do use normally.
You may also encounter (at least with version 0.7 and KDE3.5 the fact that networkmanager does see the modem but does not dial. This is another bug (and again you do not encounter it in umtsmon).
Good luck.

Thanks guys.

Well DNS general policy is set to “” (means I manually add my own DNS’es to resolv.conf).

The issue was fixed after reinstall, knm works on user now… perfectly.

I’m configuring mp3 and xvid codecs now :slight_smile:

Then rest of the stuff so my migration might be over soon.

P.S. MY HANDS WILL NEVER ENTER ROOT IN THE LOGIN WINDOW ! :slight_smile:

Some day in the future you will find that this was one of the wisest decisions you made in your linux life. Great you got it working now.

Just for the record, which version of opensuse were you referring to?

11.2 ofcourse

Thanks. LOL never assume “of course”. There are quite some people running still 11.0, 11.1. Sometimes I see even 10.3.
It is always good to state exactly what one have to get better assistance and to make people understand whether a solution proposed is applicable to them. That’s why the question was “obliged”.
Cheers.

stakanov wrote:
> Thanks. LOL never assume “of course”. There are quite some people
> running still 11.0, 11.1. Sometimes I see even 10.3.

exactly! i try to never assume i know what they run…

i helped a person yesterday and in the thanks reply s/he mentioned
s/he is running 8.x


DenverD (Linux Counter 282315)
CAVEAT: http://is.gd/bpoMD
posted via NNTP w/TBird 2.0.0.23 | KDE 3.5.7 | openSUSE 10.3
2.6.22.19-0.4-default SMP i686
AMD Athlon 1 GB RAM | GeForce FX 5500 | ASRock K8Upgrade-760GX |
CMedia 9761 AC’97 Audio