4 ms·
For some reason, new Firefox windows can only be launched from the same environment from which the first window has been started. Even the same user who started
by JonathanBeuys 3y ago
For some reason, new Firefox windows can only be launched from the same environment from which the first window has been started. Even the same user who started FF cannot launch a new window from a new shell. That constantly interferes with my workflow.
Example: Say firefox has been started from the Destop already and now I want to start a new Firefox window from a root terminal:
su desktopuser firefox
It does not work. It gives me "Firefox is already running, but is not responding.".
- vagbesfen 3y agoUse --new-instance.
- JonathanBeuys 3y agoGives me the exact same behavior: Firefox is already running, but is not responding. Have you tried it?
- lightlyused 3y agoPerhaps you need a different profile? (Not tested)
- megous 3y agoYeah, same here. Worked fine in the past. https://megous.com/dl/tmp/b82a40ffb92bb11b.png https://megous.com/dl/tmp/b82a40ffb92bb11b.png Console says: [GFX1-]: glxtest: ManageChildProcess failed [GFX1-]: glxtest: libEGL initialize failed [GFX1-]: glxtest: X error, error_code=2, request_code=152, minor_code=3
- Lapha 3y agoI don't mean this as a dig, but I am curious to know what your use case is for launching new browser windows from different environments is. Something along the lines of remote debugging?
- JonathanBeuys 3y agoJust my command line tool telling me "Now look at the following page" and open a browser window with a url.
- ysavir 3y agoI'm not the GP, but for me it was an issue while wanting FF open for regular use and debugging, and another to run for automated feature tests. It's been a few years since I've tried, so I might be forgetting the exact circumstance, but there was some issue like that.
- johnchristopher 3y agoI think that would mess up your user profile if two instances tried to handle it at the same time. Depending on your use case Docker may be a solution.
- JonathanBeuys 3y agoI don't want "two instances". I just want to trigger Firefox to open a new window. Just like it does when I press CTRL+n.
- johnchristopher 3y agoAh, I see now. Try: Try sudo -i -u $user firefox or sudo -E -u $user firefox ?
- JonathanBeuys 3y agoBoth don't work. Why don't you try before you post?
- deleted 3y ago[deleted]
- johnchristopher 3y agoI am working from memory, on my smartphone in public transit in a heatwave. I'd sacrifice some karma but I am hesitant so go see yourself out and off to https://stackoverflow.com https://stackoverflow.com instead.
- Izkata 3y agoIt works if you use -E both when leaving the user environment and when reentering it. There's something in the environment variables that needs to be set for the new firefox instance to communicate with the old one to pass along the new window command, and using -E both times carries it along. Also ssh is somehow able to load this from somewhere without carrying it along. You can "ssh desktopuser@localhost" to restore it, though this does mean you need to set "DISPLAY=:0" manually.
- rascul 3y agoThis does it for me: firefox --new-window google.com
- JonathanBeuys 3y agoNo, that does not work from a different environment. You probably inherited the environment from the process that started FF. How did you try to do it from a new environment?
- rascul 3y agoNo it's from a new environment. I had to set DBUS_SESSION_BUS_ADDRESS and DISPLAY and also allow it with xhost then it worked fine. I don't know how to do that with wayland though.
- deleted 3y ago[deleted]
- paulryanrogers 3y agoYou may need --no-remote and/or -P
- JonathanBeuys 3y ago--no-remote seems to have no effect -P asks me to select a profile. That's not what I want. I simply want a new Firefox window.
- paulryanrogers 3y agoYou may need to combine them like "Firefox --no-remote -P myotherprofile
- JonathanBeuys 3y agoI don't have (nor want) another profile. I just want Firefox to launch a new window. No matter if there already are Firefox windows active or not. Chromium has no problem doing so. So that is the reason I use Chromium and not Firefox.
- paulryanrogers 3y agoThat does seem to be a quirk of Firefox profiles. You could workaround with a secondary profile that uses Firefox Sync to make them nearly equivalent.