gtk_icon_theme_get_for_screen error for nautilus - upgrade

Recently i have updated the ubuntu 14.04 to Ubuntu 15.04. Usually nautilus . command should open the directory in GUI.However, now i am getting the error like below.
What is the recent for that and any solution to solve it
vanjikumaran#vanjikumaran-ThinkPad-T530:~$ nautilus .
(nautilus:7627): Gtk-CRITICAL **: gtk_icon_theme_get_for_screen: assertion 'GDK_IS_SCREEN (screen)' failed
(nautilus:7627): GLib-GObject-WARNING **: invalid (NULL) pointer instance
(nautilus:7627): GLib-GObject-CRITICAL **: g_signal_connect_object: assertion 'G_TYPE_CHECK_INSTANCE (instance)' failed
vanjikumaran#vanjikumaran-ThinkPad-T530:~$

I have the same issue as you, so I tried to run it as root
sudo nautilus .
But there were still warnings, so I found solution here.
So finally I ran
sudo killall nautilus
sudo apt-get purge nautilus
sudo apt-get update
sudo apt-get install nautilus
Or one line solution
sudo killall nautilus && sudo apt-get purge nautilus && sudo apt-get update && sudo apt-get install nautilus

Related

Remove grafana from ubuntu 17.10

I'm trying to un-install grafana 4.6.3 from Ubuntu 17.10, but is not possible. So far i have tried
sudo apt-get remove grafana , sudo apt-get remove --auto-remove grafana
and says Unable to locate package grafana.
Also tried to install it again from ubuntu software in order to unistall it properly but then pops me up an error message says: Unable to install grafana snap "graphana" is already installed. I installed it first time from ubuntu software.
What can i do to un-install it?
Have you tried dpkg?
sudo dpkg --remove --force-remove-reinstreq <packagename>
If apt won't remove it try using dpkg.
You could also try and clean up your apt utility.
sudo rm -rf /var/cache/apt/archives/<package_name.deb>
sudo apt-get autoclean
sudo apt-get update
sudo apt-get upgrade

Getting Error while installing java8 on ubuntu 16.04

I tried to install java 8 on ubuntu 16.04.
The steps followed are :
$ sudo add-apt-repository ppa:webupd8team/java
$ sudo apt-get update
$ sudo apt install oracle-java8-installer
while running sudo apt install oracle-java8-installer I got the below error.
dpkg: error processing package unattended-upgrades (--configure):
subprocess installed post-installation script returned error exit status 127
No apport report written because MaxReports is reached already
Errors were encountered while processing:
openjdk-8-jre-headless:amd64
locales
oracle-java8-installer
linux-image-4.4.0-78-generic
linux-image-extra-4.4.0-78-generic
linux-image-generic
linux-generic
openjdk-8-jre:amd64
postgresql-common
postgresql-9.6
postgresql-contrib-9.6
postgresql-contrib
sysstat
tomcat8
unattended-upgrades
E: Sub-process /usr/bin/dpkg returned an error code (1)
Please suggest me how to overcome by this error on Ubuntu and suggest the steps to install oracle-java8.
Open Terminal -> and do the following steps sequentially:
sudo add-apt-repository ppa:openjdk-r/ppa
sudo apt-get update
sudo apt-get install openjdk-8-jdk
and finally type:java -version.
This command will show you whether jdk installed in your Ubuntu or not.

how to install mongodb on ubuntu 16.04.1?

I have used the instructions from the docs
after this command:
sudo apt-get install -y mongodb-org
I get this warning:
WARNING: The following packages cannot be authenticated!
mongodb-org-shell mongodb-org-server mongodb-org-mongos mongodb-org-tools mongodb-org
E: There were unauthenticated packages and -y was used without --allow-unauthenticated
Its instruction to start and test gives the following:
sudo service mongod start
cat /var/log/mongodb/mongod.log
cat: /var/log/mongodb/mongod.log: No such file or directory
As I mentioned in the comment, you could solve the problem by bypassing the gpg signature checks of apt using :
sudo apt-get --allow-unauthenticated install -y mongodb-org
You might want to have a look at more configuration options in detail along with right practices of using this appraoch here : https://askubuntu.com/questions/74345/how-do-i-bypass-ignore-the-gpg-signature-checks-of-apt
The mongodb docs have a great page on installing the latest mongo on Ubuntu. You can find it at: https://docs.mongodb.com/manual/tutorial/install-mongodb-on-ubuntu/
I'd recommend uninstalling mongodb and following the instructions on the previously mentioned page.

MongoDB - Ubuntu 15.04 missing packages

I've updated my Ubuntu 14.04 to the latest 15.04. Since then Mongo failed to run. can run the command mongo and it'll advise the version and so on but server will not run: sudo service mongod start as normal.
When I ran: sudo apt-get install -y mongodb-org it failed with the error in the screen shot below:
I completely purged mongo and re-installed, followed the instructions from here. However when I ran sudo apt-get update I noticed the below packages were 404'ing. See Screen shot below.
If anyone could shed any light on this would be great?
Following instructions from this page page http://docs.mongodb.org/manual/tutorial/install-mongodb-on-ubuntu/
but with slighty changed second step 2. Create a list file for MongoDB:
echo "deb http://repo.mongodb.org/apt/ubuntu trusty/mongodb-org/3.0 multiverse" | sudo tee /etc/apt/sources.list.d/mongodb-org-3.0.list
I put trusty (code name for Ubuntu 14.04 LTS) instead of $(lsb_release -sc) which issues vivid as codename for 15.04
I see now that #Nail Lonergan already commented echo path change...
There is currently no build available for Ubuntu 15.04. Check this page for all builds: https://www.mongodb.org/downloads#development
After having heaps of issues, finally this is how I installed it,
Ubuntu 15.04
apt-get update
apt-get dist-upgrade
apt-get install -y mongodb
sudo apt-get install upstart-sysv
sudo service mongodb status
if not running
sudo service mongodb start
Install PHP Driver
sudo apt-get install php5-dev
sudo apt-get install build-essential
sudo pecl install mongo
https://sonnguyen.ws/install-mongodb-mongo-php-in-ubuntu/
sudo apt-get install mongodb
ps -ef|grep mongo
sudo pecl install mongo
sudo apt-get install php5-dev php5-cli php-pear

Can not install postgres in ubuntu

I tried to install postgresql using the following command
apt-get install -t squeeze-backports postgresql-9.1 postgresql-client-9.1 postgresql-contrib-9.1
but i got the following error message.
E: Could not open lock file /var/lib/dpkg/lock - open (13: Permission denied)
E: Unable to lock the administration directory (/var/lib/dpkg/), are you root?
how to fix this?
It looks to me like you aren't running the command as root. Prefix it with "sudo".
sudo apt-get install -t squeeze-backports postgresql-9.1 postgresql-client-9.1 postgresql-contrib-9.1
per the error message:
E: Unable to lock the administration directory (/var/lib/dpkg/), are you root?
However, it looks like you don't understand the command, as you're running Ubuntu and Squeeze is a Debian dist. I think you need to go back to the basics and read the instructions:
Ubuntu help for Pg.
PostgreSQL-supplied packages of newer versions
Some other program has a lock on download operations. Have you got another terminal open or synaptic package manager or anything? Close everything and try again. You can also delete this file /var/lib/dpkg/lock if that doesnt work. Or it might be a root access issue. try running with sudo
Simple steps to install postgresql latest version (Believe me -- try these commends to install postgresql..it will works perfectly )
sudo bash -c 'echo "deb http://apt.postgresql.org/pub/repos/apt/
precise-pgdg main" > /etc/apt/sources.list.d/pgdg.list'
sudo apt-get update
sudo apt-get install postgresql-9.3 pgadmin3
For Open Terminal of postgres
sudo -u postgres psql postgres