LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (http://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Opera Launcher (http://www.linuxquestions.org/questions/linux-newbie-8/opera-launcher-844462/)

acraig 11-15-2010 07:40 PM

Opera Launcher
 
I recently returned to Gnome from Xfce, and when I installed Opera I did everything I did the first, second, and third time I installed Opera in Linux, but the launcher had to be manually tweaked to work. I've used Opera for years and this is the first time I've had this problem.

The command was changed from /usr/local/bin/opera %U to sudo /usr/local/bin/opera %U

It does not work without being prefaced by 'sudo'. That is not a big issue with me, although I know from past experience that I shouldn't have had to do that. I am webmaster and web page designer and use multiple browser to view web pages before they are placed online. I recently realized that when I right click on a web page and choose Opera to open the file, nothing happens. I have to go to "open with other application", choose "use a custom command" and type in "sudo /usr/local/bin/opera" in order to open the page in Opera. I have to do it every single time!

It is becoming very annoying, as I build and tweak a lot of pages. Is there a way to fix this, so I never have to use special, manual commands and sudo again?

stress_junkie 11-15-2010 08:08 PM

Of course running Opera as root is a security problem but the fact that it works as root says that all of the files are in the right place. The problem appears to be related to permissions.

Check the permissions on the opera binary. Make sure that it is executable by everyone.

Run Opera from a terminal and watch the error messages to get a better idea of the problem.

acraig 11-16-2010 04:01 PM

I don't know where to find the "binary permissions", but I did locate the hidden directory in home. It was owned by root. I logged in as root and changed the permissions, but I still can not open a web page in Opera by right clicking. And when I tried to open Opera in a terminal all I got was an open terminal.:scratch:

Also, I just realized something else pretty significant that I hadn't realized before, I can't start Opera from the Applications drop down menu!:o I had never tried before, because I prefer and use launchers exclusively for daily use programs.

Would I be better off just uninstalling and reinstalling Opera, even though I did what I had always done to make Opera available to everyone when I installed last time? Is it possible that could work or is something else going on?

stress_junkie 11-16-2010 04:51 PM

Quote:

Originally Posted by acraig (Post 4161116)
Would I be better off just uninstalling and reinstalling Opera, even though I did what I had always done to make Opera available to everyone when I installed last time? Is it possible that could work or is something else going on?

It's a tempting idea. I suppose it depends on what you always do to make an application available to everyone. It seems likely that if you followed the same steps then you would achieve the same results.

Since Opera works for root then we should be able to make it work for a non-privileged user account.

Quote:

Originally Posted by acraig (Post 4161116)
I don't know where to find the "binary permissions", but I did locate the hidden directory in home. It was owned by root.

If you could see that the .opera file was owned by root then you probably also saw the permission settings. It depends on how you found the .opera directory. If it was in some GUI file manager then it may not have shown you the permissions.

Quote:

Originally Posted by acraig (Post 4161116)
Also, I just realized something else pretty significant that I hadn't realized before, I can't start Opera from the Applications drop down menu!:o I had never tried before, because I prefer and use launchers exclusively for daily use programs.

That is to be expected since the desktop launcher would do the same thing as the application menu.

Quote:

Originally Posted by acraig (Post 4161116)
I logged in as root and changed the permissions, but I still can not open a web page in Opera by right clicking. And when I tried to open Opera in a terminal all I got was an open terminal.

My ignorance of Dream Linux is getting in my way here. I don't know what terminal emulator software is installed by default. I had expected that when you opened the terminal window you would then type opera at the prompt and press the enter key. Then you would see a bunch of messages that are generated by Opera. Some of those messages could help us find the problem.

Now that we know that the .opera directory is owned by root our first task should be to delete that directory. You may need to become root to do that or you may be able to use the sudo utility to temporarily gain root access for one command. Here is an example of how to use sudo to delete the .opera directory in your home directory.
Code:

cd
sudo rm -r .opera

Notice that I performed the cd command first just to be sure that we are in your home directory. Then the sudo command gains root privileges and executes the following command. The rm -r command will remove the entire .opera directory and its files.

That by itself could fix your problem. Give it a try and report the results.

frankbell 11-16-2010 07:07 PM

When you install Opera, it give you the option of installing it for all users or installing just for the installing user.

If you installed it as root or with sudo, is it possible a mouse click went wrong on that question?

You might try also posing this question on the Opera newsgroups at news.opera.com or in the Opera forums at opera.com.

acraig 11-17-2010 06:10 PM

Thank you!!
 
Thank you for the advice, stress_junkie! I removed the .opera directory and reinstalled Opera, very carefully, system wide.

I think frankbell is correct as to how this happened. When I was reinstalling, I realized the set up would make such an accident easy to make. I probably nudged the down key just before I hit enter and ended up installing as root, even though it had appeared to be installed system wide.

After I reinstalled Opera, first thing I tried was right clicking on a web page and it opened right up. No problem. Everything now works as it should -- desktop launcher with sudo removed and the applications drop down menu.:D

I really appreciate the help. Thank you very much!


All times are GMT -5. The time now is 01:11 PM.