Firefox updating display very slowly when running as normal user
Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
that is honestly all you have to say after someone took the effort to write it all out for you with steps, commands and alternatives?
may your fingers rot off.
or wait, maybe you are a bot?
This is very confusing. Normally, you shouldn't ever need to run Firefox as root. If you do, then things may get weird. The developers do not expect anyone to run Firefox as root, so any strange bugs caused by it are not ones the developers would have prepared for.
Note that Firefox does not play nicely with itself when trying to run it in multiple processes on the same screen. Instead of opening a second instance of Firefox, it will open a new window in the currently running instance of Firefox. It expects the running user to be the same, of course.
My guess is that it's getting confused because some files which should have been created and owned by the normal user were instead created and owned by root. I'd wipe clean various folders in your normal user home folder to try and deal with this. And remember to never run Firefox as root. Any bugs you encounter from running as root will not be ones the developers have anticipated or would be familiar with.
If you have ran firefox as root chances are... worms in java got into the fox belly. Tar to back up both /root/.mozilla and /home/$USER/.mozilla keep it safe for in case you will miss your bookmarks. Then
I think, then, that there may be something going on with X, where the regular user has insufficient rights for hardware accelerated graphics or something. I'm afraid I do not know how to troubleshoot X issues like this.
You could try creating a new regular user and see if the new user has similar issues. If nothing else, creating a new regular user will give you a "sand box" for experimenting with potential fixes or trying to duplicate an issue.
had another glance at post #1.
intel broadwell cpu & graphics, i915 driver, probably a cutting edge kernel version with arch - i really don't see any problems there.
i suspect that the whole running-gui-apps-as-root might have messed things up a bit (a lot).
Running Firefox as root poses no problem to an ordinary user's home, if the X session was started as root. Otherwise, trouble like Shadow_7 describes is to be expected.
Creating a new user to see if it solves the original lagging problem is a good idea, but it won't solve problems created by the original user running Firefox as root. To confirm that all root owned files in the normal user's home have been eradicated is fairly easy using the OFMMC (Midnight Commander), which lists files the same way as 'ls -l' does, so root-owned files will jump in your face if they exist, while MC makes easy to navigate through the home tree looking to see that all files and directories are properly owned.
Does that Haswell laptop have both Intel and NVidia video? IIUC, that combination wants a special video driver that won't install by default, Bumblebee or Optimus.
If there is only Intel, uninstalling the Intel video driver will result in the 1.18.4 server falling back to the integral modesetting driver, which works just fine on my Haswell, and might solve the original problem.
Running Firefox as root poses no problem to an ordinary user's home, if the X session was started as root.
wasn't:
Quote:
Originally Posted by ForumBot
When I run one version of Firefox as root and another as a normal user, the one run as a normal user doesn't display slowly and my settings for running it as root are used when running it as a normal user, even though this normaly isn't the case.
When I run one version of Firefox as root and another as a normal user, the one run as a normal user doesn't display slowly and my settings for running it as root are used when running it as a normal user, even though this normaly isn't the case.
What sequence of events is transpiring here is clear as mud. How exactly are these different browser versions being started up? It sounds like these are simultaneous and need --no-remote switches or envar NO_REMOTE=1.
Running Firefox as root poses no problem to an ordinary user's home, if the X session was started as root. Otherwise, trouble like Shadow_7 describes is to be expected.
It's normally a problem if you run it as root and are IN the ordinary user's home path. Like if you use "su" instead of "su - root" to become root as that ordinary user. Not normally an issue if the user ran firefox first. But if the first user to run firefox from that path was root and not the user, issues. Probably not the issue in this case.
$ groups
If you're not in the "video" group, you can't use GPU acceleration. Which would make things slower. Also if you don't have internet access I've found that firefox launch time is extremely slow. Since my internet was down several hours on friday evening (storm). And bringing up said browser to reboot the router over it's webby interface was painful. It didn't used to be this way.
It's normally a problem if you run it as root and are IN the ordinary user's home path. Like if you use "su" instead of "su - root" to become root as that ordinary user....
When you start an X session as root, it doesn't matter where you start an X application from. The only settings that will be used for the root X session are those in /root/. It works the same way as for normal users, other than root's homedir isn't a subdir of /home/. When you are in a normal user's X session already and use su, all bets are off, because you didn't start the X session as root, and thus can expect file ownership trouble.
I think, then, that there may be something going on with X, where the regular user has insufficient rights for hardware accelerated graphics or something. I'm afraid I do not know how to troubleshoot X issues like this.
You could try creating a new regular user and see if the new user has similar issues. If nothing else, creating a new regular user will give you a "sand box" for experimenting with potential fixes or trying to duplicate an issue.
Thank you for the response.
I created a new user with useradd -m temp. When I ran su temp and then startx, sXorg would not start and produced produced the error at http://textuploader.com/58gra. When I logged out and logged in as temp, startx ran without errors except for occasionally outputting, "(firefox:9348_: Gtk-CRITICAL **: gtk_clipboard_set_with_data: assertion 'targets != NULL' failed." I didn't notice a change in speed between running Firefox as temp, lithoria, and before and after the error was outputted.
I will now give more details about Firefox's performance. On rare occasions, displaying typing and opening new tabs is done almost instantaneously when running as temp. I have noticed opening new tabs being displayed almost instantaneously when running Firefox as lithoria, but I haven't seen typing being displayed almost instantaneously when running as lithoria. This may be due to its rarity. Aside from these occasions, when I start typing into the search box, no text is displayed until I stop typing text for roughly two seconds, which results in all text being displayed. It takes roughly one second for the display to update after opening or closing a tab. It takes 20-30 seconds for the display to updated after highlighting text. It takes roughly 50 seconds for the display to update after pressing a menu item in the Firefox preferences pages. It takes roughly one second for the widgets on the top right corner of the screen to be highlighted when moused over. It took 19 seconds for the display to be updated after clicking on the drop-down list in Firefox's search preferences page.
What sequence of events is transpiring here is clear as mud. How exactly are these different browser versions being started up? It sounds like these are simultaneous and need --no-remote switches or envar NO_REMOTE=1.
The events happened in this order:
* I ran startx as lithoria
* From within Ratpoison, I ran su root to log in as root.
* From within the above terminal, as root, I ran firefox.
* I opened a new terminal without closing the other one.
* In the new terminal I was already lithoria, so I ran firefox.
* Firefox updated the display quickly.
It's normally a problem if you run it as root and are IN the ordinary user's home path. Like if you use "su" instead of "su - root" to become root as that ordinary user. Not normally an issue if the user ran firefox first. But if the first user to run firefox from that path was root and not the user, issues. Probably not the issue in this case.
$ groups
If you're not in the "video" group, you can't use GPU acceleration. Which would make things slower. Also if you don't have internet access I've found that firefox launch time is extremely slow. Since my internet was down several hours on friday evening (storm). And bringing up said browser to reboot the router over it's webby interface was painful. It didn't used to be this way.
Thank you for the response.
I have Internet access.
I edited /etc/group to add lithoria to the video group, which lithoria was not currently in. I didn't notice any changes in Firefox's speed.
To confirm that all root owned files in the normal user's home have been eradicated is fairly easy using the OFMMC (Midnight Commander), which lists files the same way as 'ls -l' does, so root-owned files will jump in your face if they exist, while MC makes easy to navigate through the home tree looking to see that all files and directories are properly owned.
I used ls -lR to look through all files in /home/lithoria other than those in documents, downloads, and archive, which only contain personal files. All files had owners and owner groups of lithoria.
[QUOTE=mrmazda;5597203]Does that Haswell laptop have both Intel and NVidia video? IIUC, that combination wants a special video driver that won't install by default, Bumblebee or Optimus.[\QUOTE]
AFAIK my laptop only has Intel, but I don't know how to verify this.
[QUOTE=mrmazda;5597203]If there is only Intel, uninstalling the Intel video driver will result in the 1.18.4 server falling back to the integral modesetting driver, which works just fine on my Haswell, and might solve the original problem.[\QUOTE]
I had the package xf86-video-intel. I uninstalled it. After doing so, Firefox updated the display quickly when run as a normal user. Thank you. Do you know why uninstalling it fixed the problem? Presumably it's because it stopped Firefox from using the driver, but I don't know why that fixed the problem.
AFAIK my laptop only has Intel, but I don't know how to verify this.
'lspci | grep VGA' should be sufficient to see if there is more than just Intel.
Quote:
Quote:
Originally Posted by mrmazda
If there is only Intel, uninstalling the Intel video driver will result in the 1.18.4 server falling back to the integral modesetting driver, which works just fine on my Haswell, and might solve the original problem.
I had the package xf86-video-intel. I uninstalled it. After doing so, Firefox updated the display quickly when run as a normal user. Thank you. Do you know why uninstalling it fixed the problem? Presumably it's because it stopped Firefox from using the driver, but I don't know why that fixed the problem.
Some hardware exposes bugs that other hardware doesn't. This provides an overview, but doesn't help with why Firefox only as normal user. Someone in a Mozilla-specific forum, e.g. on IRC, might be able to provide insight.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.