You are not logged in.

#1 2010-12-12 22:13:46

bcapro
Member
Registered: 2010-12-12
Posts: 4

[Solved!] Chromium Will Only Run as Root

Hi, all. Love Arch something fierce, but I'm having one specific problem I can't seem to find an answer on any forum or wiki. I'm using xfce4.

I installed Chromium as root using pacman -S chromium. Installed fine, and when I, as root, type "chromium" into the terminal it will pull up. However, I can't set it as my default browser, I can't use it as my normal user, and I can't find any configuration files to change it. I did change my browser default to Chromium via xdg config, but it hasn't changed anything else. Also, on the default icon for web (the little world), I can right-click and get the properties, and see how to switch it to Chromium, but it's not available to select (it's grayed out). I assume this is because I can only set programs that are assigned to my user, not root.

Any thoughts? I really wanted to get everything up and running perfectly without the help of forums, but this one's getting the best of me. Thanks!

Last edited by bcapro (2010-12-14 03:04:37)

Offline

#2 2010-12-12 22:26:56

graysky
Wiki Maintainer
From: :wq
Registered: 2008-12-01
Posts: 10,600
Website

Re: [Solved!] Chromium Will Only Run as Root

What is the output of "chromium" as your normal user?  Run it from a shell, not the shortcut.


CPU-optimized Linux-ck packages @ Repo-ck  • AUR packagesZsh and other configs

Offline

#3 2010-12-12 22:48:33

bcapro
Member
Registered: 2010-12-12
Posts: 4

Re: [Solved!] Chromium Will Only Run as Root

Forgive my ignorance, but when I type "chromium" into the terminal when normal user, this is the output:

3010:3010:7547086139:ERROR:chrome/browser/process_singleton_linux.cc(453) read link failed: permission denied

This repeats 6 times with different errors numbers. The final piece says "ERROR:chrome/browser/browser_main.cc(1150) Failed to create a process singleton from your profile directory. This means that running multiple instances would start multiple browser processes rather than opening a new window in the existing process. Aborting now to avoid profile corruption."

From this I think it's referring to two things: my root and normal user conflicting, or my Google profile conflicting with another instance. (I have a heavily tricked-out profile with apps, bookmarks, extensions, etc.)

It seems more likely that this is a root/user issue. (I may VERY well be wrong). In that case, if I can find a way to remove it from root and put it into my user, that would solve the problem. But I can't install chromium unless I'm root, and I tried various things with chown and chmod to move it, but I don't know what to move.

If there's an error in my thinking, please let me know. I'm by no means a Linux expert, but I enjoy the learning.

Thanks!

Offline

#4 2010-12-12 22:53:44

skunktrader
Member
From: Brisbane, Australia
Registered: 2010-02-14
Posts: 1,543

Re: [Solved!] Chromium Will Only Run as Root

bcapro wrote:

But I can't install chromium unless I'm root, and I tried various things with chown and chmod to move it, but I don't know what to move.

Where did you install it from?  Repo http://www.archlinux.org/packages/extra … /chromium/  or AUR? http://aur.archlinux.org/packages.php?ID=37244  or somewhere else?

Offline

#5 2010-12-12 22:55:15

anonymous_user
Member
Registered: 2009-08-28
Posts: 3,059

Re: [Solved!] Chromium Will Only Run as Root

Have you tried deleting Chromium's config folder?

rm -r ~/.config/chromium

Offline

#6 2010-12-13 00:02:09

bcapro
Member
Registered: 2010-12-12
Posts: 4

Re: [Solved!] Chromium Will Only Run as Root

I downloaded it from the Extra repo.

When I tried to run "rm -r ~/.config/chromium" in both normal and root user, it's telling me No such file or directory. Just out of curiosity, I ran "nano etc/config/chromium" to see what would happen, and I get the Nano editor with a page titled "etc/config/chromium" but there's nothing there.

Last edited by bcapro (2010-12-13 00:16:33)

Offline

#7 2010-12-13 00:58:51

useradded
Member
From: Edinburgh, UK
Registered: 2010-05-15
Posts: 77

Re: [Solved!] Chromium Will Only Run as Root

bcapro wrote:

When I tried to run "rm -r ~/.config/chromium" in both normal and root user, it's telling me No such file or directory. Just out of curiosity, I ran "nano etc/config/chromium" to see what would happen, and I get the Nano editor with a page titled "etc/config/chromium" but there's nothing there.

If file xxx does not exist then "nano xxx" will always open a new, blank file.  The command "nano [anything_here]" will open a new, blank file of that name for editing.

EDIT: also, /etc/config/chromium does not exist.

Last edited by useradded (2010-12-13 01:01:05)

Offline

#8 2010-12-13 01:19:20

Ultraman
Member
Registered: 2009-12-24
Posts: 242

Re: [Solved!] Chromium Will Only Run as Root

"3010:3010:7547086139:ERROR:chrome/browser/process_singleton_linux.cc(453) read link failed: permission denied"

This is the "lock" file Chromium creates/maintains when it's running.
I once experienced a crash with Chromium, and was unable to launch chromium again. Starting it from the terminal gave me a similar kind of message.

What you should do is removing Chromium's files that it created in your home directory and the root home directory.
I'm not on a system running Chromium right now, so I cannot provide you with the exact names or path.
But they will be in /home/<you username here> and in /root (the homedir of root).
Check your homedir for .chromium for example and remove it. Rinse and repeat for the homedir of root (/root)

You should have a clean slate now; as if you had just installed Chromium.

Last edited by Ultraman (2010-12-13 01:19:38)

Offline

#9 2010-12-13 01:28:06

anonymous_user
Member
Registered: 2009-08-28
Posts: 3,059

Re: [Solved!] Chromium Will Only Run as Root

@bcapro - ~/.config/chromium is a folder not a file. Double-check with your file manager if it exists.

Offline

#10 2010-12-13 13:58:35

devius
Member
Registered: 2010-11-11
Posts: 22

Re: [Solved!] Chromium Will Only Run as Root

Ultraman wrote:

What you should do is removing Chromium's files that it created in your home directory and the root home directory.
I'm not on a system running Chromium right now, so I cannot provide you with the exact names or path.
But they will be in /home/<you username here> and in /root (the homedir of root).

You should have a clean slate now; as if you had just installed Chromium.

@bcapro: I don't think that the root's chromium files will interfere with the user's ones, so it's probably safe to leave the root home directory alone. If the directory /home/<yourusername>/.config/chromium doesn't exist that may be the problem. Maybe it can't be created at runtime due to incorrect permissions on the .config directory or even your home directory.

Offline

#11 2010-12-14 03:04:04

bcapro
Member
Registered: 2010-12-12
Posts: 4

Re: [Solved!] Chromium Will Only Run as Root

SOLVED! SOLVED! Okay, here's how I did it. I took all your advice and found that Chromium was only in root. Okay, logically, I need to switch Chromium to my user. I tried everything, running multiple commands. First I realized my file wasn't in an example format. So I switched that. New errors. Okay, now I have to chown it to myself, using sudo. First, I have to install sudo, configure it to allow my user after switching to nano (that's all I know), then I can run the command. More errors- what's going on? Turns out it was already inputting the long path I was using before, so I had to shorten it to what I originally tried. And then it worked, and I feel like a hero. A nerdy, geeky hero.

Thanks so much for your help, everybody. That's it- my Arch's ready to go.

I am crushing so hard on this distro right now.

Offline

#12 2011-05-04 22:55:08

MSXManiac
Member
Registered: 2011-05-04
Posts: 2

Re: [Solved!] Chromium Will Only Run as Root

Simply modify the /etc/chromium-browser/default file with gedit or leafpad or another pure text file editor to add this flag to the chromium flags:
--user-data-dir
And voilá, chromium starts in a root profile!

Offline

Board footer

Powered by FluxBB