9

I've switched to XMonad as my window manager. Sometimes when I put my laptop to hibernate, it's hanging and won't shut down. I have to force it off by pressing the powerbutton for 5 seconds.

After I boot again, I can't connect to the internet. I have to logout, go to gnome, and after logging in, I rightclick the network applet icon and select the enable networking options. After that, my internet is working again.

Is there a way to do this via the command line or another option?

Stefano Palazzo
  • 85,787
  • 45
  • 210
  • 227
Ikke
  • 9,203
  • 2
  • 17
  • 10

4 Answers4

5

You can use nmcli (part of NM) or cnetworkmanager

sudo apt-get install cnetworkmanager

to control NetworkManager from the commandline.

BTW: you can configure Monad to use a panel or such (but maybe that's not what you want).

Mark Kirby
  • 18,289
  • 19
  • 78
  • 113
JanC
  • 19,222
  • 4
  • 44
  • 50
  • basically this, disable: `nmcli nm enable false` enable: `nmcli nm enable true`, no sudo required! saw [here](http://ubuntuforums.org/showthread.php?t=1969533&p=11900910#post11900910) – Aquarius Power Jul 23 '14 at 08:50
3

You can customise xmonad with status bar and tray apps for utilities like network-manager which need tray icons.

This guide, for example, details how to set up xmobar and trayer, among other things.

  • It seems a good sollution. The only problem is that I can't seem to get trayer on the top of my screen. It just doesn't appear. – Ikke Oct 28 '10 at 12:47
  • Temporarily fixed the problem by adjusting my xorg.conf to allow for only one screen. See http://askubuntu.com/questions/10005/getting-trayer-to-work-with-dual-screen-setup – Ikke Oct 28 '10 at 15:04
1

I find after improper shutdowns that the /etc/NetworkManager/nm-system-settings.conf often has Managed=False set. When you go into GNOME and hit that checkbox, all you're doing is toggling that to True. You can do it with a text editor too.

maco
  • 15,622
  • 3
  • 31
  • 35
  • Setting it to true doesn't solve the issue, and it seems enableing networking doesn't set it to true – Ikke Oct 23 '10 at 13:18
-1

It sounds like you've killed the network-manager daemon. You can restart it by doing sudo service network-manager start. However if you're not using network-manager you can always remove it all together (and probably eliminate this issue).

Nick HS
  • 781
  • 6
  • 13
  • The network manager is still running (NetworkManager process). And I use nm-applet to get wireless connection. – Ikke Oct 23 '10 at 13:17