Network manager says wired network device not managed
If you have any trouble in accessing internet using your wired connection and while troubleshooting, if your network manager says that "device is not managed", open the terminal and follow the below steps to fix the issue.
sudo vim /etc/NetworkManager/NetworkManager.conf
change the line managed=false to managed=true
sudo service network-manager restart
Related cards:
know which window manager is running
In ubuntu, you have a variety of window managers to choose from. Though Ubuntu 12.04 comes with Unity as the default you can switch back to Gnome, or choose other managers like Cinnamon.
If you want to know, which window manager you are running c...
SUDO not working
sudo: /etc/sudoers is mode 0640, should be 0440?
When a similar message appears when you try to run sudo on your machine, the problem is likely with the permissions of /etc/sudoers file.
Try running
pkexec chmod 0440 /etc/sudoers
```...
/etc/resolvconf/update.d/libc: Warning: /etc/resolv.conf is not a symbolic link to /run/resolvconf/resolv.conf
Use following command and answer YES to enable dynamic updates:
sudo dpkg-reconfigure resolvconf
Do a system restart after that.
install cisco vpn client on ubuntu
Ubuntu ships by default with the plugin for the Point-to-Point Tunneling Protocol (PPTP), but we need the plugin for the Cisco Compatible VPN (vpnc), that provides easy access to Cisco Connector based VPNs. To install the vpnc plugin, open your te...
ssh login without password
Nothing new .. just a note to self about how easy this is
> ssh-keygen [Enter] [Enter] [Enter]
> ssh-copy-id -i ~/.ssh/id_rsa.pub user@remote-host
> ssh user@remote-host
||= operator in Ruby
x ||= y is similar to x || x = y.
In the above statement, if x evaluates to logical true then assignment is not done.
If x evaluates to logical false only then the assignment is done.
Though the above two statements are similar, there are...
Class_eval and Instance_eval
class_eval is called on a class object and is used to create instance methods for the class at runtime.
%w(administrator developer teamlead tester).each do |user|
class_eval <<-EOR
def is_#{user}?
site == "MYACCOUNT_#{org.upcase}" ...
$: in Ruby
In Rails programming you might seldom come across the below statement
$:.unshift File.dirname(__FILE__)
$: represents load path in Ruby.
Its a pre-defined variable and short hand for $LOAD_PATH which ruby uses to look for files.
unshif...
Prepend filters in rails
prepend_before_filter and append_before_filter are almost the same.
They differ only in precedence. Prepend filters have higher precedence over append filters.
before_filter is an alias to append_before_filter
class MyController < ActionCon...
collect or map in ruby
map is an alias to collect . It basically returns an array by performing some operation on every item in the given collection. It expects a block containing the operation.
[1, 2, 3, 4].map {|number| number ** 2}
# [1, 4, 9, 16]
In the ab...